From cc38f01aea40040b615ad8e0ea43f358ef1e844b Mon Sep 17 00:00:00 2001 From: WhiteSource Renovate Date: Wed, 31 Aug 2022 23:02:19 +0200 Subject: [PATCH 01/38] chore(deps): update dependency com.google.cloud:libraries-bom to v26.1.1 (#785) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit [![Mend Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com) This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [com.google.cloud:libraries-bom](https://cloud.google.com/java/docs/bom) ([source](https://togithub.com/googleapis/java-cloud-bom)) | `26.1.0` -> `26.1.1` | [![age](https://badges.renovateapi.com/packages/maven/com.google.cloud:libraries-bom/26.1.1/age-slim)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://badges.renovateapi.com/packages/maven/com.google.cloud:libraries-bom/26.1.1/adoption-slim)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://badges.renovateapi.com/packages/maven/com.google.cloud:libraries-bom/26.1.1/compatibility-slim/26.1.0)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://badges.renovateapi.com/packages/maven/com.google.cloud:libraries-bom/26.1.1/confidence-slim/26.1.0)](https://docs.renovatebot.com/merge-confidence/) | --- ### Configuration 📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. 🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] If you want to rebase/retry this PR, click this checkbox. --- This PR has been generated by [Mend Renovate](https://www.mend.io/free-developer-tools/renovate/). View repository job log [here](https://app.renovatebot.com/dashboard#github/googleapis/java-cloudbuild). --- samples/snippets/pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/samples/snippets/pom.xml b/samples/snippets/pom.xml index a3cf959e..c42d1772 100644 --- a/samples/snippets/pom.xml +++ b/samples/snippets/pom.xml @@ -30,7 +30,7 @@ com.google.cloud libraries-bom - 26.1.0 + 26.1.1 pom import From ae125a8dd95463afe5186935017be25a40602461 Mon Sep 17 00:00:00 2001 From: WhiteSource Renovate Date: Fri, 9 Sep 2022 05:48:12 +0200 Subject: [PATCH 02/38] deps: update dependency com.google.cloud:google-cloud-shared-dependencies to v3.0.2 (#787) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit [![Mend Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com) This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [com.google.cloud:google-cloud-shared-dependencies](https://togithub.com/googleapis/java-shared-dependencies) | `3.0.1` -> `3.0.2` | [![age](https://badges.renovateapi.com/packages/maven/com.google.cloud:google-cloud-shared-dependencies/3.0.2/age-slim)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://badges.renovateapi.com/packages/maven/com.google.cloud:google-cloud-shared-dependencies/3.0.2/adoption-slim)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://badges.renovateapi.com/packages/maven/com.google.cloud:google-cloud-shared-dependencies/3.0.2/compatibility-slim/3.0.1)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://badges.renovateapi.com/packages/maven/com.google.cloud:google-cloud-shared-dependencies/3.0.2/confidence-slim/3.0.1)](https://docs.renovatebot.com/merge-confidence/) | --- ### Release Notes
googleapis/java-shared-dependencies ### [`v3.0.2`](https://togithub.com/googleapis/java-shared-dependencies/blob/HEAD/CHANGELOG.md#​302-httpsgithubcomgoogleapisjava-shared-dependenciescomparev301v302-2022-09-08) [Compare Source](https://togithub.com/googleapis/java-shared-dependencies/compare/v3.0.1...v3.0.2) ##### Dependencies - Update dependency com.fasterxml.jackson:jackson-bom to v2.13.4 ([#​789](https://togithub.com/googleapis/java-shared-dependencies/issues/789)) ([6cf91a9](https://togithub.com/googleapis/java-shared-dependencies/commit/6cf91a96b9ea6af0fb845b50582dac7aa2892cab)) - Update dependency com.google.auth:google-auth-library-bom to v1.10.0 ([#​781](https://togithub.com/googleapis/java-shared-dependencies/issues/781)) ([8859e61](https://togithub.com/googleapis/java-shared-dependencies/commit/8859e61808bfc5cd9546e27e945fc855b36d2554)) - Update dependency com.google.auth:google-auth-library-bom to v1.11.0 ([#​790](https://togithub.com/googleapis/java-shared-dependencies/issues/790)) ([3431a47](https://togithub.com/googleapis/java-shared-dependencies/commit/3431a471cbf874a67a4f1a42e31f0ed891dedc92)) - Update dependency com.google.auth:google-auth-library-bom to v1.9.0 ([#​773](https://togithub.com/googleapis/java-shared-dependencies/issues/773)) ([27fc79f](https://togithub.com/googleapis/java-shared-dependencies/commit/27fc79f00ee70011df6a368bb8fcfad7f0ce41f0)) - Update dependency com.google.errorprone:error_prone_annotations to v2.15.0 ([#​776](https://togithub.com/googleapis/java-shared-dependencies/issues/776)) ([bf333b8](https://togithub.com/googleapis/java-shared-dependencies/commit/bf333b8c88072d21cb959db4d3328bbb55d9ef5c)) - Update dependency com.google.protobuf:protobuf-bom to v3.21.5 ([#​780](https://togithub.com/googleapis/java-shared-dependencies/issues/780)) ([da7f44d](https://togithub.com/googleapis/java-shared-dependencies/commit/da7f44d71d6d7f372b5313dab68ce220308614d4)) - Update dependency io.grpc:grpc-bom to v1.48.1 ([#​768](https://togithub.com/googleapis/java-shared-dependencies/issues/768)) ([5c7768d](https://togithub.com/googleapis/java-shared-dependencies/commit/5c7768d3c9665dd356de6c39c0a6a5fa6e992f2e)) - Update dependency io.grpc:grpc-bom to v1.49.0 ([#​786](https://togithub.com/googleapis/java-shared-dependencies/issues/786)) ([8734812](https://togithub.com/googleapis/java-shared-dependencies/commit/8734812f1b4e2faaa48caf41eff59a85892ae344)) - Update dependency org.checkerframework:checker-qual to v3.24.0 ([#​775](https://togithub.com/googleapis/java-shared-dependencies/issues/775)) ([df74b7b](https://togithub.com/googleapis/java-shared-dependencies/commit/df74b7b0dd5dd592523f302d9fb36adb5991cb0b)) - Update dependency org.checkerframework:checker-qual to v3.25.0 ([#​788](https://togithub.com/googleapis/java-shared-dependencies/issues/788)) ([207035b](https://togithub.com/googleapis/java-shared-dependencies/commit/207035bd04c9305899eea540acbefaf06a7b1ec9)) - Update dependency org.threeten:threetenbp to v1.6.1 ([#​782](https://togithub.com/googleapis/java-shared-dependencies/issues/782)) ([0f218ae](https://togithub.com/googleapis/java-shared-dependencies/commit/0f218aeb6aa33cf1da4a8b1d6c82bbf87946dab9)) - Update gax.version to v2.19.0 ([#​785](https://togithub.com/googleapis/java-shared-dependencies/issues/785)) ([4448331](https://togithub.com/googleapis/java-shared-dependencies/commit/4448331c4c6d88ea8076260776d1d47d24aa19fa)) - Update google.core.version to v2.8.10 ([#​787](https://togithub.com/googleapis/java-shared-dependencies/issues/787)) ([3c344d5](https://togithub.com/googleapis/java-shared-dependencies/commit/3c344d515e3b9215db5a1f8ef550d800d974e558)) - Update google.core.version to v2.8.7 ([#​774](https://togithub.com/googleapis/java-shared-dependencies/issues/774)) ([d0cd5e8](https://togithub.com/googleapis/java-shared-dependencies/commit/d0cd5e8f6ca88787fe0dbf7f30c849cb4c4fae5e)) - Update google.core.version to v2.8.8 ([#​777](https://togithub.com/googleapis/java-shared-dependencies/issues/777)) ([f00571c](https://togithub.com/googleapis/java-shared-dependencies/commit/f00571cd1e9f1c4e011fba4a1e1674c1d8d60200)) - Update google.core.version to v2.8.9 ([#​784](https://togithub.com/googleapis/java-shared-dependencies/issues/784)) ([aa8e505](https://togithub.com/googleapis/java-shared-dependencies/commit/aa8e505dbb1214b2239e55d5ac83b00c167d77e4))
--- ### Configuration 📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. 🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] If you want to rebase/retry this PR, click this checkbox. --- This PR has been generated by [Mend Renovate](https://www.mend.io/free-developer-tools/renovate/). View repository job log [here](https://app.renovatebot.com/dashboard#github/googleapis/java-cloudbuild). --- pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pom.xml b/pom.xml index 8beb5fc4..1f8b70e5 100644 --- a/pom.xml +++ b/pom.xml @@ -78,7 +78,7 @@ com.google.cloud google-cloud-shared-dependencies - 3.0.1 + 3.0.2 pom import From 87f2e01e4d3ff83eadfcbc08a263f7869118f68b Mon Sep 17 00:00:00 2001 From: "release-please[bot]" <55107282+release-please[bot]@users.noreply.github.com> Date: Fri, 9 Sep 2022 04:06:35 +0000 Subject: [PATCH 03/38] chore(main): release 3.5.3 (#788) :robot: I have created a release *beep* *boop* --- ## [3.5.3](https://github.com/googleapis/java-cloudbuild/compare/v3.5.2...v3.5.3) (2022-09-09) ### Dependencies * Update dependency com.google.cloud:google-cloud-shared-dependencies to v3.0.2 ([#787](https://github.com/googleapis/java-cloudbuild/issues/787)) ([ae125a8](https://github.com/googleapis/java-cloudbuild/commit/ae125a8dd95463afe5186935017be25a40602461)) --- This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please). --- CHANGELOG.md | 7 +++++++ google-cloud-build-bom/pom.xml | 8 ++++---- google-cloud-build/pom.xml | 4 ++-- grpc-google-cloud-build-v1/pom.xml | 4 ++-- pom.xml | 8 ++++---- proto-google-cloud-build-v1/pom.xml | 4 ++-- versions.txt | 6 +++--- 7 files changed, 24 insertions(+), 17 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 66d7da69..3660812a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,12 @@ # Changelog +## [3.5.3](https://github.com/googleapis/java-cloudbuild/compare/v3.5.2...v3.5.3) (2022-09-09) + + +### Dependencies + +* Update dependency com.google.cloud:google-cloud-shared-dependencies to v3.0.2 ([#787](https://github.com/googleapis/java-cloudbuild/issues/787)) ([ae125a8](https://github.com/googleapis/java-cloudbuild/commit/ae125a8dd95463afe5186935017be25a40602461)) + ## [3.5.2](https://github.com/googleapis/java-cloudbuild/compare/v3.5.1...v3.5.2) (2022-08-02) diff --git a/google-cloud-build-bom/pom.xml b/google-cloud-build-bom/pom.xml index f9fc8aa0..a7ba302c 100644 --- a/google-cloud-build-bom/pom.xml +++ b/google-cloud-build-bom/pom.xml @@ -3,7 +3,7 @@ 4.0.0 com.google.cloud google-cloud-build-bom - 3.5.3-SNAPSHOT + 3.5.3 pom com.google.cloud @@ -52,17 +52,17 @@ com.google.cloud google-cloud-build - 3.5.3-SNAPSHOT + 3.5.3 com.google.api.grpc grpc-google-cloud-build-v1 - 3.5.3-SNAPSHOT + 3.5.3 com.google.api.grpc proto-google-cloud-build-v1 - 3.5.3-SNAPSHOT + 3.5.3 diff --git a/google-cloud-build/pom.xml b/google-cloud-build/pom.xml index 07b649eb..904c711a 100644 --- a/google-cloud-build/pom.xml +++ b/google-cloud-build/pom.xml @@ -3,7 +3,7 @@ 4.0.0 com.google.cloud google-cloud-build - 3.5.3-SNAPSHOT + 3.5.3 jar Google Cloud Build https://github.com/googleapis/java-cloudbuild @@ -13,7 +13,7 @@ com.google.cloud google-cloud-build-parent - 3.5.3-SNAPSHOT + 3.5.3 google-cloud-build diff --git a/grpc-google-cloud-build-v1/pom.xml b/grpc-google-cloud-build-v1/pom.xml index 0c33449b..2d06bb32 100644 --- a/grpc-google-cloud-build-v1/pom.xml +++ b/grpc-google-cloud-build-v1/pom.xml @@ -4,13 +4,13 @@ 4.0.0 com.google.api.grpc grpc-google-cloud-build-v1 - 3.5.3-SNAPSHOT + 3.5.3 grpc-google-cloud-build-v1 GRPC library for grpc-google-cloud-build-v1 com.google.cloud google-cloud-build-parent - 3.5.3-SNAPSHOT + 3.5.3 diff --git a/pom.xml b/pom.xml index 1f8b70e5..225db0ea 100644 --- a/pom.xml +++ b/pom.xml @@ -4,7 +4,7 @@ com.google.cloud google-cloud-build-parent pom - 3.5.3-SNAPSHOT + 3.5.3 Google Cloud Build Parent https://github.com/googleapis/java-cloudbuild @@ -62,17 +62,17 @@ com.google.api.grpc proto-google-cloud-build-v1 - 3.5.3-SNAPSHOT + 3.5.3 com.google.cloud google-cloud-build - 3.5.3-SNAPSHOT + 3.5.3 com.google.api.grpc grpc-google-cloud-build-v1 - 3.5.3-SNAPSHOT + 3.5.3 diff --git a/proto-google-cloud-build-v1/pom.xml b/proto-google-cloud-build-v1/pom.xml index 2219eb08..f4589a4a 100644 --- a/proto-google-cloud-build-v1/pom.xml +++ b/proto-google-cloud-build-v1/pom.xml @@ -4,13 +4,13 @@ 4.0.0 com.google.api.grpc proto-google-cloud-build-v1 - 3.5.3-SNAPSHOT + 3.5.3 proto-google-cloud-build-v1 PROTO library for proto-google-cloud-build-v1 com.google.cloud google-cloud-build-parent - 3.5.3-SNAPSHOT + 3.5.3 diff --git a/versions.txt b/versions.txt index 9263690b..da0374b0 100644 --- a/versions.txt +++ b/versions.txt @@ -1,6 +1,6 @@ # Format: # module:released-version:current-version -google-cloud-build:3.5.2:3.5.3-SNAPSHOT -grpc-google-cloud-build-v1:3.5.2:3.5.3-SNAPSHOT -proto-google-cloud-build-v1:3.5.2:3.5.3-SNAPSHOT +google-cloud-build:3.5.3:3.5.3 +grpc-google-cloud-build-v1:3.5.3:3.5.3 +proto-google-cloud-build-v1:3.5.3:3.5.3 From d7caba6cc11960d0d71159de9143f6584feafd52 Mon Sep 17 00:00:00 2001 From: "release-please[bot]" <55107282+release-please[bot]@users.noreply.github.com> Date: Fri, 9 Sep 2022 15:02:13 +0000 Subject: [PATCH 04/38] chore(main): release 3.5.4-SNAPSHOT (#789) :robot: I have created a release *beep* *boop* --- ### Updating meta-information for bleeding-edge SNAPSHOT release. --- This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please). --- google-cloud-build-bom/pom.xml | 8 ++++---- google-cloud-build/pom.xml | 4 ++-- grpc-google-cloud-build-v1/pom.xml | 4 ++-- pom.xml | 8 ++++---- proto-google-cloud-build-v1/pom.xml | 4 ++-- versions.txt | 6 +++--- 6 files changed, 17 insertions(+), 17 deletions(-) diff --git a/google-cloud-build-bom/pom.xml b/google-cloud-build-bom/pom.xml index a7ba302c..f2f01603 100644 --- a/google-cloud-build-bom/pom.xml +++ b/google-cloud-build-bom/pom.xml @@ -3,7 +3,7 @@ 4.0.0 com.google.cloud google-cloud-build-bom - 3.5.3 + 3.5.4-SNAPSHOT pom com.google.cloud @@ -52,17 +52,17 @@ com.google.cloud google-cloud-build - 3.5.3 + 3.5.4-SNAPSHOT com.google.api.grpc grpc-google-cloud-build-v1 - 3.5.3 + 3.5.4-SNAPSHOT com.google.api.grpc proto-google-cloud-build-v1 - 3.5.3 + 3.5.4-SNAPSHOT diff --git a/google-cloud-build/pom.xml b/google-cloud-build/pom.xml index 904c711a..be5b43d7 100644 --- a/google-cloud-build/pom.xml +++ b/google-cloud-build/pom.xml @@ -3,7 +3,7 @@ 4.0.0 com.google.cloud google-cloud-build - 3.5.3 + 3.5.4-SNAPSHOT jar Google Cloud Build https://github.com/googleapis/java-cloudbuild @@ -13,7 +13,7 @@ com.google.cloud google-cloud-build-parent - 3.5.3 + 3.5.4-SNAPSHOT google-cloud-build diff --git a/grpc-google-cloud-build-v1/pom.xml b/grpc-google-cloud-build-v1/pom.xml index 2d06bb32..c646b2d2 100644 --- a/grpc-google-cloud-build-v1/pom.xml +++ b/grpc-google-cloud-build-v1/pom.xml @@ -4,13 +4,13 @@ 4.0.0 com.google.api.grpc grpc-google-cloud-build-v1 - 3.5.3 + 3.5.4-SNAPSHOT grpc-google-cloud-build-v1 GRPC library for grpc-google-cloud-build-v1 com.google.cloud google-cloud-build-parent - 3.5.3 + 3.5.4-SNAPSHOT diff --git a/pom.xml b/pom.xml index 225db0ea..415be23a 100644 --- a/pom.xml +++ b/pom.xml @@ -4,7 +4,7 @@ com.google.cloud google-cloud-build-parent pom - 3.5.3 + 3.5.4-SNAPSHOT Google Cloud Build Parent https://github.com/googleapis/java-cloudbuild @@ -62,17 +62,17 @@ com.google.api.grpc proto-google-cloud-build-v1 - 3.5.3 + 3.5.4-SNAPSHOT com.google.cloud google-cloud-build - 3.5.3 + 3.5.4-SNAPSHOT com.google.api.grpc grpc-google-cloud-build-v1 - 3.5.3 + 3.5.4-SNAPSHOT diff --git a/proto-google-cloud-build-v1/pom.xml b/proto-google-cloud-build-v1/pom.xml index f4589a4a..cb0b25cb 100644 --- a/proto-google-cloud-build-v1/pom.xml +++ b/proto-google-cloud-build-v1/pom.xml @@ -4,13 +4,13 @@ 4.0.0 com.google.api.grpc proto-google-cloud-build-v1 - 3.5.3 + 3.5.4-SNAPSHOT proto-google-cloud-build-v1 PROTO library for proto-google-cloud-build-v1 com.google.cloud google-cloud-build-parent - 3.5.3 + 3.5.4-SNAPSHOT diff --git a/versions.txt b/versions.txt index da0374b0..592e394a 100644 --- a/versions.txt +++ b/versions.txt @@ -1,6 +1,6 @@ # Format: # module:released-version:current-version -google-cloud-build:3.5.3:3.5.3 -grpc-google-cloud-build-v1:3.5.3:3.5.3 -proto-google-cloud-build-v1:3.5.3:3.5.3 +google-cloud-build:3.5.3:3.5.4-SNAPSHOT +grpc-google-cloud-build-v1:3.5.3:3.5.4-SNAPSHOT +proto-google-cloud-build-v1:3.5.3:3.5.4-SNAPSHOT From 8b66c5a43519dc22671651663a65a74f869f1707 Mon Sep 17 00:00:00 2001 From: "gcf-owl-bot[bot]" <78513119+gcf-owl-bot[bot]@users.noreply.github.com> Date: Fri, 9 Sep 2022 15:08:43 +0000 Subject: [PATCH 05/38] chore(bazel): Update WORKSPACE files for rules_gapic, gax_java, generator_java versions (#786) - [ ] Regenerate this pull request now. PiperOrigin-RevId: 472750037 Source-Link: https://github.com/googleapis/googleapis/commit/88f2ea3f53b9712f2e04f28f06210f6f77fa7e24 Source-Link: https://github.com/googleapis/googleapis-gen/commit/230a5588306aae18fe8f2a57f14d4039ad72c901 Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiMjMwYTU1ODgzMDZhYWUxOGZlOGYyYTU3ZjE0ZDQwMzlhZDcyYzkwMSJ9 --- README.md | 6 +- .../cloudbuild/v1/CloudBuildClient.java | 497 +++++++++++++----- .../cloudbuild/v1/CloudBuildSettings.java | 12 +- .../devtools/cloudbuild/v1/package-info.java | 7 +- .../v1/stub/CloudBuildStubSettings.java | 12 +- .../v1/stub/HttpJsonCloudBuildStub.java | 27 +- 6 files changed, 392 insertions(+), 169 deletions(-) diff --git a/README.md b/README.md index a9072da4..d49d947e 100644 --- a/README.md +++ b/README.md @@ -19,20 +19,20 @@ If you are using Maven, add this to your pom.xml file: com.google.cloud google-cloud-build - 3.5.2 + 3.5.3 ``` If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-build:3.5.2' +implementation 'com.google.cloud:google-cloud-build:3.5.3' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-build" % "3.5.2" +libraryDependencies += "com.google.cloud" % "google-cloud-build" % "3.5.3" ``` ## Authentication diff --git a/google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/CloudBuildClient.java b/google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/CloudBuildClient.java index e138c8dc..b251a531 100644 --- a/google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/CloudBuildClient.java +++ b/google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/CloudBuildClient.java @@ -86,8 +86,11 @@ * calls that map to API methods. Sample code to get started: * *
{@code
- * // This snippet has been automatically generated for illustrative purposes only.
- * // It may require modifications to work in your environment.
+ * // This snippet has been automatically generated and should be regarded as a code template only.
+ * // It will require modifications to work:
+ * // - It may require correct/in-range values for request initialization.
+ * // - It may require specifying regional endpoints when creating the service client as shown in
+ * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
  * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
  *   String projectId = "projectId-894832108";
  *   String id = "id3355";
@@ -124,8 +127,11 @@
  * 

To customize credentials: * *

{@code
- * // This snippet has been automatically generated for illustrative purposes only.
- * // It may require modifications to work in your environment.
+ * // This snippet has been automatically generated and should be regarded as a code template only.
+ * // It will require modifications to work:
+ * // - It may require correct/in-range values for request initialization.
+ * // - It may require specifying regional endpoints when creating the service client as shown in
+ * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
  * CloudBuildSettings cloudBuildSettings =
  *     CloudBuildSettings.newBuilder()
  *         .setCredentialsProvider(FixedCredentialsProvider.create(myCredentials))
@@ -136,8 +142,11 @@
  * 

To customize the endpoint: * *

{@code
- * // This snippet has been automatically generated for illustrative purposes only.
- * // It may require modifications to work in your environment.
+ * // This snippet has been automatically generated and should be regarded as a code template only.
+ * // It will require modifications to work:
+ * // - It may require correct/in-range values for request initialization.
+ * // - It may require specifying regional endpoints when creating the service client as shown in
+ * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
  * CloudBuildSettings cloudBuildSettings =
  *     CloudBuildSettings.newBuilder().setEndpoint(myEndpoint).build();
  * CloudBuildClient cloudBuildClient = CloudBuildClient.create(cloudBuildSettings);
@@ -147,8 +156,11 @@
  * the wire:
  *
  * 
{@code
- * // This snippet has been automatically generated for illustrative purposes only.
- * // It may require modifications to work in your environment.
+ * // This snippet has been automatically generated and should be regarded as a code template only.
+ * // It will require modifications to work:
+ * // - It may require correct/in-range values for request initialization.
+ * // - It may require specifying regional endpoints when creating the service client as shown in
+ * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
  * CloudBuildSettings cloudBuildSettings =
  *     CloudBuildSettings.newBuilder()
  *         .setTransportChannelProvider(
@@ -242,8 +254,11 @@ public final OperationsClient getHttpJsonOperationsClient() {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   String projectId = "projectId-894832108";
    *   Build build = Build.newBuilder().build();
@@ -272,8 +287,11 @@ public final OperationFuture createBuildAsync(
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   CreateBuildRequest request =
    *       CreateBuildRequest.newBuilder()
@@ -303,8 +321,11 @@ public final OperationFuture createBuildAsync(
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   CreateBuildRequest request =
    *       CreateBuildRequest.newBuilder()
@@ -334,8 +355,11 @@ public final OperationFuture createBuildAsync(
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   CreateBuildRequest request =
    *       CreateBuildRequest.newBuilder()
@@ -363,8 +387,11 @@ public final UnaryCallable createBuildCallable()
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   String projectId = "projectId-894832108";
    *   String id = "id3355";
@@ -392,8 +419,11 @@ public final Build getBuild(String projectId, String id) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   GetBuildRequest request =
    *       GetBuildRequest.newBuilder()
@@ -422,8 +452,11 @@ public final Build getBuild(GetBuildRequest request) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   GetBuildRequest request =
    *       GetBuildRequest.newBuilder()
@@ -451,8 +484,11 @@ public final UnaryCallable getBuildCallable() {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   String projectId = "projectId-894832108";
    *   String filter = "filter-1274492040";
@@ -482,8 +518,11 @@ public final ListBuildsPagedResponse listBuilds(String projectId, String filter)
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   ListBuildsRequest request =
    *       ListBuildsRequest.newBuilder()
@@ -516,8 +555,11 @@ public final ListBuildsPagedResponse listBuilds(ListBuildsRequest request) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   ListBuildsRequest request =
    *       ListBuildsRequest.newBuilder()
@@ -549,8 +591,11 @@ public final UnaryCallable listBuild
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   ListBuildsRequest request =
    *       ListBuildsRequest.newBuilder()
@@ -586,8 +631,11 @@ public final UnaryCallable listBuildsCall
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   String projectId = "projectId-894832108";
    *   String id = "id3355";
@@ -612,8 +660,11 @@ public final Build cancelBuild(String projectId, String id) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   CancelBuildRequest request =
    *       CancelBuildRequest.newBuilder()
@@ -639,8 +690,11 @@ public final Build cancelBuild(CancelBuildRequest request) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   CancelBuildRequest request =
    *       CancelBuildRequest.newBuilder()
@@ -695,8 +749,11 @@ public final UnaryCallable cancelBuildCallable() {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   String projectId = "projectId-894832108";
    *   String id = "id3355";
@@ -752,8 +809,11 @@ public final OperationFuture retryBuildAsync(
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   RetryBuildRequest request =
    *       RetryBuildRequest.newBuilder()
@@ -810,8 +870,11 @@ public final OperationFuture retryBuildAsync(
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   RetryBuildRequest request =
    *       RetryBuildRequest.newBuilder()
@@ -868,8 +931,11 @@ public final OperationFuture retryBuildAsync(
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   RetryBuildRequest request =
    *       RetryBuildRequest.newBuilder()
@@ -898,8 +964,11 @@ public final UnaryCallable retryBuildCallable() {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   String name = "name3373707";
    *   ApprovalResult approvalResult = ApprovalResult.newBuilder().build();
@@ -930,8 +999,11 @@ public final OperationFuture approveBuildAsync(
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   ApproveBuildRequest request =
    *       ApproveBuildRequest.newBuilder()
@@ -961,8 +1033,11 @@ public final OperationFuture approveBuildAsync(
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   ApproveBuildRequest request =
    *       ApproveBuildRequest.newBuilder()
@@ -992,8 +1067,11 @@ public final OperationFuture approveBuildAsync(
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   ApproveBuildRequest request =
    *       ApproveBuildRequest.newBuilder()
@@ -1019,8 +1097,11 @@ public final UnaryCallable approveBuildCallable(
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   String projectId = "projectId-894832108";
    *   BuildTrigger trigger = BuildTrigger.newBuilder().build();
@@ -1047,8 +1128,11 @@ public final BuildTrigger createBuildTrigger(String projectId, BuildTrigger trig
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   CreateBuildTriggerRequest request =
    *       CreateBuildTriggerRequest.newBuilder()
@@ -1076,8 +1160,11 @@ public final BuildTrigger createBuildTrigger(CreateBuildTriggerRequest request)
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   CreateBuildTriggerRequest request =
    *       CreateBuildTriggerRequest.newBuilder()
@@ -1105,8 +1192,11 @@ public final UnaryCallable createBuildT
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   String projectId = "projectId-894832108";
    *   String triggerId = "triggerId-648752909";
@@ -1133,8 +1223,11 @@ public final BuildTrigger getBuildTrigger(String projectId, String triggerId) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   GetBuildTriggerRequest request =
    *       GetBuildTriggerRequest.newBuilder()
@@ -1162,8 +1255,11 @@ public final BuildTrigger getBuildTrigger(GetBuildTriggerRequest request) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   GetBuildTriggerRequest request =
    *       GetBuildTriggerRequest.newBuilder()
@@ -1191,8 +1287,11 @@ public final UnaryCallable getBuildTrigger
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   String projectId = "projectId-894832108";
    *   for (BuildTrigger element : cloudBuildClient.listBuildTriggers(projectId).iterateAll()) {
@@ -1219,8 +1318,11 @@ public final ListBuildTriggersPagedResponse listBuildTriggers(String projectId)
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   ListBuildTriggersRequest request =
    *       ListBuildTriggersRequest.newBuilder()
@@ -1251,8 +1353,11 @@ public final ListBuildTriggersPagedResponse listBuildTriggers(ListBuildTriggersR
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   ListBuildTriggersRequest request =
    *       ListBuildTriggersRequest.newBuilder()
@@ -1284,8 +1389,11 @@ public final ListBuildTriggersPagedResponse listBuildTriggers(ListBuildTriggersR
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   ListBuildTriggersRequest request =
    *       ListBuildTriggersRequest.newBuilder()
@@ -1324,8 +1432,11 @@ public final ListBuildTriggersPagedResponse listBuildTriggers(ListBuildTriggersR
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   String projectId = "projectId-894832108";
    *   String triggerId = "triggerId-648752909";
@@ -1355,8 +1466,11 @@ public final void deleteBuildTrigger(String projectId, String triggerId) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   DeleteBuildTriggerRequest request =
    *       DeleteBuildTriggerRequest.newBuilder()
@@ -1384,8 +1498,11 @@ public final void deleteBuildTrigger(DeleteBuildTriggerRequest request) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   DeleteBuildTriggerRequest request =
    *       DeleteBuildTriggerRequest.newBuilder()
@@ -1412,8 +1529,11 @@ public final UnaryCallable deleteBuildTriggerC
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   String projectId = "projectId-894832108";
    *   String triggerId = "triggerId-648752909";
@@ -1447,8 +1567,11 @@ public final BuildTrigger updateBuildTrigger(
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   UpdateBuildTriggerRequest request =
    *       UpdateBuildTriggerRequest.newBuilder()
@@ -1476,8 +1599,11 @@ public final BuildTrigger updateBuildTrigger(UpdateBuildTriggerRequest request)
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   UpdateBuildTriggerRequest request =
    *       UpdateBuildTriggerRequest.newBuilder()
@@ -1503,8 +1629,11 @@ public final UnaryCallable updateBuildT
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   String projectId = "projectId-894832108";
    *   String triggerId = "triggerId-648752909";
@@ -1536,8 +1665,11 @@ public final OperationFuture runBuildTriggerAsync
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   RunBuildTriggerRequest request =
    *       RunBuildTriggerRequest.newBuilder()
@@ -1565,8 +1697,11 @@ public final OperationFuture runBuildTriggerAsync
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   RunBuildTriggerRequest request =
    *       RunBuildTriggerRequest.newBuilder()
@@ -1594,8 +1729,11 @@ public final OperationFuture runBuildTriggerAsync
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   RunBuildTriggerRequest request =
    *       RunBuildTriggerRequest.newBuilder()
@@ -1622,8 +1760,11 @@ public final UnaryCallable runBuildTriggerCal
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   ReceiveTriggerWebhookRequest request =
    *       ReceiveTriggerWebhookRequest.newBuilder()
@@ -1653,8 +1794,11 @@ public final ReceiveTriggerWebhookResponse receiveTriggerWebhook(
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   ReceiveTriggerWebhookRequest request =
    *       ReceiveTriggerWebhookRequest.newBuilder()
@@ -1683,8 +1827,11 @@ public final ReceiveTriggerWebhookResponse receiveTriggerWebhook(
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
    *   WorkerPool workerPool = WorkerPool.newBuilder().build();
@@ -1720,8 +1867,11 @@ public final OperationFuture crea
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
    *   WorkerPool workerPool = WorkerPool.newBuilder().build();
@@ -1757,8 +1907,11 @@ public final OperationFuture crea
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   CreateWorkerPoolRequest request =
    *       CreateWorkerPoolRequest.newBuilder()
@@ -1786,8 +1939,11 @@ public final OperationFuture crea
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   CreateWorkerPoolRequest request =
    *       CreateWorkerPoolRequest.newBuilder()
@@ -1816,8 +1972,11 @@ public final OperationFuture crea
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   CreateWorkerPoolRequest request =
    *       CreateWorkerPoolRequest.newBuilder()
@@ -1843,8 +2002,11 @@ public final UnaryCallable createWorkerPoolC
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   WorkerPoolName name = WorkerPoolName.of("[PROJECT]", "[LOCATION]", "[WORKER_POOL]");
    *   WorkerPool response = cloudBuildClient.getWorkerPool(name);
@@ -1868,8 +2030,11 @@ public final WorkerPool getWorkerPool(WorkerPoolName name) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   String name = WorkerPoolName.of("[PROJECT]", "[LOCATION]", "[WORKER_POOL]").toString();
    *   WorkerPool response = cloudBuildClient.getWorkerPool(name);
@@ -1892,8 +2057,11 @@ public final WorkerPool getWorkerPool(String name) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   GetWorkerPoolRequest request =
    *       GetWorkerPoolRequest.newBuilder()
@@ -1917,8 +2085,11 @@ public final WorkerPool getWorkerPool(GetWorkerPoolRequest request) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   GetWorkerPoolRequest request =
    *       GetWorkerPoolRequest.newBuilder()
@@ -1941,8 +2112,11 @@ public final UnaryCallable getWorkerPoolCallab
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   WorkerPoolName name = WorkerPoolName.of("[PROJECT]", "[LOCATION]", "[WORKER_POOL]");
    *   cloudBuildClient.deleteWorkerPoolAsync(name).get();
@@ -1967,8 +2141,11 @@ public final OperationFuture deleteWor
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   String name = WorkerPoolName.of("[PROJECT]", "[LOCATION]", "[WORKER_POOL]").toString();
    *   cloudBuildClient.deleteWorkerPoolAsync(name).get();
@@ -1992,8 +2169,11 @@ public final OperationFuture deleteWor
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   DeleteWorkerPoolRequest request =
    *       DeleteWorkerPoolRequest.newBuilder()
@@ -2021,8 +2201,11 @@ public final OperationFuture deleteWor
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   DeleteWorkerPoolRequest request =
    *       DeleteWorkerPoolRequest.newBuilder()
@@ -2050,8 +2233,11 @@ public final OperationFuture deleteWor
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   DeleteWorkerPoolRequest request =
    *       DeleteWorkerPoolRequest.newBuilder()
@@ -2077,8 +2263,11 @@ public final UnaryCallable deleteWorkerPoolC
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   WorkerPool workerPool = WorkerPool.newBuilder().build();
    *   FieldMask updateMask = FieldMask.newBuilder().build();
@@ -2109,8 +2298,11 @@ public final OperationFuture upda
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   UpdateWorkerPoolRequest request =
    *       UpdateWorkerPoolRequest.newBuilder()
@@ -2137,8 +2329,11 @@ public final OperationFuture upda
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   UpdateWorkerPoolRequest request =
    *       UpdateWorkerPoolRequest.newBuilder()
@@ -2166,8 +2361,11 @@ public final OperationFuture upda
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   UpdateWorkerPoolRequest request =
    *       UpdateWorkerPoolRequest.newBuilder()
@@ -2192,8 +2390,11 @@ public final UnaryCallable updateWorkerPoolC
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
    *   for (WorkerPool element : cloudBuildClient.listWorkerPools(parent).iterateAll()) {
@@ -2221,8 +2422,11 @@ public final ListWorkerPoolsPagedResponse listWorkerPools(LocationName parent) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
    *   for (WorkerPool element : cloudBuildClient.listWorkerPools(parent).iterateAll()) {
@@ -2247,8 +2451,11 @@ public final ListWorkerPoolsPagedResponse listWorkerPools(String parent) {
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   ListWorkerPoolsRequest request =
    *       ListWorkerPoolsRequest.newBuilder()
@@ -2276,8 +2483,11 @@ public final ListWorkerPoolsPagedResponse listWorkerPools(ListWorkerPoolsRequest
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   ListWorkerPoolsRequest request =
    *       ListWorkerPoolsRequest.newBuilder()
@@ -2306,8 +2516,11 @@ public final ListWorkerPoolsPagedResponse listWorkerPools(ListWorkerPoolsRequest
    * 

Sample code: * *

{@code
-   * // This snippet has been automatically generated for illustrative purposes only.
-   * // It may require modifications to work in your environment.
+   * // This snippet has been automatically generated and should be regarded as a code template only.
+   * // It will require modifications to work:
+   * // - It may require correct/in-range values for request initialization.
+   * // - It may require specifying regional endpoints when creating the service client as shown in
+   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
    * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
    *   ListWorkerPoolsRequest request =
    *       ListWorkerPoolsRequest.newBuilder()
diff --git a/google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/CloudBuildSettings.java b/google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/CloudBuildSettings.java
index b7e9d24e..ce32e376 100644
--- a/google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/CloudBuildSettings.java
+++ b/google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/CloudBuildSettings.java
@@ -87,16 +87,16 @@
  * 

For example, to set the total timeout of getBuild to 30 seconds: * *

{@code
- * // This snippet has been automatically generated for illustrative purposes only.
- * // It may require modifications to work in your environment.
+ * // This snippet has been automatically generated and should be regarded as a code template only.
+ * // It will require modifications to work:
+ * // - It may require correct/in-range values for request initialization.
+ * // - It may require specifying regional endpoints when creating the service client as shown in
+ * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
  * CloudBuildSettings.Builder cloudBuildSettingsBuilder = CloudBuildSettings.newBuilder();
  * cloudBuildSettingsBuilder
  *     .getBuildSettings()
  *     .setRetrySettings(
- *         cloudBuildSettingsBuilder
- *             .getBuildSettings()
- *             .getRetrySettings()
- *             .toBuilder()
+ *         cloudBuildSettingsBuilder.getBuildSettings().getRetrySettings().toBuilder()
  *             .setTotalTimeout(Duration.ofSeconds(30))
  *             .build());
  * CloudBuildSettings cloudBuildSettings = cloudBuildSettingsBuilder.build();
diff --git a/google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/package-info.java b/google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/package-info.java
index 12351c3f..6bb314aa 100644
--- a/google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/package-info.java
+++ b/google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/package-info.java
@@ -30,8 +30,11 @@
  * 

Sample for CloudBuildClient: * *

{@code
- * // This snippet has been automatically generated for illustrative purposes only.
- * // It may require modifications to work in your environment.
+ * // This snippet has been automatically generated and should be regarded as a code template only.
+ * // It will require modifications to work:
+ * // - It may require correct/in-range values for request initialization.
+ * // - It may require specifying regional endpoints when creating the service client as shown in
+ * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
  * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
  *   String projectId = "projectId-894832108";
  *   String id = "id3355";
diff --git a/google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/stub/CloudBuildStubSettings.java b/google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/stub/CloudBuildStubSettings.java
index d9d92243..7c7f1446 100644
--- a/google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/stub/CloudBuildStubSettings.java
+++ b/google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/stub/CloudBuildStubSettings.java
@@ -107,16 +107,16 @@
  * 

For example, to set the total timeout of getBuild to 30 seconds: * *

{@code
- * // This snippet has been automatically generated for illustrative purposes only.
- * // It may require modifications to work in your environment.
+ * // This snippet has been automatically generated and should be regarded as a code template only.
+ * // It will require modifications to work:
+ * // - It may require correct/in-range values for request initialization.
+ * // - It may require specifying regional endpoints when creating the service client as shown in
+ * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
  * CloudBuildStubSettings.Builder cloudBuildSettingsBuilder = CloudBuildStubSettings.newBuilder();
  * cloudBuildSettingsBuilder
  *     .getBuildSettings()
  *     .setRetrySettings(
- *         cloudBuildSettingsBuilder
- *             .getBuildSettings()
- *             .getRetrySettings()
- *             .toBuilder()
+ *         cloudBuildSettingsBuilder.getBuildSettings().getRetrySettings().toBuilder()
  *             .setTotalTimeout(Duration.ofSeconds(30))
  *             .build());
  * CloudBuildStubSettings cloudBuildSettings = cloudBuildSettingsBuilder.build();
diff --git a/google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/stub/HttpJsonCloudBuildStub.java b/google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/stub/HttpJsonCloudBuildStub.java
index 0fd6b501..9ecc4e78 100644
--- a/google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/stub/HttpJsonCloudBuildStub.java
+++ b/google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/stub/HttpJsonCloudBuildStub.java
@@ -123,7 +123,8 @@ public class HttpJsonCloudBuildStub extends CloudBuildStub {
                           })
                       .setRequestBodyExtractor(
                           request ->
-                              ProtoRestSerializer.create().toBody("build", request.getBuild()))
+                              ProtoRestSerializer.create()
+                                  .toBody("build", request.getBuild(), false))
                       .build())
               .setResponseParser(
                   ProtoMessageResponseParser.newBuilder()
@@ -244,7 +245,8 @@ public class HttpJsonCloudBuildStub extends CloudBuildStub {
                                       .clearId()
                                       .clearName()
                                       .clearProjectId()
-                                      .build()))
+                                      .build(),
+                                  false))
                   .build())
           .setResponseParser(
               ProtoMessageResponseParser.newBuilder()
@@ -290,7 +292,8 @@ public class HttpJsonCloudBuildStub extends CloudBuildStub {
                                           .clearId()
                                           .clearName()
                                           .clearProjectId()
-                                          .build()))
+                                          .build(),
+                                      false))
                       .build())
               .setResponseParser(
                   ProtoMessageResponseParser.newBuilder()
@@ -330,7 +333,7 @@ public class HttpJsonCloudBuildStub extends CloudBuildStub {
                       .setRequestBodyExtractor(
                           request ->
                               ProtoRestSerializer.create()
-                                  .toBody("*", request.toBuilder().clearName().build()))
+                                  .toBody("*", request.toBuilder().clearName().build(), false))
                       .build())
               .setResponseParser(
                   ProtoMessageResponseParser.newBuilder()
@@ -370,7 +373,8 @@ public class HttpJsonCloudBuildStub extends CloudBuildStub {
                           })
                       .setRequestBodyExtractor(
                           request ->
-                              ProtoRestSerializer.create().toBody("trigger", request.getTrigger()))
+                              ProtoRestSerializer.create()
+                                  .toBody("trigger", request.getTrigger(), false))
                       .build())
               .setResponseParser(
                   ProtoMessageResponseParser.newBuilder()
@@ -521,7 +525,8 @@ public class HttpJsonCloudBuildStub extends CloudBuildStub {
                           })
                       .setRequestBodyExtractor(
                           request ->
-                              ProtoRestSerializer.create().toBody("trigger", request.getTrigger()))
+                              ProtoRestSerializer.create()
+                                  .toBody("trigger", request.getTrigger(), false))
                       .build())
               .setResponseParser(
                   ProtoMessageResponseParser.newBuilder()
@@ -559,7 +564,8 @@ public class HttpJsonCloudBuildStub extends CloudBuildStub {
                           })
                       .setRequestBodyExtractor(
                           request ->
-                              ProtoRestSerializer.create().toBody("source", request.getSource()))
+                              ProtoRestSerializer.create()
+                                  .toBody("source", request.getSource(), false))
                       .build())
               .setResponseParser(
                   ProtoMessageResponseParser.newBuilder()
@@ -602,7 +608,8 @@ public class HttpJsonCloudBuildStub extends CloudBuildStub {
                             return fields;
                           })
                       .setRequestBodyExtractor(
-                          request -> ProtoRestSerializer.create().toBody("body", request.getBody()))
+                          request ->
+                              ProtoRestSerializer.create().toBody("body", request.getBody(), false))
                       .build())
               .setResponseParser(
                   ProtoMessageResponseParser.newBuilder()
@@ -642,7 +649,7 @@ public class HttpJsonCloudBuildStub extends CloudBuildStub {
                       .setRequestBodyExtractor(
                           request ->
                               ProtoRestSerializer.create()
-                                  .toBody("workerPool", request.getWorkerPool()))
+                                  .toBody("workerPool", request.getWorkerPool(), false))
                       .build())
               .setResponseParser(
                   ProtoMessageResponseParser.newBuilder()
@@ -759,7 +766,7 @@ public class HttpJsonCloudBuildStub extends CloudBuildStub {
                       .setRequestBodyExtractor(
                           request ->
                               ProtoRestSerializer.create()
-                                  .toBody("workerPool", request.getWorkerPool()))
+                                  .toBody("workerPool", request.getWorkerPool(), false))
                       .build())
               .setResponseParser(
                   ProtoMessageResponseParser.newBuilder()

From ddba57bced69fe8a22bd1df9edb59a7467e19250 Mon Sep 17 00:00:00 2001
From: WhiteSource Renovate 
Date: Fri, 9 Sep 2022 17:54:14 +0200
Subject: [PATCH 06/38] chore(deps): update dependency
 com.google.cloud:google-cloud-build to v3.5.3 (#790)
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

[![Mend Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com)

This PR contains the following updates:

| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
| [com.google.cloud:google-cloud-build](https://togithub.com/googleapis/java-cloudbuild) | `3.5.2` -> `3.5.3` | [![age](https://badges.renovateapi.com/packages/maven/com.google.cloud:google-cloud-build/3.5.3/age-slim)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://badges.renovateapi.com/packages/maven/com.google.cloud:google-cloud-build/3.5.3/adoption-slim)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://badges.renovateapi.com/packages/maven/com.google.cloud:google-cloud-build/3.5.3/compatibility-slim/3.5.2)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://badges.renovateapi.com/packages/maven/com.google.cloud:google-cloud-build/3.5.3/confidence-slim/3.5.2)](https://docs.renovatebot.com/merge-confidence/) |

---

### Configuration

📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).

🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied.

♻ **Rebasing**: Renovate will not automatically rebase this PR, because other commits have been found.

🔕 **Ignore**: Close this PR and you won't be reminded about these updates again.

---

 - [ ] If you want to rebase/retry this PR, click this checkbox. ⚠ **Warning**: custom changes will be lost.

---

This PR has been generated by [Mend Renovate](https://www.mend.io/free-developer-tools/renovate/). View repository job log [here](https://app.renovatebot.com/dashboard#github/googleapis/java-cloudbuild).

---
 samples/install-without-bom/pom.xml | 2 +-
 samples/snapshot/pom.xml            | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/samples/install-without-bom/pom.xml b/samples/install-without-bom/pom.xml
index 46d67f2a..43c6d832 100644
--- a/samples/install-without-bom/pom.xml
+++ b/samples/install-without-bom/pom.xml
@@ -29,7 +29,7 @@
     
       com.google.cloud
       google-cloud-build
-      3.5.2
+      3.5.3
     
     
 
diff --git a/samples/snapshot/pom.xml b/samples/snapshot/pom.xml
index 2af1c66b..7db950f5 100644
--- a/samples/snapshot/pom.xml
+++ b/samples/snapshot/pom.xml
@@ -28,7 +28,7 @@
     
       com.google.cloud
       google-cloud-build
-      3.5.2
+      3.5.3
     
 
     

From 6611778f3e081d0b300f308035d309e9390103f7 Mon Sep 17 00:00:00 2001
From: "gcf-owl-bot[bot]" <78513119+gcf-owl-bot[bot]@users.noreply.github.com>
Date: Sat, 10 Sep 2022 02:12:16 +0000
Subject: [PATCH 07/38] chore: Generated snippets should not be owned by
 samples reviewers (#1575) (#791)

Source-Link: https://github.com/googleapis/synthtool/commit/2e9ac19d5b8181af77cdc5337cf922517813cc49
Post-Processor: gcr.io/cloud-devrel-public-resources/owlbot-java:latest@sha256:8175681a918181d306d9c370d3262f16b4c724cc73d74111b7d42fc985ca7f93
---
 .github/.OwlBot.lock.yaml | 3 +--
 .github/CODEOWNERS        | 3 +++
 2 files changed, 4 insertions(+), 2 deletions(-)

diff --git a/.github/.OwlBot.lock.yaml b/.github/.OwlBot.lock.yaml
index f8b912ad..62592923 100644
--- a/.github/.OwlBot.lock.yaml
+++ b/.github/.OwlBot.lock.yaml
@@ -13,5 +13,4 @@
 # limitations under the License.
 docker:
   image: gcr.io/cloud-devrel-public-resources/owlbot-java:latest
-  digest: sha256:b47e411068ffc6e6990cb4e0802fbac9a4488dec7f5f424553518ba21abea208
-# created: 2022-07-26T16:25:31.033836225Z
+  digest: sha256:8175681a918181d306d9c370d3262f16b4c724cc73d74111b7d42fc985ca7f93
diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS
index 1578dc2f..5232f38f 100644
--- a/.github/CODEOWNERS
+++ b/.github/CODEOWNERS
@@ -10,3 +10,6 @@
 
 # The java-samples-reviewers team is the default owner for samples changes
 samples/**/*.java       @googleapis/java-samples-reviewers
+
+# Generated snippets should not be owned by samples reviewers
+samples/snippets/generated/       @googleapis/yoshi-java

From 31995f42ac9d4904a16f9660facf1ff82c7df2f6 Mon Sep 17 00:00:00 2001
From: WhiteSource Renovate 
Date: Thu, 15 Sep 2022 15:56:23 +0200
Subject: [PATCH 08/38] deps: update dependency
 com.google.cloud:google-cloud-shared-dependencies to v3.0.3 (#792)
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

[![Mend Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com)

This PR contains the following updates:

| Package | Change | Age | Adoption | Passing | Confidence |
|---|---|---|---|---|---|
| [com.google.cloud:google-cloud-shared-dependencies](https://togithub.com/googleapis/java-shared-dependencies) | `3.0.2` -> `3.0.3` | [![age](https://badges.renovateapi.com/packages/maven/com.google.cloud:google-cloud-shared-dependencies/3.0.3/age-slim)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://badges.renovateapi.com/packages/maven/com.google.cloud:google-cloud-shared-dependencies/3.0.3/adoption-slim)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://badges.renovateapi.com/packages/maven/com.google.cloud:google-cloud-shared-dependencies/3.0.3/compatibility-slim/3.0.2)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://badges.renovateapi.com/packages/maven/com.google.cloud:google-cloud-shared-dependencies/3.0.3/confidence-slim/3.0.2)](https://docs.renovatebot.com/merge-confidence/) |

---

### Release Notes

googleapis/java-shared-dependencies ### [`v3.0.3`](https://togithub.com/googleapis/java-shared-dependencies/blob/HEAD/CHANGELOG.md#​303-httpsgithubcomgoogleapisjava-shared-dependenciescomparev302v303-2022-09-14) [Compare Source](https://togithub.com/googleapis/java-shared-dependencies/compare/v3.0.2...v3.0.3) ##### Dependencies - Google-cloud-core 2.8.12 ([#​799](https://togithub.com/googleapis/java-shared-dependencies/issues/799)) ([1b3db8d](https://togithub.com/googleapis/java-shared-dependencies/commit/1b3db8d1e17c49ebae79fc96164fa9058e1df6e3)) - Moving gson to first-party-dependencies ([#​800](https://togithub.com/googleapis/java-shared-dependencies/issues/800)) ([a41fcc1](https://togithub.com/googleapis/java-shared-dependencies/commit/a41fcc11d32e02e5af2837561792e3919f6d4b3f)) - Update dependency com.google.protobuf:protobuf-bom to v3.21.6 ([#​797](https://togithub.com/googleapis/java-shared-dependencies/issues/797)) ([bc5fdc9](https://togithub.com/googleapis/java-shared-dependencies/commit/bc5fdc9b3af7973c28f063a9ac156fe2af562814)) - Update gax.version to v2.19.1 ([#​798](https://togithub.com/googleapis/java-shared-dependencies/issues/798)) ([84e5487](https://togithub.com/googleapis/java-shared-dependencies/commit/84e5487b2e3dce4bb60badecebde788c3cb702b8)) - Update google.core.version to v2.8.11 ([#​793](https://togithub.com/googleapis/java-shared-dependencies/issues/793)) ([63c1297](https://togithub.com/googleapis/java-shared-dependencies/commit/63c129722aa0b821031ff5b4c11004adf7b12044))
--- ### Configuration 📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. 🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] If you want to rebase/retry this PR, click this checkbox. --- This PR has been generated by [Mend Renovate](https://www.mend.io/free-developer-tools/renovate/). View repository job log [here](https://app.renovatebot.com/dashboard#github/googleapis/java-cloudbuild). --- pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pom.xml b/pom.xml index 415be23a..3f603486 100644 --- a/pom.xml +++ b/pom.xml @@ -78,7 +78,7 @@ com.google.cloud google-cloud-shared-dependencies - 3.0.2 + 3.0.3 pom import From 92f4ad7c5a1ebdffa5984cd6f4b5361390f8e5de Mon Sep 17 00:00:00 2001 From: "release-please[bot]" <55107282+release-please[bot]@users.noreply.github.com> Date: Thu, 15 Sep 2022 14:10:35 +0000 Subject: [PATCH 09/38] chore(main): release 3.5.4 (#793) :robot: I have created a release *beep* *boop* --- ## [3.5.4](https://github.com/googleapis/java-cloudbuild/compare/v3.5.3...v3.5.4) (2022-09-15) ### Dependencies * Update dependency com.google.cloud:google-cloud-shared-dependencies to v3.0.3 ([#792](https://github.com/googleapis/java-cloudbuild/issues/792)) ([31995f4](https://github.com/googleapis/java-cloudbuild/commit/31995f42ac9d4904a16f9660facf1ff82c7df2f6)) --- This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please). --- CHANGELOG.md | 7 +++++++ google-cloud-build-bom/pom.xml | 8 ++++---- google-cloud-build/pom.xml | 4 ++-- grpc-google-cloud-build-v1/pom.xml | 4 ++-- pom.xml | 8 ++++---- proto-google-cloud-build-v1/pom.xml | 4 ++-- versions.txt | 6 +++--- 7 files changed, 24 insertions(+), 17 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 3660812a..df623804 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,12 @@ # Changelog +## [3.5.4](https://github.com/googleapis/java-cloudbuild/compare/v3.5.3...v3.5.4) (2022-09-15) + + +### Dependencies + +* Update dependency com.google.cloud:google-cloud-shared-dependencies to v3.0.3 ([#792](https://github.com/googleapis/java-cloudbuild/issues/792)) ([31995f4](https://github.com/googleapis/java-cloudbuild/commit/31995f42ac9d4904a16f9660facf1ff82c7df2f6)) + ## [3.5.3](https://github.com/googleapis/java-cloudbuild/compare/v3.5.2...v3.5.3) (2022-09-09) diff --git a/google-cloud-build-bom/pom.xml b/google-cloud-build-bom/pom.xml index f2f01603..7beda4af 100644 --- a/google-cloud-build-bom/pom.xml +++ b/google-cloud-build-bom/pom.xml @@ -3,7 +3,7 @@ 4.0.0 com.google.cloud google-cloud-build-bom - 3.5.4-SNAPSHOT + 3.5.4 pom com.google.cloud @@ -52,17 +52,17 @@ com.google.cloud google-cloud-build - 3.5.4-SNAPSHOT + 3.5.4 com.google.api.grpc grpc-google-cloud-build-v1 - 3.5.4-SNAPSHOT + 3.5.4 com.google.api.grpc proto-google-cloud-build-v1 - 3.5.4-SNAPSHOT + 3.5.4 diff --git a/google-cloud-build/pom.xml b/google-cloud-build/pom.xml index be5b43d7..cc2bcdf9 100644 --- a/google-cloud-build/pom.xml +++ b/google-cloud-build/pom.xml @@ -3,7 +3,7 @@ 4.0.0 com.google.cloud google-cloud-build - 3.5.4-SNAPSHOT + 3.5.4 jar Google Cloud Build https://github.com/googleapis/java-cloudbuild @@ -13,7 +13,7 @@ com.google.cloud google-cloud-build-parent - 3.5.4-SNAPSHOT + 3.5.4 google-cloud-build diff --git a/grpc-google-cloud-build-v1/pom.xml b/grpc-google-cloud-build-v1/pom.xml index c646b2d2..3f33002e 100644 --- a/grpc-google-cloud-build-v1/pom.xml +++ b/grpc-google-cloud-build-v1/pom.xml @@ -4,13 +4,13 @@ 4.0.0 com.google.api.grpc grpc-google-cloud-build-v1 - 3.5.4-SNAPSHOT + 3.5.4 grpc-google-cloud-build-v1 GRPC library for grpc-google-cloud-build-v1 com.google.cloud google-cloud-build-parent - 3.5.4-SNAPSHOT + 3.5.4 diff --git a/pom.xml b/pom.xml index 3f603486..8eae6242 100644 --- a/pom.xml +++ b/pom.xml @@ -4,7 +4,7 @@ com.google.cloud google-cloud-build-parent pom - 3.5.4-SNAPSHOT + 3.5.4 Google Cloud Build Parent https://github.com/googleapis/java-cloudbuild @@ -62,17 +62,17 @@ com.google.api.grpc proto-google-cloud-build-v1 - 3.5.4-SNAPSHOT + 3.5.4 com.google.cloud google-cloud-build - 3.5.4-SNAPSHOT + 3.5.4 com.google.api.grpc grpc-google-cloud-build-v1 - 3.5.4-SNAPSHOT + 3.5.4 diff --git a/proto-google-cloud-build-v1/pom.xml b/proto-google-cloud-build-v1/pom.xml index cb0b25cb..94c85c5e 100644 --- a/proto-google-cloud-build-v1/pom.xml +++ b/proto-google-cloud-build-v1/pom.xml @@ -4,13 +4,13 @@ 4.0.0 com.google.api.grpc proto-google-cloud-build-v1 - 3.5.4-SNAPSHOT + 3.5.4 proto-google-cloud-build-v1 PROTO library for proto-google-cloud-build-v1 com.google.cloud google-cloud-build-parent - 3.5.4-SNAPSHOT + 3.5.4 diff --git a/versions.txt b/versions.txt index 592e394a..69de327c 100644 --- a/versions.txt +++ b/versions.txt @@ -1,6 +1,6 @@ # Format: # module:released-version:current-version -google-cloud-build:3.5.3:3.5.4-SNAPSHOT -grpc-google-cloud-build-v1:3.5.3:3.5.4-SNAPSHOT -proto-google-cloud-build-v1:3.5.3:3.5.4-SNAPSHOT +google-cloud-build:3.5.4:3.5.4 +grpc-google-cloud-build-v1:3.5.4:3.5.4 +proto-google-cloud-build-v1:3.5.4:3.5.4 From 5787c1e69b9579a46481abd07519649d0d488f19 Mon Sep 17 00:00:00 2001 From: "release-please[bot]" <55107282+release-please[bot]@users.noreply.github.com> Date: Thu, 15 Sep 2022 14:28:18 +0000 Subject: [PATCH 10/38] chore(main): release 3.5.5-SNAPSHOT (#794) :robot: I have created a release *beep* *boop* --- ### Updating meta-information for bleeding-edge SNAPSHOT release. --- This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please). --- google-cloud-build-bom/pom.xml | 8 ++++---- google-cloud-build/pom.xml | 4 ++-- grpc-google-cloud-build-v1/pom.xml | 4 ++-- pom.xml | 8 ++++---- proto-google-cloud-build-v1/pom.xml | 4 ++-- versions.txt | 6 +++--- 6 files changed, 17 insertions(+), 17 deletions(-) diff --git a/google-cloud-build-bom/pom.xml b/google-cloud-build-bom/pom.xml index 7beda4af..57ce3dcf 100644 --- a/google-cloud-build-bom/pom.xml +++ b/google-cloud-build-bom/pom.xml @@ -3,7 +3,7 @@ 4.0.0 com.google.cloud google-cloud-build-bom - 3.5.4 + 3.5.5-SNAPSHOT pom com.google.cloud @@ -52,17 +52,17 @@ com.google.cloud google-cloud-build - 3.5.4 + 3.5.5-SNAPSHOT com.google.api.grpc grpc-google-cloud-build-v1 - 3.5.4 + 3.5.5-SNAPSHOT com.google.api.grpc proto-google-cloud-build-v1 - 3.5.4 + 3.5.5-SNAPSHOT diff --git a/google-cloud-build/pom.xml b/google-cloud-build/pom.xml index cc2bcdf9..ae582361 100644 --- a/google-cloud-build/pom.xml +++ b/google-cloud-build/pom.xml @@ -3,7 +3,7 @@ 4.0.0 com.google.cloud google-cloud-build - 3.5.4 + 3.5.5-SNAPSHOT jar Google Cloud Build https://github.com/googleapis/java-cloudbuild @@ -13,7 +13,7 @@ com.google.cloud google-cloud-build-parent - 3.5.4 + 3.5.5-SNAPSHOT google-cloud-build diff --git a/grpc-google-cloud-build-v1/pom.xml b/grpc-google-cloud-build-v1/pom.xml index 3f33002e..09d8b391 100644 --- a/grpc-google-cloud-build-v1/pom.xml +++ b/grpc-google-cloud-build-v1/pom.xml @@ -4,13 +4,13 @@ 4.0.0 com.google.api.grpc grpc-google-cloud-build-v1 - 3.5.4 + 3.5.5-SNAPSHOT grpc-google-cloud-build-v1 GRPC library for grpc-google-cloud-build-v1 com.google.cloud google-cloud-build-parent - 3.5.4 + 3.5.5-SNAPSHOT diff --git a/pom.xml b/pom.xml index 8eae6242..a3ba6e6d 100644 --- a/pom.xml +++ b/pom.xml @@ -4,7 +4,7 @@ com.google.cloud google-cloud-build-parent pom - 3.5.4 + 3.5.5-SNAPSHOT Google Cloud Build Parent https://github.com/googleapis/java-cloudbuild @@ -62,17 +62,17 @@ com.google.api.grpc proto-google-cloud-build-v1 - 3.5.4 + 3.5.5-SNAPSHOT com.google.cloud google-cloud-build - 3.5.4 + 3.5.5-SNAPSHOT com.google.api.grpc grpc-google-cloud-build-v1 - 3.5.4 + 3.5.5-SNAPSHOT diff --git a/proto-google-cloud-build-v1/pom.xml b/proto-google-cloud-build-v1/pom.xml index 94c85c5e..88ebb7e2 100644 --- a/proto-google-cloud-build-v1/pom.xml +++ b/proto-google-cloud-build-v1/pom.xml @@ -4,13 +4,13 @@ 4.0.0 com.google.api.grpc proto-google-cloud-build-v1 - 3.5.4 + 3.5.5-SNAPSHOT proto-google-cloud-build-v1 PROTO library for proto-google-cloud-build-v1 com.google.cloud google-cloud-build-parent - 3.5.4 + 3.5.5-SNAPSHOT diff --git a/versions.txt b/versions.txt index 69de327c..6a771648 100644 --- a/versions.txt +++ b/versions.txt @@ -1,6 +1,6 @@ # Format: # module:released-version:current-version -google-cloud-build:3.5.4:3.5.4 -grpc-google-cloud-build-v1:3.5.4:3.5.4 -proto-google-cloud-build-v1:3.5.4:3.5.4 +google-cloud-build:3.5.4:3.5.5-SNAPSHOT +grpc-google-cloud-build-v1:3.5.4:3.5.5-SNAPSHOT +proto-google-cloud-build-v1:3.5.4:3.5.5-SNAPSHOT From ba17f811c583dcf4a62ce81b2eefe8bc882f0d97 Mon Sep 17 00:00:00 2001 From: WhiteSource Renovate Date: Tue, 20 Sep 2022 16:18:27 +0200 Subject: [PATCH 11/38] chore(deps): update dependency com.google.cloud:google-cloud-build to v3.5.4 (#795) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit [![Mend Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com) This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [com.google.cloud:google-cloud-build](https://togithub.com/googleapis/java-cloudbuild) | `3.5.3` -> `3.5.4` | [![age](https://badges.renovateapi.com/packages/maven/com.google.cloud:google-cloud-build/3.5.4/age-slim)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://badges.renovateapi.com/packages/maven/com.google.cloud:google-cloud-build/3.5.4/adoption-slim)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://badges.renovateapi.com/packages/maven/com.google.cloud:google-cloud-build/3.5.4/compatibility-slim/3.5.3)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://badges.renovateapi.com/packages/maven/com.google.cloud:google-cloud-build/3.5.4/confidence-slim/3.5.3)](https://docs.renovatebot.com/merge-confidence/) | --- ### Configuration 📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Renovate will not automatically rebase this PR, because other commits have been found. 🔕 **Ignore**: Close this PR and you won't be reminded about these updates again. --- - [ ] If you want to rebase/retry this PR, click this checkbox. ⚠ **Warning**: custom changes will be lost. --- This PR has been generated by [Mend Renovate](https://www.mend.io/free-developer-tools/renovate/). View repository job log [here](https://app.renovatebot.com/dashboard#github/googleapis/java-cloudbuild). --- README.md | 6 +++--- samples/install-without-bom/pom.xml | 2 +- samples/snapshot/pom.xml | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index d49d947e..b71cd62d 100644 --- a/README.md +++ b/README.md @@ -19,20 +19,20 @@ If you are using Maven, add this to your pom.xml file: com.google.cloud google-cloud-build - 3.5.3 + 3.5.4 ``` If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-build:3.5.3' +implementation 'com.google.cloud:google-cloud-build:3.5.4' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-build" % "3.5.3" +libraryDependencies += "com.google.cloud" % "google-cloud-build" % "3.5.4" ``` ## Authentication diff --git a/samples/install-without-bom/pom.xml b/samples/install-without-bom/pom.xml index 43c6d832..21aebf26 100644 --- a/samples/install-without-bom/pom.xml +++ b/samples/install-without-bom/pom.xml @@ -29,7 +29,7 @@ com.google.cloud google-cloud-build - 3.5.3 + 3.5.4 diff --git a/samples/snapshot/pom.xml b/samples/snapshot/pom.xml index 7db950f5..d46ebaa5 100644 --- a/samples/snapshot/pom.xml +++ b/samples/snapshot/pom.xml @@ -28,7 +28,7 @@ com.google.cloud google-cloud-build - 3.5.3 + 3.5.4 From 7028548af0d2037a6283a270106dd2ba9aa706a5 Mon Sep 17 00:00:00 2001 From: WhiteSource Renovate Date: Tue, 20 Sep 2022 17:36:35 +0200 Subject: [PATCH 12/38] chore(deps): update dependency com.google.cloud:libraries-bom to v26.1.2 (#796) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit [![Mend Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com) This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [com.google.cloud:libraries-bom](https://cloud.google.com/java/docs/bom) ([source](https://togithub.com/googleapis/java-cloud-bom)) | `26.1.1` -> `26.1.2` | [![age](https://badges.renovateapi.com/packages/maven/com.google.cloud:libraries-bom/26.1.2/age-slim)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://badges.renovateapi.com/packages/maven/com.google.cloud:libraries-bom/26.1.2/adoption-slim)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://badges.renovateapi.com/packages/maven/com.google.cloud:libraries-bom/26.1.2/compatibility-slim/26.1.1)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://badges.renovateapi.com/packages/maven/com.google.cloud:libraries-bom/26.1.2/confidence-slim/26.1.1)](https://docs.renovatebot.com/merge-confidence/) | --- ### Configuration 📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Renovate will not automatically rebase this PR, because other commits have been found. 🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] If you want to rebase/retry this PR, click this checkbox. ⚠ **Warning**: custom changes will be lost. --- This PR has been generated by [Mend Renovate](https://www.mend.io/free-developer-tools/renovate/). View repository job log [here](https://app.renovatebot.com/dashboard#github/googleapis/java-cloudbuild). --- samples/snippets/pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/samples/snippets/pom.xml b/samples/snippets/pom.xml index c42d1772..d410d759 100644 --- a/samples/snippets/pom.xml +++ b/samples/snippets/pom.xml @@ -30,7 +30,7 @@ com.google.cloud libraries-bom - 26.1.1 + 26.1.2 pom import From 32b39363efeb78596b869f681a459f4680e1efd3 Mon Sep 17 00:00:00 2001 From: "gcf-owl-bot[bot]" <78513119+gcf-owl-bot[bot]@users.noreply.github.com> Date: Mon, 26 Sep 2022 21:54:26 +0000 Subject: [PATCH 13/38] chore: pin versions of dependencies for compatibility with Python 3.6 (#1588) (#797) * chore: pin versions of dependencies for compatibility with Python 3.6 * fix path of requirements file in synthtool Source-Link: https://github.com/googleapis/synthtool/commit/69cdb47824170d0b02bf694649ce66613c889040 Post-Processor: gcr.io/cloud-devrel-public-resources/owlbot-java:latest@sha256:6566dc8226f20993af18e5a4e7a2b1ba85a292b02dedb6a1634cf10e1b418fa5 --- .github/.OwlBot.lock.yaml | 2 +- .kokoro/release/publish_javadoc.sh | 2 +- .kokoro/release/publish_javadoc11.sh | 2 +- .kokoro/release/stage.sh | 3 +- .kokoro/requirements.in | 31 ++ .kokoro/requirements.txt | 452 +++++++++++++++++++++++++++ 6 files changed, 488 insertions(+), 4 deletions(-) create mode 100644 .kokoro/requirements.in create mode 100644 .kokoro/requirements.txt diff --git a/.github/.OwlBot.lock.yaml b/.github/.OwlBot.lock.yaml index 62592923..791e842d 100644 --- a/.github/.OwlBot.lock.yaml +++ b/.github/.OwlBot.lock.yaml @@ -13,4 +13,4 @@ # limitations under the License. docker: image: gcr.io/cloud-devrel-public-resources/owlbot-java:latest - digest: sha256:8175681a918181d306d9c370d3262f16b4c724cc73d74111b7d42fc985ca7f93 + digest: sha256:6566dc8226f20993af18e5a4e7a2b1ba85a292b02dedb6a1634cf10e1b418fa5 diff --git a/.kokoro/release/publish_javadoc.sh b/.kokoro/release/publish_javadoc.sh index 333e78bf..6e294d8d 100755 --- a/.kokoro/release/publish_javadoc.sh +++ b/.kokoro/release/publish_javadoc.sh @@ -28,7 +28,7 @@ fi pushd $(dirname "$0")/../../ # install docuploader package -python3 -m pip install gcp-docuploader +python3 -m pip install --require-hashes -r .kokoro/requirements.txt # compile all packages mvn clean install -B -q -DskipTests=true diff --git a/.kokoro/release/publish_javadoc11.sh b/.kokoro/release/publish_javadoc11.sh index cf4747a5..61b66670 100755 --- a/.kokoro/release/publish_javadoc11.sh +++ b/.kokoro/release/publish_javadoc11.sh @@ -28,7 +28,7 @@ fi pushd $(dirname "$0")/../../ # install docuploader package -python3 -m pip install gcp-docuploader +python3 -m pip install --require-hashes -r .kokoro/requirements.txt # compile all packages mvn clean install -B -q -DskipTests=true diff --git a/.kokoro/release/stage.sh b/.kokoro/release/stage.sh index 1dba8de1..61e714d6 100755 --- a/.kokoro/release/stage.sh +++ b/.kokoro/release/stage.sh @@ -16,7 +16,8 @@ set -eo pipefail # Start the releasetool reporter -python3 -m pip install gcp-releasetool +requirementsFile=$(realpath $(dirname "${BASH_SOURCE[0]}")/../requirements.txt) +python3 -m pip install --require-hashes -r $requirementsFile python3 -m releasetool publish-reporter-script > /tmp/publisher-script; source /tmp/publisher-script source $(dirname "$0")/common.sh diff --git a/.kokoro/requirements.in b/.kokoro/requirements.in new file mode 100644 index 00000000..cfdc2e7e --- /dev/null +++ b/.kokoro/requirements.in @@ -0,0 +1,31 @@ +gcp-docuploader==0.6.3 +google-crc32c==1.3.0 +googleapis-common-protos==1.56.3 +gcp-releasetool==1.8.7 +cachetools==4.2.4 +cffi==1.15.1 +jeepney==0.7.1 +jinja2==3.0.3 +markupsafe==2.0.1 +keyring==23.4.1 +packaging==21.3 +protobuf==3.19.5 +pyjwt==2.4.0 +pyparsing==3.0.9 +pycparser==2.21 +pyperclip==1.8.2 +python-dateutil==2.8.2 +requests==2.27.1 +importlib-metadata==4.8.3 +zipp==3.6.0 +google_api_core==2.8.2 +google-cloud-storage==2.0.0 +google-cloud-core==2.3.1 +typing-extensions==4.1.1 +urllib3==1.26.12 +zipp==3.6.0 +rsa==4.9 +six==1.16.0 +attrs==22.1.0 +google-auth==2.11.0 +idna==3.4 \ No newline at end of file diff --git a/.kokoro/requirements.txt b/.kokoro/requirements.txt new file mode 100644 index 00000000..170f1c63 --- /dev/null +++ b/.kokoro/requirements.txt @@ -0,0 +1,452 @@ +# +# This file is autogenerated by pip-compile with python 3.10 +# To update, run: +# +# pip-compile --allow-unsafe --generate-hashes requirements.in +# +attrs==22.1.0 \ + --hash=sha256:29adc2665447e5191d0e7c568fde78b21f9672d344281d0c6e1ab085429b22b6 \ + --hash=sha256:86efa402f67bf2df34f51a335487cf46b1ec130d02b8d39fd248abfd30da551c + # via + # -r requirements.in + # gcp-releasetool +cachetools==4.2.4 \ + --hash=sha256:89ea6f1b638d5a73a4f9226be57ac5e4f399d22770b92355f92dcb0f7f001693 \ + --hash=sha256:92971d3cb7d2a97efff7c7bb1657f21a8f5fb309a37530537c71b1774189f2d1 + # via + # -r requirements.in + # google-auth +certifi==2022.9.14 \ + --hash=sha256:36973885b9542e6bd01dea287b2b4b3b21236307c56324fcc3f1160f2d655ed5 \ + --hash=sha256:e232343de1ab72c2aa521b625c80f699e356830fd0e2c620b465b304b17b0516 + # via requests +cffi==1.15.1 \ + --hash=sha256:00a9ed42e88df81ffae7a8ab6d9356b371399b91dbdf0c3cb1e84c03a13aceb5 \ + --hash=sha256:03425bdae262c76aad70202debd780501fabeaca237cdfddc008987c0e0f59ef \ + --hash=sha256:04ed324bda3cda42b9b695d51bb7d54b680b9719cfab04227cdd1e04e5de3104 \ + --hash=sha256:0e2642fe3142e4cc4af0799748233ad6da94c62a8bec3a6648bf8ee68b1c7426 \ + --hash=sha256:173379135477dc8cac4bc58f45db08ab45d228b3363adb7af79436135d028405 \ + --hash=sha256:198caafb44239b60e252492445da556afafc7d1e3ab7a1fb3f0584ef6d742375 \ + --hash=sha256:1e74c6b51a9ed6589199c787bf5f9875612ca4a8a0785fb2d4a84429badaf22a \ + --hash=sha256:2012c72d854c2d03e45d06ae57f40d78e5770d252f195b93f581acf3ba44496e \ + --hash=sha256:21157295583fe8943475029ed5abdcf71eb3911894724e360acff1d61c1d54bc \ + --hash=sha256:2470043b93ff09bf8fb1d46d1cb756ce6132c54826661a32d4e4d132e1977adf \ + --hash=sha256:285d29981935eb726a4399badae8f0ffdff4f5050eaa6d0cfc3f64b857b77185 \ + --hash=sha256:30d78fbc8ebf9c92c9b7823ee18eb92f2e6ef79b45ac84db507f52fbe3ec4497 \ + --hash=sha256:320dab6e7cb2eacdf0e658569d2575c4dad258c0fcc794f46215e1e39f90f2c3 \ + --hash=sha256:33ab79603146aace82c2427da5ca6e58f2b3f2fb5da893ceac0c42218a40be35 \ + --hash=sha256:3548db281cd7d2561c9ad9984681c95f7b0e38881201e157833a2342c30d5e8c \ + --hash=sha256:3799aecf2e17cf585d977b780ce79ff0dc9b78d799fc694221ce814c2c19db83 \ + --hash=sha256:39d39875251ca8f612b6f33e6b1195af86d1b3e60086068be9cc053aa4376e21 \ + --hash=sha256:3b926aa83d1edb5aa5b427b4053dc420ec295a08e40911296b9eb1b6170f6cca \ + --hash=sha256:3bcde07039e586f91b45c88f8583ea7cf7a0770df3a1649627bf598332cb6984 \ + --hash=sha256:3d08afd128ddaa624a48cf2b859afef385b720bb4b43df214f85616922e6a5ac \ + --hash=sha256:3eb6971dcff08619f8d91607cfc726518b6fa2a9eba42856be181c6d0d9515fd \ + --hash=sha256:40f4774f5a9d4f5e344f31a32b5096977b5d48560c5592e2f3d2c4374bd543ee \ + --hash=sha256:4289fc34b2f5316fbb762d75362931e351941fa95fa18789191b33fc4cf9504a \ + --hash=sha256:470c103ae716238bbe698d67ad020e1db9d9dba34fa5a899b5e21577e6d52ed2 \ + --hash=sha256:4f2c9f67e9821cad2e5f480bc8d83b8742896f1242dba247911072d4fa94c192 \ + --hash=sha256:50a74364d85fd319352182ef59c5c790484a336f6db772c1a9231f1c3ed0cbd7 \ + --hash=sha256:54a2db7b78338edd780e7ef7f9f6c442500fb0d41a5a4ea24fff1c929d5af585 \ + --hash=sha256:5635bd9cb9731e6d4a1132a498dd34f764034a8ce60cef4f5319c0541159392f \ + --hash=sha256:59c0b02d0a6c384d453fece7566d1c7e6b7bae4fc5874ef2ef46d56776d61c9e \ + --hash=sha256:5d598b938678ebf3c67377cdd45e09d431369c3b1a5b331058c338e201f12b27 \ + --hash=sha256:5df2768244d19ab7f60546d0c7c63ce1581f7af8b5de3eb3004b9b6fc8a9f84b \ + --hash=sha256:5ef34d190326c3b1f822a5b7a45f6c4535e2f47ed06fec77d3d799c450b2651e \ + --hash=sha256:6975a3fac6bc83c4a65c9f9fcab9e47019a11d3d2cf7f3c0d03431bf145a941e \ + --hash=sha256:6c9a799e985904922a4d207a94eae35c78ebae90e128f0c4e521ce339396be9d \ + --hash=sha256:70df4e3b545a17496c9b3f41f5115e69a4f2e77e94e1d2a8e1070bc0c38c8a3c \ + --hash=sha256:7473e861101c9e72452f9bf8acb984947aa1661a7704553a9f6e4baa5ba64415 \ + --hash=sha256:8102eaf27e1e448db915d08afa8b41d6c7ca7a04b7d73af6514df10a3e74bd82 \ + --hash=sha256:87c450779d0914f2861b8526e035c5e6da0a3199d8f1add1a665e1cbc6fc6d02 \ + --hash=sha256:8b7ee99e510d7b66cdb6c593f21c043c248537a32e0bedf02e01e9553a172314 \ + --hash=sha256:91fc98adde3d7881af9b59ed0294046f3806221863722ba7d8d120c575314325 \ + --hash=sha256:94411f22c3985acaec6f83c6df553f2dbe17b698cc7f8ae751ff2237d96b9e3c \ + --hash=sha256:98d85c6a2bef81588d9227dde12db8a7f47f639f4a17c9ae08e773aa9c697bf3 \ + --hash=sha256:9ad5db27f9cabae298d151c85cf2bad1d359a1b9c686a275df03385758e2f914 \ + --hash=sha256:a0b71b1b8fbf2b96e41c4d990244165e2c9be83d54962a9a1d118fd8657d2045 \ + --hash=sha256:a0f100c8912c114ff53e1202d0078b425bee3649ae34d7b070e9697f93c5d52d \ + --hash=sha256:a591fe9e525846e4d154205572a029f653ada1a78b93697f3b5a8f1f2bc055b9 \ + --hash=sha256:a5c84c68147988265e60416b57fc83425a78058853509c1b0629c180094904a5 \ + --hash=sha256:a66d3508133af6e8548451b25058d5812812ec3798c886bf38ed24a98216fab2 \ + --hash=sha256:a8c4917bd7ad33e8eb21e9a5bbba979b49d9a97acb3a803092cbc1133e20343c \ + --hash=sha256:b3bbeb01c2b273cca1e1e0c5df57f12dce9a4dd331b4fa1635b8bec26350bde3 \ + --hash=sha256:cba9d6b9a7d64d4bd46167096fc9d2f835e25d7e4c121fb2ddfc6528fb0413b2 \ + --hash=sha256:cc4d65aeeaa04136a12677d3dd0b1c0c94dc43abac5860ab33cceb42b801c1e8 \ + --hash=sha256:ce4bcc037df4fc5e3d184794f27bdaab018943698f4ca31630bc7f84a7b69c6d \ + --hash=sha256:cec7d9412a9102bdc577382c3929b337320c4c4c4849f2c5cdd14d7368c5562d \ + --hash=sha256:d400bfb9a37b1351253cb402671cea7e89bdecc294e8016a707f6d1d8ac934f9 \ + --hash=sha256:d61f4695e6c866a23a21acab0509af1cdfd2c013cf256bbf5b6b5e2695827162 \ + --hash=sha256:db0fbb9c62743ce59a9ff687eb5f4afbe77e5e8403d6697f7446e5f609976f76 \ + --hash=sha256:dd86c085fae2efd48ac91dd7ccffcfc0571387fe1193d33b6394db7ef31fe2a4 \ + --hash=sha256:e00b098126fd45523dd056d2efba6c5a63b71ffe9f2bbe1a4fe1716e1d0c331e \ + --hash=sha256:e229a521186c75c8ad9490854fd8bbdd9a0c9aa3a524326b55be83b54d4e0ad9 \ + --hash=sha256:e263d77ee3dd201c3a142934a086a4450861778baaeeb45db4591ef65550b0a6 \ + --hash=sha256:ed9cb427ba5504c1dc15ede7d516b84757c3e3d7868ccc85121d9310d27eed0b \ + --hash=sha256:fa6693661a4c91757f4412306191b6dc88c1703f780c8234035eac011922bc01 \ + --hash=sha256:fcd131dd944808b5bdb38e6f5b53013c5aa4f334c5cad0c72742f6eba4b73db0 + # via + # -r requirements.in + # cryptography +charset-normalizer==2.0.12 \ + --hash=sha256:2857e29ff0d34db842cd7ca3230549d1a697f96ee6d3fb071cfa6c7393832597 \ + --hash=sha256:6881edbebdb17b39b4eaaa821b438bf6eddffb4468cf344f09f89def34a8b1df + # via requests +click==8.0.4 \ + --hash=sha256:6a7a62563bbfabfda3a38f3023a1db4a35978c0abd76f6c9605ecd6554d6d9b1 \ + --hash=sha256:8458d7b1287c5fb128c90e23381cf99dcde74beaf6c7ff6384ce84d6fe090adb + # via + # gcp-docuploader + # gcp-releasetool +colorlog==6.7.0 \ + --hash=sha256:0d33ca236784a1ba3ff9c532d4964126d8a2c44f1f0cb1d2b0728196f512f662 \ + --hash=sha256:bd94bd21c1e13fac7bd3153f4bc3a7dc0eb0974b8bc2fdf1a989e474f6e582e5 + # via gcp-docuploader +cryptography==38.0.1 \ + --hash=sha256:0297ffc478bdd237f5ca3a7dc96fc0d315670bfa099c04dc3a4a2172008a405a \ + --hash=sha256:10d1f29d6292fc95acb597bacefd5b9e812099d75a6469004fd38ba5471a977f \ + --hash=sha256:16fa61e7481f4b77ef53991075de29fc5bacb582a1244046d2e8b4bb72ef66d0 \ + --hash=sha256:194044c6b89a2f9f169df475cc167f6157eb9151cc69af8a2a163481d45cc407 \ + --hash=sha256:1db3d807a14931fa317f96435695d9ec386be7b84b618cc61cfa5d08b0ae33d7 \ + --hash=sha256:3261725c0ef84e7592597606f6583385fed2a5ec3909f43bc475ade9729a41d6 \ + --hash=sha256:3b72c360427889b40f36dc214630e688c2fe03e16c162ef0aa41da7ab1455153 \ + --hash=sha256:3e3a2599e640927089f932295a9a247fc40a5bdf69b0484532f530471a382750 \ + --hash=sha256:3fc26e22840b77326a764ceb5f02ca2d342305fba08f002a8c1f139540cdfaad \ + --hash=sha256:5067ee7f2bce36b11d0e334abcd1ccf8c541fc0bbdaf57cdd511fdee53e879b6 \ + --hash=sha256:52e7bee800ec869b4031093875279f1ff2ed12c1e2f74923e8f49c916afd1d3b \ + --hash=sha256:64760ba5331e3f1794d0bcaabc0d0c39e8c60bf67d09c93dc0e54189dfd7cfe5 \ + --hash=sha256:765fa194a0f3372d83005ab83ab35d7c5526c4e22951e46059b8ac678b44fa5a \ + --hash=sha256:79473cf8a5cbc471979bd9378c9f425384980fcf2ab6534b18ed7d0d9843987d \ + --hash=sha256:896dd3a66959d3a5ddcfc140a53391f69ff1e8f25d93f0e2e7830c6de90ceb9d \ + --hash=sha256:89ed49784ba88c221756ff4d4755dbc03b3c8d2c5103f6d6b4f83a0fb1e85294 \ + --hash=sha256:ac7e48f7e7261207d750fa7e55eac2d45f720027d5703cd9007e9b37bbb59ac0 \ + --hash=sha256:ad7353f6ddf285aeadfaf79e5a6829110106ff8189391704c1d8801aa0bae45a \ + --hash=sha256:b0163a849b6f315bf52815e238bc2b2346604413fa7c1601eea84bcddb5fb9ac \ + --hash=sha256:b6c9b706316d7b5a137c35e14f4103e2115b088c412140fdbd5f87c73284df61 \ + --hash=sha256:c2e5856248a416767322c8668ef1845ad46ee62629266f84a8f007a317141013 \ + --hash=sha256:ca9f6784ea96b55ff41708b92c3f6aeaebde4c560308e5fbbd3173fbc466e94e \ + --hash=sha256:d1a5bd52d684e49a36582193e0b89ff267704cd4025abefb9e26803adeb3e5fb \ + --hash=sha256:d3971e2749a723e9084dd507584e2a2761f78ad2c638aa31e80bc7a15c9db4f9 \ + --hash=sha256:d4ef6cc305394ed669d4d9eebf10d3a101059bdcf2669c366ec1d14e4fb227bd \ + --hash=sha256:d9e69ae01f99abe6ad646947bba8941e896cb3aa805be2597a0400e0764b5818 + # via + # gcp-releasetool + # secretstorage +gcp-docuploader==0.6.3 \ + --hash=sha256:ba8c9d76b3bbac54b0311c503a373b00edc2dc02d6d54ea9507045adb8e870f7 \ + --hash=sha256:c0f5aaa82ce1854a386197e4e359b120ad6d4e57ae2c812fce42219a3288026b + # via -r requirements.in +gcp-releasetool==1.8.7 \ + --hash=sha256:3d2a67c9db39322194afb3b427e9cb0476ce8f2a04033695f0aeb63979fc2b37 \ + --hash=sha256:5e4d28f66e90780d77f3ecf1e9155852b0c3b13cbccb08ab07e66b2357c8da8d + # via -r requirements.in +google-api-core==2.8.2 \ + --hash=sha256:06f7244c640322b508b125903bb5701bebabce8832f85aba9335ec00b3d02edc \ + --hash=sha256:93c6a91ccac79079ac6bbf8b74ee75db970cc899278b97d53bc012f35908cf50 + # via + # -r requirements.in + # google-cloud-core + # google-cloud-storage +google-auth==2.11.0 \ + --hash=sha256:be62acaae38d0049c21ca90f27a23847245c9f161ff54ede13af2cb6afecbac9 \ + --hash=sha256:ed65ecf9f681832298e29328e1ef0a3676e3732b2e56f41532d45f70a22de0fb + # via + # -r requirements.in + # gcp-releasetool + # google-api-core + # google-cloud-core + # google-cloud-storage +google-cloud-core==2.3.1 \ + --hash=sha256:113ba4f492467d5bd442c8d724c1a25ad7384045c3178369038840ecdd19346c \ + --hash=sha256:34334359cb04187bdc80ddcf613e462dfd7a3aabbc3fe4d118517ab4b9303d53 + # via + # -r requirements.in + # google-cloud-storage +google-cloud-storage==2.0.0 \ + --hash=sha256:a57a15aead0f9dfbd4381f1bfdbe8bf89818a4bd75bab846cafcefb2db846c47 \ + --hash=sha256:ec4be60bb223a3a960f0d01697d849b86d91cad815a84915a32ed3635e93a5e7 + # via + # -r requirements.in + # gcp-docuploader +google-crc32c==1.3.0 \ + --hash=sha256:04e7c220798a72fd0f08242bc8d7a05986b2a08a0573396187fd32c1dcdd58b3 \ + --hash=sha256:05340b60bf05b574159e9bd940152a47d38af3fb43803ffe71f11d704b7696a6 \ + --hash=sha256:12674a4c3b56b706153a358eaa1018c4137a5a04635b92b4652440d3d7386206 \ + --hash=sha256:127f9cc3ac41b6a859bd9dc4321097b1a4f6aa7fdf71b4f9227b9e3ebffb4422 \ + --hash=sha256:13af315c3a0eec8bb8b8d80b8b128cb3fcd17d7e4edafc39647846345a3f003a \ + --hash=sha256:1926fd8de0acb9d15ee757175ce7242e235482a783cd4ec711cc999fc103c24e \ + --hash=sha256:226f2f9b8e128a6ca6a9af9b9e8384f7b53a801907425c9a292553a3a7218ce0 \ + --hash=sha256:276de6273eb074a35bc598f8efbc00c7869c5cf2e29c90748fccc8c898c244df \ + --hash=sha256:318f73f5484b5671f0c7f5f63741ab020a599504ed81d209b5c7129ee4667407 \ + --hash=sha256:3bbce1be3687bbfebe29abdb7631b83e6b25da3f4e1856a1611eb21854b689ea \ + --hash=sha256:42ae4781333e331a1743445931b08ebdad73e188fd554259e772556fc4937c48 \ + --hash=sha256:58be56ae0529c664cc04a9c76e68bb92b091e0194d6e3c50bea7e0f266f73713 \ + --hash=sha256:5da2c81575cc3ccf05d9830f9e8d3c70954819ca9a63828210498c0774fda1a3 \ + --hash=sha256:6311853aa2bba4064d0c28ca54e7b50c4d48e3de04f6770f6c60ebda1e975267 \ + --hash=sha256:650e2917660e696041ab3dcd7abac160b4121cd9a484c08406f24c5964099829 \ + --hash=sha256:6a4db36f9721fdf391646685ecffa404eb986cbe007a3289499020daf72e88a2 \ + --hash=sha256:779cbf1ce375b96111db98fca913c1f5ec11b1d870e529b1dc7354b2681a8c3a \ + --hash=sha256:7f6fe42536d9dcd3e2ffb9d3053f5d05221ae3bbcefbe472bdf2c71c793e3183 \ + --hash=sha256:891f712ce54e0d631370e1f4997b3f182f3368179198efc30d477c75d1f44942 \ + --hash=sha256:95c68a4b9b7828ba0428f8f7e3109c5d476ca44996ed9a5f8aac6269296e2d59 \ + --hash=sha256:96a8918a78d5d64e07c8ea4ed2bc44354e3f93f46a4866a40e8db934e4c0d74b \ + --hash=sha256:9c3cf890c3c0ecfe1510a452a165431b5831e24160c5fcf2071f0f85ca5a47cd \ + --hash=sha256:9f58099ad7affc0754ae42e6d87443299f15d739b0ce03c76f515153a5cda06c \ + --hash=sha256:a0b9e622c3b2b8d0ce32f77eba617ab0d6768b82836391e4f8f9e2074582bf02 \ + --hash=sha256:a7f9cbea4245ee36190f85fe1814e2d7b1e5f2186381b082f5d59f99b7f11328 \ + --hash=sha256:bab4aebd525218bab4ee615786c4581952eadc16b1ff031813a2fd51f0cc7b08 \ + --hash=sha256:c124b8c8779bf2d35d9b721e52d4adb41c9bfbde45e6a3f25f0820caa9aba73f \ + --hash=sha256:c9da0a39b53d2fab3e5467329ed50e951eb91386e9d0d5b12daf593973c3b168 \ + --hash=sha256:ca60076c388728d3b6ac3846842474f4250c91efbfe5afa872d3ffd69dd4b318 \ + --hash=sha256:cb6994fff247987c66a8a4e550ef374671c2b82e3c0d2115e689d21e511a652d \ + --hash=sha256:d1c1d6236feab51200272d79b3d3e0f12cf2cbb12b208c835b175a21efdb0a73 \ + --hash=sha256:dd7760a88a8d3d705ff562aa93f8445ead54f58fd482e4f9e2bafb7e177375d4 \ + --hash=sha256:dda4d8a3bb0b50f540f6ff4b6033f3a74e8bf0bd5320b70fab2c03e512a62812 \ + --hash=sha256:e0f1ff55dde0ebcfbef027edc21f71c205845585fffe30d4ec4979416613e9b3 \ + --hash=sha256:e7a539b9be7b9c00f11ef16b55486141bc2cdb0c54762f84e3c6fc091917436d \ + --hash=sha256:eb0b14523758e37802f27b7f8cd973f5f3d33be7613952c0df904b68c4842f0e \ + --hash=sha256:ed447680ff21c14aaceb6a9f99a5f639f583ccfe4ce1a5e1d48eb41c3d6b3217 \ + --hash=sha256:f52a4ad2568314ee713715b1e2d79ab55fab11e8b304fd1462ff5cccf4264b3e \ + --hash=sha256:fbd60c6aaa07c31d7754edbc2334aef50601b7f1ada67a96eb1eb57c7c72378f \ + --hash=sha256:fc28e0db232c62ca0c3600884933178f0825c99be4474cdd645e378a10588125 \ + --hash=sha256:fe31de3002e7b08eb20823b3735b97c86c5926dd0581c7710a680b418a8709d4 \ + --hash=sha256:fec221a051150eeddfdfcff162e6db92c65ecf46cb0f7bb1bf812a1520ec026b \ + --hash=sha256:ff71073ebf0e42258a42a0b34f2c09ec384977e7f6808999102eedd5b49920e3 + # via + # -r requirements.in + # google-resumable-media +google-resumable-media==2.3.3 \ + --hash=sha256:27c52620bd364d1c8116eaac4ea2afcbfb81ae9139fb3199652fcac1724bfb6c \ + --hash=sha256:5b52774ea7a829a8cdaa8bd2d4c3d4bc660c91b30857ab2668d0eb830f4ea8c5 + # via google-cloud-storage +googleapis-common-protos==1.56.3 \ + --hash=sha256:6f1369b58ed6cf3a4b7054a44ebe8d03b29c309257583a2bbdc064cd1e4a1442 \ + --hash=sha256:87955d7b3a73e6e803f2572a33179de23989ebba725e05ea42f24838b792e461 + # via + # -r requirements.in + # google-api-core +idna==3.4 \ + --hash=sha256:814f528e8dead7d329833b91c5faa87d60bf71824cd12a7530b5526063d02cb4 \ + --hash=sha256:90b77e79eaa3eba6de819a0c442c0b4ceefc341a7a2ab77d7562bf49f425c5c2 + # via + # -r requirements.in + # requests +importlib-metadata==4.8.3 \ + --hash=sha256:65a9576a5b2d58ca44d133c42a241905cc45e34d2c06fd5ba2bafa221e5d7b5e \ + --hash=sha256:766abffff765960fcc18003801f7044eb6755ffae4521c8e8ce8e83b9c9b0668 + # via + # -r requirements.in + # keyring +jeepney==0.7.1 \ + --hash=sha256:1b5a0ea5c0e7b166b2f5895b91a08c14de8915afda4407fb5022a195224958ac \ + --hash=sha256:fa9e232dfa0c498bd0b8a3a73b8d8a31978304dcef0515adc859d4e096f96f4f + # via + # -r requirements.in + # keyring + # secretstorage +jinja2==3.0.3 \ + --hash=sha256:077ce6014f7b40d03b47d1f1ca4b0fc8328a692bd284016f806ed0eaca390ad8 \ + --hash=sha256:611bb273cd68f3b993fabdc4064fc858c5b47a973cb5aa7999ec1ba405c87cd7 + # via + # -r requirements.in + # gcp-releasetool +keyring==23.4.1 \ + --hash=sha256:17e49fb0d6883c2b4445359434dba95aad84aabb29bbff044ad0ed7100232eca \ + --hash=sha256:89cbd74d4683ed164c8082fb38619341097741323b3786905c6dac04d6915a55 + # via + # -r requirements.in + # gcp-releasetool +markupsafe==2.0.1 \ + --hash=sha256:01a9b8ea66f1658938f65b93a85ebe8bc016e6769611be228d797c9d998dd298 \ + --hash=sha256:023cb26ec21ece8dc3907c0e8320058b2e0cb3c55cf9564da612bc325bed5e64 \ + --hash=sha256:0446679737af14f45767963a1a9ef7620189912317d095f2d9ffa183a4d25d2b \ + --hash=sha256:04635854b943835a6ea959e948d19dcd311762c5c0c6e1f0e16ee57022669194 \ + --hash=sha256:0717a7390a68be14b8c793ba258e075c6f4ca819f15edfc2a3a027c823718567 \ + --hash=sha256:0955295dd5eec6cb6cc2fe1698f4c6d84af2e92de33fbcac4111913cd100a6ff \ + --hash=sha256:0d4b31cc67ab36e3392bbf3862cfbadac3db12bdd8b02a2731f509ed5b829724 \ + --hash=sha256:10f82115e21dc0dfec9ab5c0223652f7197feb168c940f3ef61563fc2d6beb74 \ + --hash=sha256:168cd0a3642de83558a5153c8bd34f175a9a6e7f6dc6384b9655d2697312a646 \ + --hash=sha256:1d609f577dc6e1aa17d746f8bd3c31aa4d258f4070d61b2aa5c4166c1539de35 \ + --hash=sha256:1f2ade76b9903f39aa442b4aadd2177decb66525062db244b35d71d0ee8599b6 \ + --hash=sha256:20dca64a3ef2d6e4d5d615a3fd418ad3bde77a47ec8a23d984a12b5b4c74491a \ + --hash=sha256:2a7d351cbd8cfeb19ca00de495e224dea7e7d919659c2841bbb7f420ad03e2d6 \ + --hash=sha256:2d7d807855b419fc2ed3e631034685db6079889a1f01d5d9dac950f764da3dad \ + --hash=sha256:2ef54abee730b502252bcdf31b10dacb0a416229b72c18b19e24a4509f273d26 \ + --hash=sha256:36bc903cbb393720fad60fc28c10de6acf10dc6cc883f3e24ee4012371399a38 \ + --hash=sha256:37205cac2a79194e3750b0af2a5720d95f786a55ce7df90c3af697bfa100eaac \ + --hash=sha256:3c112550557578c26af18a1ccc9e090bfe03832ae994343cfdacd287db6a6ae7 \ + --hash=sha256:3dd007d54ee88b46be476e293f48c85048603f5f516008bee124ddd891398ed6 \ + --hash=sha256:4296f2b1ce8c86a6aea78613c34bb1a672ea0e3de9c6ba08a960efe0b0a09047 \ + --hash=sha256:47ab1e7b91c098ab893b828deafa1203de86d0bc6ab587b160f78fe6c4011f75 \ + --hash=sha256:49e3ceeabbfb9d66c3aef5af3a60cc43b85c33df25ce03d0031a608b0a8b2e3f \ + --hash=sha256:4dc8f9fb58f7364b63fd9f85013b780ef83c11857ae79f2feda41e270468dd9b \ + --hash=sha256:4efca8f86c54b22348a5467704e3fec767b2db12fc39c6d963168ab1d3fc9135 \ + --hash=sha256:53edb4da6925ad13c07b6d26c2a852bd81e364f95301c66e930ab2aef5b5ddd8 \ + --hash=sha256:5855f8438a7d1d458206a2466bf82b0f104a3724bf96a1c781ab731e4201731a \ + --hash=sha256:594c67807fb16238b30c44bdf74f36c02cdf22d1c8cda91ef8a0ed8dabf5620a \ + --hash=sha256:5b6d930f030f8ed98e3e6c98ffa0652bdb82601e7a016ec2ab5d7ff23baa78d1 \ + --hash=sha256:5bb28c636d87e840583ee3adeb78172efc47c8b26127267f54a9c0ec251d41a9 \ + --hash=sha256:60bf42e36abfaf9aff1f50f52644b336d4f0a3fd6d8a60ca0d054ac9f713a864 \ + --hash=sha256:611d1ad9a4288cf3e3c16014564df047fe08410e628f89805e475368bd304914 \ + --hash=sha256:6300b8454aa6930a24b9618fbb54b5a68135092bc666f7b06901f897fa5c2fee \ + --hash=sha256:63f3268ba69ace99cab4e3e3b5840b03340efed0948ab8f78d2fd87ee5442a4f \ + --hash=sha256:6557b31b5e2c9ddf0de32a691f2312a32f77cd7681d8af66c2692efdbef84c18 \ + --hash=sha256:693ce3f9e70a6cf7d2fb9e6c9d8b204b6b39897a2c4a1aa65728d5ac97dcc1d8 \ + --hash=sha256:6a7fae0dd14cf60ad5ff42baa2e95727c3d81ded453457771d02b7d2b3f9c0c2 \ + --hash=sha256:6c4ca60fa24e85fe25b912b01e62cb969d69a23a5d5867682dd3e80b5b02581d \ + --hash=sha256:6fcf051089389abe060c9cd7caa212c707e58153afa2c649f00346ce6d260f1b \ + --hash=sha256:7d91275b0245b1da4d4cfa07e0faedd5b0812efc15b702576d103293e252af1b \ + --hash=sha256:89c687013cb1cd489a0f0ac24febe8c7a666e6e221b783e53ac50ebf68e45d86 \ + --hash=sha256:8d206346619592c6200148b01a2142798c989edcb9c896f9ac9722a99d4e77e6 \ + --hash=sha256:905fec760bd2fa1388bb5b489ee8ee5f7291d692638ea5f67982d968366bef9f \ + --hash=sha256:97383d78eb34da7e1fa37dd273c20ad4320929af65d156e35a5e2d89566d9dfb \ + --hash=sha256:984d76483eb32f1bcb536dc27e4ad56bba4baa70be32fa87152832cdd9db0833 \ + --hash=sha256:99df47edb6bda1249d3e80fdabb1dab8c08ef3975f69aed437cb69d0a5de1e28 \ + --hash=sha256:9f02365d4e99430a12647f09b6cc8bab61a6564363f313126f775eb4f6ef798e \ + --hash=sha256:a30e67a65b53ea0a5e62fe23682cfe22712e01f453b95233b25502f7c61cb415 \ + --hash=sha256:ab3ef638ace319fa26553db0624c4699e31a28bb2a835c5faca8f8acf6a5a902 \ + --hash=sha256:aca6377c0cb8a8253e493c6b451565ac77e98c2951c45f913e0b52facdcff83f \ + --hash=sha256:add36cb2dbb8b736611303cd3bfcee00afd96471b09cda130da3581cbdc56a6d \ + --hash=sha256:b2f4bf27480f5e5e8ce285a8c8fd176c0b03e93dcc6646477d4630e83440c6a9 \ + --hash=sha256:b7f2d075102dc8c794cbde1947378051c4e5180d52d276987b8d28a3bd58c17d \ + --hash=sha256:baa1a4e8f868845af802979fcdbf0bb11f94f1cb7ced4c4b8a351bb60d108145 \ + --hash=sha256:be98f628055368795d818ebf93da628541e10b75b41c559fdf36d104c5787066 \ + --hash=sha256:bf5d821ffabf0ef3533c39c518f3357b171a1651c1ff6827325e4489b0e46c3c \ + --hash=sha256:c47adbc92fc1bb2b3274c4b3a43ae0e4573d9fbff4f54cd484555edbf030baf1 \ + --hash=sha256:cdfba22ea2f0029c9261a4bd07e830a8da012291fbe44dc794e488b6c9bb353a \ + --hash=sha256:d6c7ebd4e944c85e2c3421e612a7057a2f48d478d79e61800d81468a8d842207 \ + --hash=sha256:d7f9850398e85aba693bb640262d3611788b1f29a79f0c93c565694658f4071f \ + --hash=sha256:d8446c54dc28c01e5a2dbac5a25f071f6653e6e40f3a8818e8b45d790fe6ef53 \ + --hash=sha256:deb993cacb280823246a026e3b2d81c493c53de6acfd5e6bfe31ab3402bb37dd \ + --hash=sha256:e0f138900af21926a02425cf736db95be9f4af72ba1bb21453432a07f6082134 \ + --hash=sha256:e9936f0b261d4df76ad22f8fee3ae83b60d7c3e871292cd42f40b81b70afae85 \ + --hash=sha256:f0567c4dc99f264f49fe27da5f735f414c4e7e7dd850cfd8e69f0862d7c74ea9 \ + --hash=sha256:f5653a225f31e113b152e56f154ccbe59eeb1c7487b39b9d9f9cdb58e6c79dc5 \ + --hash=sha256:f826e31d18b516f653fe296d967d700fddad5901ae07c622bb3705955e1faa94 \ + --hash=sha256:f8ba0e8349a38d3001fae7eadded3f6606f0da5d748ee53cc1dab1d6527b9509 \ + --hash=sha256:f9081981fe268bd86831e5c75f7de206ef275defcb82bc70740ae6dc507aee51 \ + --hash=sha256:fa130dd50c57d53368c9d59395cb5526eda596d3ffe36666cd81a44d56e48872 + # via + # -r requirements.in + # jinja2 +packaging==21.3 \ + --hash=sha256:dd47c42927d89ab911e606518907cc2d3a1f38bbd026385970643f9c5b8ecfeb \ + --hash=sha256:ef103e05f519cdc783ae24ea4e2e0f508a9c99b2d4969652eed6a2e1ea5bd522 + # via + # -r requirements.in + # gcp-releasetool +protobuf==3.19.5 \ + --hash=sha256:1867f93b06a183f87696871bb8d1e99ee71dbb69d468ce1f0cc8bf3d30f982f3 \ + --hash=sha256:3c4160b601220627f7e91154e572baf5e161a9c3f445a8242d536ee3d0b7b17c \ + --hash=sha256:4ee2af7051d3b10c8a4fe6fd1a2c69f201fea36aeee7086cf202a692e1b99ee1 \ + --hash=sha256:5266c36cc0af3bb3dbf44f199d225b33da66a9a5c3bdc2b14865ad10eddf0e37 \ + --hash=sha256:5470f892961af464ae6eaf0f3099e2c1190ae8c7f36f174b89491281341f79ca \ + --hash=sha256:66d14b5b90090353efe75c9fb1bf65ef7267383034688d255b500822e37d5c2f \ + --hash=sha256:67efb5d20618020aa9596e17bfc37ca068c28ec0c1507d9507f73c93d46c9855 \ + --hash=sha256:696e6cfab94cc15a14946f2bf72719dced087d437adbd994fff34f38986628bc \ + --hash=sha256:6a02172b9650f819d01fb8e224fc69b0706458fc1ab4f1c669281243c71c1a5e \ + --hash=sha256:6eca9ae238ba615d702387a2ddea635d535d769994a9968c09a4ca920c487ab9 \ + --hash=sha256:950abd6c00e7b51f87ae8b18a0ce4d69fea217f62f171426e77de5061f6d9850 \ + --hash=sha256:9e1d74032f56ff25f417cfe84c8147047732e5059137ca42efad20cbbd25f5e0 \ + --hash=sha256:9e42b1cf2ecd8a1bd161239e693f22035ba99905ae6d7efeac8a0546c7ec1a27 \ + --hash=sha256:9f957ef53e872d58a0afd3bf6d80d48535d28c99b40e75e6634cbc33ea42fd54 \ + --hash=sha256:a89aa0c042e61e11ade320b802d6db4ee5391d8d973e46d3a48172c1597789f8 \ + --hash=sha256:c0f80876a8ff0ae7064084ed094eb86497bd5a3812e6fc96a05318b92301674e \ + --hash=sha256:c44e3282cff74ad18c7e8a0375f407f69ee50c2116364b44492a196293e08b21 \ + --hash=sha256:d249519ba5ecf5dd6b18150c9b6bcde510b273714b696f3923ff8308fc11ae49 \ + --hash=sha256:d3973a2d58aefc7d1230725c2447ce7f86a71cbc094b86a77c6ee1505ac7cdb1 \ + --hash=sha256:dca2284378a5f2a86ffed35c6ac147d14c48b525eefcd1083e5a9ce28dfa8657 \ + --hash=sha256:e63b0b3c42e51c94add62b010366cd4979cb6d5f06158bcae8faac4c294f91e1 \ + --hash=sha256:f2b599a21c9a32e171ec29a2ac54e03297736c578698e11b099d031f79da114b \ + --hash=sha256:f2bde37667b18c2b5280df83bc799204394a5d2d774e4deaf9de0eb741df6833 \ + --hash=sha256:f4f909f4dde413dec435a44b0894956d55bb928ded7d6e3c726556ca4c796e84 \ + --hash=sha256:f976234e20ab2785f54224bcdafa027674e23663b132fa3ca0caa291a6cfbde7 \ + --hash=sha256:f9cebda093c2f6bfed88f1c17cdade09d4d96096421b344026feee236532d4de + # via + # -r requirements.in + # gcp-docuploader + # gcp-releasetool + # google-api-core + # google-cloud-storage + # googleapis-common-protos +pyasn1==0.4.8 \ + --hash=sha256:39c7e2ec30515947ff4e87fb6f456dfc6e84857d34be479c9d4a4ba4bf46aa5d \ + --hash=sha256:aef77c9fb94a3ac588e87841208bdec464471d9871bd5050a287cc9a475cd0ba + # via + # pyasn1-modules + # rsa +pyasn1-modules==0.2.8 \ + --hash=sha256:905f84c712230b2c592c19470d3ca8d552de726050d1d1716282a1f6146be65e \ + --hash=sha256:a50b808ffeb97cb3601dd25981f6b016cbb3d31fbf57a8b8a87428e6158d0c74 + # via google-auth +pycparser==2.21 \ + --hash=sha256:8ee45429555515e1f6b185e78100aea234072576aa43ab53aefcae078162fca9 \ + --hash=sha256:e644fdec12f7872f86c58ff790da456218b10f863970249516d60a5eaca77206 + # via + # -r requirements.in + # cffi +pyjwt==2.4.0 \ + --hash=sha256:72d1d253f32dbd4f5c88eaf1fdc62f3a19f676ccbadb9dbc5d07e951b2b26daf \ + --hash=sha256:d42908208c699b3b973cbeb01a969ba6a96c821eefb1c5bfe4c390c01d67abba + # via + # -r requirements.in + # gcp-releasetool +pyparsing==3.0.9 \ + --hash=sha256:2b020ecf7d21b687f219b71ecad3631f644a47f01403fa1d1036b0c6416d70fb \ + --hash=sha256:5026bae9a10eeaefb61dab2f09052b9f4307d44aee4eda64b309723d8d206bbc + # via + # -r requirements.in + # packaging +pyperclip==1.8.2 \ + --hash=sha256:105254a8b04934f0bc84e9c24eb360a591aaf6535c9def5f29d92af107a9bf57 + # via + # -r requirements.in + # gcp-releasetool +python-dateutil==2.8.2 \ + --hash=sha256:0123cacc1627ae19ddf3c27a5de5bd67ee4586fbdd6440d9748f8abb483d3e86 \ + --hash=sha256:961d03dc3453ebbc59dbdea9e4e11c5651520a876d0f4db161e8674aae935da9 + # via + # -r requirements.in + # gcp-releasetool +requests==2.27.1 \ + --hash=sha256:68d7c56fd5a8999887728ef304a6d12edc7be74f1cfa47714fc8b414525c9a61 \ + --hash=sha256:f22fa1e554c9ddfd16e6e41ac79759e17be9e492b3587efa038054674760e72d + # via + # -r requirements.in + # gcp-releasetool + # google-api-core + # google-cloud-storage +rsa==4.9 \ + --hash=sha256:90260d9058e514786967344d0ef75fa8727eed8a7d2e43ce9f4bcf1b536174f7 \ + --hash=sha256:e38464a49c6c85d7f1351b0126661487a7e0a14a50f1675ec50eb34d4f20ef21 + # via + # -r requirements.in + # google-auth +secretstorage==3.3.3 \ + --hash=sha256:2403533ef369eca6d2ba81718576c5e0f564d5cca1b58f73a8b23e7d4eeebd77 \ + --hash=sha256:f356e6628222568e3af06f2eba8df495efa13b3b63081dafd4f7d9a7b7bc9f99 + # via keyring +six==1.16.0 \ + --hash=sha256:1e61c37477a1626458e36f7b1d82aa5c9b094fa4802892072e49de9c60c4c926 \ + --hash=sha256:8abb2f1d86890a2dfb989f9a77cfcfd3e47c2a354b01111771326f8aa26e0254 + # via + # -r requirements.in + # gcp-docuploader + # google-auth + # python-dateutil +typing-extensions==4.1.1 \ + --hash=sha256:1a9462dcc3347a79b1f1c0271fbe79e844580bb598bafa1ed208b94da3cdcd42 \ + --hash=sha256:21c85e0fe4b9a155d0799430b0ad741cdce7e359660ccbd8b530613e8df88ce2 + # via -r requirements.in +urllib3==1.26.12 \ + --hash=sha256:3fa96cf423e6987997fc326ae8df396db2a8b7c667747d47ddd8ecba91f4a74e \ + --hash=sha256:b930dd878d5a8afb066a637fbb35144fe7901e3b209d1cd4f524bd0e9deee997 + # via + # -r requirements.in + # requests +zipp==3.6.0 \ + --hash=sha256:71c644c5369f4a6e07636f0aa966270449561fcea2e3d6747b8d23efaa9d7832 \ + --hash=sha256:9fe5ea21568a0a70e50f273397638d39b03353731e6cbbb3fd8502a33fec40bc + # via + # -r requirements.in + # importlib-metadata From 5a0da57d3211f49a3d6b61a0310dca850f2d739e Mon Sep 17 00:00:00 2001 From: WhiteSource Renovate Date: Tue, 27 Sep 2022 17:00:39 +0200 Subject: [PATCH 14/38] deps: update dependency keyring to v23.9.3 (#802) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit [![Mend Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com) This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [keyring](https://togithub.com/jaraco/keyring) | `==23.4.1` -> `==23.9.3` | [![age](https://badges.renovateapi.com/packages/pypi/keyring/23.9.3/age-slim)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://badges.renovateapi.com/packages/pypi/keyring/23.9.3/adoption-slim)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://badges.renovateapi.com/packages/pypi/keyring/23.9.3/compatibility-slim/23.4.1)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://badges.renovateapi.com/packages/pypi/keyring/23.9.3/confidence-slim/23.4.1)](https://docs.renovatebot.com/merge-confidence/) | --- ### Configuration 📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Renovate will not automatically rebase this PR, because other commits have been found. 🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] If you want to rebase/retry this PR, click this checkbox. ⚠ **Warning**: custom changes will be lost. --- This PR has been generated by [Mend Renovate](https://www.mend.io/free-developer-tools/renovate/). View repository job log [here](https://app.renovatebot.com/dashboard#github/googleapis/java-cloudbuild). From 8549944a8c2769929a564222409a186c70daf404 Mon Sep 17 00:00:00 2001 From: WhiteSource Renovate Date: Tue, 27 Sep 2022 17:02:44 +0200 Subject: [PATCH 15/38] deps: update dependency zipp to v3.8.1 (#808) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit [![Mend Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com) This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [zipp](https://togithub.com/jaraco/zipp) | `==3.6.0` -> `==3.8.1` | [![age](https://badges.renovateapi.com/packages/pypi/zipp/3.8.1/age-slim)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://badges.renovateapi.com/packages/pypi/zipp/3.8.1/adoption-slim)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://badges.renovateapi.com/packages/pypi/zipp/3.8.1/compatibility-slim/3.6.0)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://badges.renovateapi.com/packages/pypi/zipp/3.8.1/confidence-slim/3.6.0)](https://docs.renovatebot.com/merge-confidence/) | --- ### Configuration 📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Renovate will not automatically rebase this PR, because other commits have been found. 🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] If you want to rebase/retry this PR, click this checkbox. ⚠ **Warning**: custom changes will be lost. --- This PR has been generated by [Mend Renovate](https://www.mend.io/free-developer-tools/renovate/). View repository job log [here](https://app.renovatebot.com/dashboard#github/googleapis/java-cloudbuild). From 4a8e7808320ed561667cbc76e9ca3323781594bc Mon Sep 17 00:00:00 2001 From: WhiteSource Renovate Date: Tue, 27 Sep 2022 17:08:19 +0200 Subject: [PATCH 16/38] deps: update dependency google-auth to v2.11.1 (#800) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit [![Mend Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com) This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [google-auth](https://togithub.com/googleapis/google-auth-library-python) | `==2.11.0` -> `==2.11.1` | [![age](https://badges.renovateapi.com/packages/pypi/google-auth/2.11.1/age-slim)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://badges.renovateapi.com/packages/pypi/google-auth/2.11.1/adoption-slim)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://badges.renovateapi.com/packages/pypi/google-auth/2.11.1/compatibility-slim/2.11.0)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://badges.renovateapi.com/packages/pypi/google-auth/2.11.1/confidence-slim/2.11.0)](https://docs.renovatebot.com/merge-confidence/) | --- ### Configuration 📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Renovate will not automatically rebase this PR, because other commits have been found. 🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] If you want to rebase/retry this PR, click this checkbox. ⚠ **Warning**: custom changes will be lost. --- This PR has been generated by [Mend Renovate](https://www.mend.io/free-developer-tools/renovate/). View repository job log [here](https://app.renovatebot.com/dashboard#github/googleapis/java-cloudbuild). From affd4651305327b69b6577b3ed3cffb8153447cd Mon Sep 17 00:00:00 2001 From: WhiteSource Renovate Date: Tue, 27 Sep 2022 17:10:37 +0200 Subject: [PATCH 17/38] deps: update dependency requests to v2.28.1 (#806) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit [![Mend Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com) This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [requests](https://requests.readthedocs.io) ([source](https://togithub.com/psf/requests), [changelog](https://togithub.com/psf/requests/blob/master/HISTORY.md)) | `==2.27.1` -> `==2.28.1` | [![age](https://badges.renovateapi.com/packages/pypi/requests/2.28.1/age-slim)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://badges.renovateapi.com/packages/pypi/requests/2.28.1/adoption-slim)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://badges.renovateapi.com/packages/pypi/requests/2.28.1/compatibility-slim/2.27.1)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://badges.renovateapi.com/packages/pypi/requests/2.28.1/confidence-slim/2.27.1)](https://docs.renovatebot.com/merge-confidence/) | --- ### Configuration 📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Renovate will not automatically rebase this PR, because other commits have been found. 🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] If you want to rebase/retry this PR, click this checkbox. ⚠ **Warning**: custom changes will be lost. --- This PR has been generated by [Mend Renovate](https://www.mend.io/free-developer-tools/renovate/). View repository job log [here](https://app.renovatebot.com/dashboard#github/googleapis/java-cloudbuild). From f7b3b2cfcfc4c6e9bdb5cf70cb6fa0faa4503375 Mon Sep 17 00:00:00 2001 From: WhiteSource Renovate Date: Tue, 27 Sep 2022 17:12:34 +0200 Subject: [PATCH 18/38] deps: update dependency typing-extensions to v4.3.0 (#807) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit [![Mend Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com) This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [typing-extensions](https://togithub.com/python/typing_extensions) ([changelog](https://togithub.com/python/typing_extensions/blob/main/CHANGELOG.md)) | `==4.1.1` -> `==4.3.0` | [![age](https://badges.renovateapi.com/packages/pypi/typing-extensions/4.3.0/age-slim)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://badges.renovateapi.com/packages/pypi/typing-extensions/4.3.0/adoption-slim)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://badges.renovateapi.com/packages/pypi/typing-extensions/4.3.0/compatibility-slim/4.1.1)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://badges.renovateapi.com/packages/pypi/typing-extensions/4.3.0/confidence-slim/4.1.1)](https://docs.renovatebot.com/merge-confidence/) | --- ### Configuration 📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Renovate will not automatically rebase this PR, because other commits have been found. 🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] If you want to rebase/retry this PR, click this checkbox. ⚠ **Warning**: custom changes will be lost. --- This PR has been generated by [Mend Renovate](https://www.mend.io/free-developer-tools/renovate/). View repository job log [here](https://app.renovatebot.com/dashboard#github/googleapis/java-cloudbuild). From 0ccbc5ab0f2d18474f18fd0c84d85ddead5676d3 Mon Sep 17 00:00:00 2001 From: WhiteSource Renovate Date: Tue, 27 Sep 2022 17:14:41 +0200 Subject: [PATCH 19/38] deps: update dependency jinja2 to v3.1.2 (#801) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit [![Mend Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com) This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [jinja2](https://palletsprojects.com/p/jinja/) ([changelog](https://jinja.palletsprojects.com/changes/)) | `==3.0.3` -> `==3.1.2` | [![age](https://badges.renovateapi.com/packages/pypi/jinja2/3.1.2/age-slim)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://badges.renovateapi.com/packages/pypi/jinja2/3.1.2/adoption-slim)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://badges.renovateapi.com/packages/pypi/jinja2/3.1.2/compatibility-slim/3.0.3)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://badges.renovateapi.com/packages/pypi/jinja2/3.1.2/confidence-slim/3.0.3)](https://docs.renovatebot.com/merge-confidence/) | --- ### Configuration 📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Renovate will not automatically rebase this PR, because other commits have been found. 🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] If you want to rebase/retry this PR, click this checkbox. ⚠ **Warning**: custom changes will be lost. --- This PR has been generated by [Mend Renovate](https://www.mend.io/free-developer-tools/renovate/). View repository job log [here](https://app.renovatebot.com/dashboard#github/googleapis/java-cloudbuild). From 9de32d3bfea0b614333ea8601269539c38256863 Mon Sep 17 00:00:00 2001 From: WhiteSource Renovate Date: Tue, 27 Sep 2022 17:30:13 +0200 Subject: [PATCH 20/38] deps: update dependency pyjwt to v2.5.0 (#805) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit [![Mend Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com) This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [pyjwt](https://togithub.com/jpadilla/pyjwt) | `==2.4.0` -> `==2.5.0` | [![age](https://badges.renovateapi.com/packages/pypi/pyjwt/2.5.0/age-slim)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://badges.renovateapi.com/packages/pypi/pyjwt/2.5.0/adoption-slim)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://badges.renovateapi.com/packages/pypi/pyjwt/2.5.0/compatibility-slim/2.4.0)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://badges.renovateapi.com/packages/pypi/pyjwt/2.5.0/confidence-slim/2.4.0)](https://docs.renovatebot.com/merge-confidence/) | --- ### Configuration 📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Renovate will not automatically rebase this PR, because other commits have been found. 🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] If you want to rebase/retry this PR, click this checkbox. ⚠ **Warning**: custom changes will be lost. --- This PR has been generated by [Mend Renovate](https://www.mend.io/free-developer-tools/renovate/). View repository job log [here](https://app.renovatebot.com/dashboard#github/googleapis/java-cloudbuild). From 571aabed6eceb3d86d73d03e7fb2d98a751875de Mon Sep 17 00:00:00 2001 From: WhiteSource Renovate Date: Tue, 27 Sep 2022 17:32:34 +0200 Subject: [PATCH 21/38] deps: update dependency protobuf to v3.20.2 (#804) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit [![Mend Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com) This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [protobuf](https://developers.google.com/protocol-buffers/) | `==3.19.5` -> `==3.20.2` | [![age](https://badges.renovateapi.com/packages/pypi/protobuf/3.20.2/age-slim)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://badges.renovateapi.com/packages/pypi/protobuf/3.20.2/adoption-slim)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://badges.renovateapi.com/packages/pypi/protobuf/3.20.2/compatibility-slim/3.19.5)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://badges.renovateapi.com/packages/pypi/protobuf/3.20.2/confidence-slim/3.19.5)](https://docs.renovatebot.com/merge-confidence/) | --- ### Configuration 📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Renovate will not automatically rebase this PR, because other commits have been found. 🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] If you want to rebase/retry this PR, click this checkbox. ⚠ **Warning**: custom changes will be lost. --- This PR has been generated by [Mend Renovate](https://www.mend.io/free-developer-tools/renovate/). View repository job log [here](https://app.renovatebot.com/dashboard#github/googleapis/java-cloudbuild). From ca6c52af55b9894ea45e218c64710517b906656e Mon Sep 17 00:00:00 2001 From: WhiteSource Renovate Date: Tue, 27 Sep 2022 17:44:22 +0200 Subject: [PATCH 22/38] deps: update dependency cachetools to v5 (#809) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit [![Mend Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com) This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [cachetools](https://togithub.com/tkem/cachetools) | `==4.2.4` -> `==5.2.0` | [![age](https://badges.renovateapi.com/packages/pypi/cachetools/5.2.0/age-slim)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://badges.renovateapi.com/packages/pypi/cachetools/5.2.0/adoption-slim)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://badges.renovateapi.com/packages/pypi/cachetools/5.2.0/compatibility-slim/4.2.4)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://badges.renovateapi.com/packages/pypi/cachetools/5.2.0/confidence-slim/4.2.4)](https://docs.renovatebot.com/merge-confidence/) | --- ### Configuration 📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Renovate will not automatically rebase this PR, because other commits have been found. 🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] If you want to rebase/retry this PR, click this checkbox. ⚠ **Warning**: custom changes will be lost. --- This PR has been generated by [Mend Renovate](https://www.mend.io/free-developer-tools/renovate/). View repository job log [here](https://app.renovatebot.com/dashboard#github/googleapis/java-cloudbuild). From 3246c6cfc1101da3bb1706bfb0ec5a5882729924 Mon Sep 17 00:00:00 2001 From: WhiteSource Renovate Date: Tue, 27 Sep 2022 17:44:36 +0200 Subject: [PATCH 23/38] deps: update dependency markupsafe to v2.1.1 (#803) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit [![Mend Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com) This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [markupsafe](https://palletsprojects.com/p/markupsafe/) ([changelog](https://markupsafe.palletsprojects.com/changes/)) | `==2.0.1` -> `==2.1.1` | [![age](https://badges.renovateapi.com/packages/pypi/markupsafe/2.1.1/age-slim)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://badges.renovateapi.com/packages/pypi/markupsafe/2.1.1/adoption-slim)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://badges.renovateapi.com/packages/pypi/markupsafe/2.1.1/compatibility-slim/2.0.1)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://badges.renovateapi.com/packages/pypi/markupsafe/2.1.1/confidence-slim/2.0.1)](https://docs.renovatebot.com/merge-confidence/) | --- ### Configuration 📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Renovate will not automatically rebase this PR, because other commits have been found. 🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] If you want to rebase/retry this PR, click this checkbox. ⚠ **Warning**: custom changes will be lost. --- This PR has been generated by [Mend Renovate](https://www.mend.io/free-developer-tools/renovate/). View repository job log [here](https://app.renovatebot.com/dashboard#github/googleapis/java-cloudbuild). From 22c4ae84de213398bc7ba81953d0c4fa8d5f7654 Mon Sep 17 00:00:00 2001 From: WhiteSource Renovate Date: Tue, 27 Sep 2022 17:48:23 +0200 Subject: [PATCH 24/38] deps: update dependency certifi to v2022.9.24 (#799) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit [![Mend Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com) This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [certifi](https://togithub.com/certifi/python-certifi) | `==2022.9.14` -> `==2022.9.24` | [![age](https://badges.renovateapi.com/packages/pypi/certifi/2022.9.24/age-slim)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://badges.renovateapi.com/packages/pypi/certifi/2022.9.24/adoption-slim)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://badges.renovateapi.com/packages/pypi/certifi/2022.9.24/compatibility-slim/2022.9.14)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://badges.renovateapi.com/packages/pypi/certifi/2022.9.24/confidence-slim/2022.9.14)](https://docs.renovatebot.com/merge-confidence/) | --- ### Configuration 📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Renovate will not automatically rebase this PR, because other commits have been found. 🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] If you want to rebase/retry this PR, click this checkbox. ⚠ **Warning**: custom changes will be lost. --- This PR has been generated by [Mend Renovate](https://www.mend.io/free-developer-tools/renovate/). View repository job log [here](https://app.renovatebot.com/dashboard#github/googleapis/java-cloudbuild). From 6a24a10c6831f45d86ce6f390fdfd87719f80bd7 Mon Sep 17 00:00:00 2001 From: "release-please[bot]" <55107282+release-please[bot]@users.noreply.github.com> Date: Tue, 27 Sep 2022 16:12:18 +0000 Subject: [PATCH 25/38] chore(main): release 3.5.5 (#810) :robot: I have created a release *beep* *boop* --- ## [3.5.5](https://github.com/googleapis/java-cloudbuild/compare/v3.5.4...v3.5.5) (2022-09-27) ### Dependencies * Update dependency cachetools to v5 ([#809](https://github.com/googleapis/java-cloudbuild/issues/809)) ([ca6c52a](https://github.com/googleapis/java-cloudbuild/commit/ca6c52af55b9894ea45e218c64710517b906656e)) * Update dependency certifi to v2022.9.24 ([#799](https://github.com/googleapis/java-cloudbuild/issues/799)) ([22c4ae8](https://github.com/googleapis/java-cloudbuild/commit/22c4ae84de213398bc7ba81953d0c4fa8d5f7654)) * Update dependency google-auth to v2.11.1 ([#800](https://github.com/googleapis/java-cloudbuild/issues/800)) ([4a8e780](https://github.com/googleapis/java-cloudbuild/commit/4a8e7808320ed561667cbc76e9ca3323781594bc)) * Update dependency jinja2 to v3.1.2 ([#801](https://github.com/googleapis/java-cloudbuild/issues/801)) ([0ccbc5a](https://github.com/googleapis/java-cloudbuild/commit/0ccbc5ab0f2d18474f18fd0c84d85ddead5676d3)) * Update dependency keyring to v23.9.3 ([#802](https://github.com/googleapis/java-cloudbuild/issues/802)) ([5a0da57](https://github.com/googleapis/java-cloudbuild/commit/5a0da57d3211f49a3d6b61a0310dca850f2d739e)) * Update dependency markupsafe to v2.1.1 ([#803](https://github.com/googleapis/java-cloudbuild/issues/803)) ([3246c6c](https://github.com/googleapis/java-cloudbuild/commit/3246c6cfc1101da3bb1706bfb0ec5a5882729924)) * Update dependency protobuf to v3.20.2 ([#804](https://github.com/googleapis/java-cloudbuild/issues/804)) ([571aabe](https://github.com/googleapis/java-cloudbuild/commit/571aabed6eceb3d86d73d03e7fb2d98a751875de)) * Update dependency pyjwt to v2.5.0 ([#805](https://github.com/googleapis/java-cloudbuild/issues/805)) ([9de32d3](https://github.com/googleapis/java-cloudbuild/commit/9de32d3bfea0b614333ea8601269539c38256863)) * Update dependency requests to v2.28.1 ([#806](https://github.com/googleapis/java-cloudbuild/issues/806)) ([affd465](https://github.com/googleapis/java-cloudbuild/commit/affd4651305327b69b6577b3ed3cffb8153447cd)) * Update dependency typing-extensions to v4.3.0 ([#807](https://github.com/googleapis/java-cloudbuild/issues/807)) ([f7b3b2c](https://github.com/googleapis/java-cloudbuild/commit/f7b3b2cfcfc4c6e9bdb5cf70cb6fa0faa4503375)) * Update dependency zipp to v3.8.1 ([#808](https://github.com/googleapis/java-cloudbuild/issues/808)) ([8549944](https://github.com/googleapis/java-cloudbuild/commit/8549944a8c2769929a564222409a186c70daf404)) --- This PR was generated with [Release Please](https://github.com/googleapis/release-please). See [documentation](https://github.com/googleapis/release-please#release-please). --- CHANGELOG.md | 17 +++++++++++++++++ google-cloud-build-bom/pom.xml | 8 ++++---- google-cloud-build/pom.xml | 4 ++-- grpc-google-cloud-build-v1/pom.xml | 4 ++-- pom.xml | 8 ++++---- proto-google-cloud-build-v1/pom.xml | 4 ++-- versions.txt | 6 +++--- 7 files changed, 34 insertions(+), 17 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index df623804..daa7640b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,22 @@ # Changelog +## [3.5.5](https://github.com/googleapis/java-cloudbuild/compare/v3.5.4...v3.5.5) (2022-09-27) + + +### Dependencies + +* Update dependency cachetools to v5 ([#809](https://github.com/googleapis/java-cloudbuild/issues/809)) ([ca6c52a](https://github.com/googleapis/java-cloudbuild/commit/ca6c52af55b9894ea45e218c64710517b906656e)) +* Update dependency certifi to v2022.9.24 ([#799](https://github.com/googleapis/java-cloudbuild/issues/799)) ([22c4ae8](https://github.com/googleapis/java-cloudbuild/commit/22c4ae84de213398bc7ba81953d0c4fa8d5f7654)) +* Update dependency google-auth to v2.11.1 ([#800](https://github.com/googleapis/java-cloudbuild/issues/800)) ([4a8e780](https://github.com/googleapis/java-cloudbuild/commit/4a8e7808320ed561667cbc76e9ca3323781594bc)) +* Update dependency jinja2 to v3.1.2 ([#801](https://github.com/googleapis/java-cloudbuild/issues/801)) ([0ccbc5a](https://github.com/googleapis/java-cloudbuild/commit/0ccbc5ab0f2d18474f18fd0c84d85ddead5676d3)) +* Update dependency keyring to v23.9.3 ([#802](https://github.com/googleapis/java-cloudbuild/issues/802)) ([5a0da57](https://github.com/googleapis/java-cloudbuild/commit/5a0da57d3211f49a3d6b61a0310dca850f2d739e)) +* Update dependency markupsafe to v2.1.1 ([#803](https://github.com/googleapis/java-cloudbuild/issues/803)) ([3246c6c](https://github.com/googleapis/java-cloudbuild/commit/3246c6cfc1101da3bb1706bfb0ec5a5882729924)) +* Update dependency protobuf to v3.20.2 ([#804](https://github.com/googleapis/java-cloudbuild/issues/804)) ([571aabe](https://github.com/googleapis/java-cloudbuild/commit/571aabed6eceb3d86d73d03e7fb2d98a751875de)) +* Update dependency pyjwt to v2.5.0 ([#805](https://github.com/googleapis/java-cloudbuild/issues/805)) ([9de32d3](https://github.com/googleapis/java-cloudbuild/commit/9de32d3bfea0b614333ea8601269539c38256863)) +* Update dependency requests to v2.28.1 ([#806](https://github.com/googleapis/java-cloudbuild/issues/806)) ([affd465](https://github.com/googleapis/java-cloudbuild/commit/affd4651305327b69b6577b3ed3cffb8153447cd)) +* Update dependency typing-extensions to v4.3.0 ([#807](https://github.com/googleapis/java-cloudbuild/issues/807)) ([f7b3b2c](https://github.com/googleapis/java-cloudbuild/commit/f7b3b2cfcfc4c6e9bdb5cf70cb6fa0faa4503375)) +* Update dependency zipp to v3.8.1 ([#808](https://github.com/googleapis/java-cloudbuild/issues/808)) ([8549944](https://github.com/googleapis/java-cloudbuild/commit/8549944a8c2769929a564222409a186c70daf404)) + ## [3.5.4](https://github.com/googleapis/java-cloudbuild/compare/v3.5.3...v3.5.4) (2022-09-15) diff --git a/google-cloud-build-bom/pom.xml b/google-cloud-build-bom/pom.xml index 57ce3dcf..8b1f498c 100644 --- a/google-cloud-build-bom/pom.xml +++ b/google-cloud-build-bom/pom.xml @@ -3,7 +3,7 @@ 4.0.0 com.google.cloud google-cloud-build-bom - 3.5.5-SNAPSHOT + 3.5.5 pom com.google.cloud @@ -52,17 +52,17 @@ com.google.cloud google-cloud-build - 3.5.5-SNAPSHOT + 3.5.5 com.google.api.grpc grpc-google-cloud-build-v1 - 3.5.5-SNAPSHOT + 3.5.5 com.google.api.grpc proto-google-cloud-build-v1 - 3.5.5-SNAPSHOT + 3.5.5 diff --git a/google-cloud-build/pom.xml b/google-cloud-build/pom.xml index ae582361..033dcdcc 100644 --- a/google-cloud-build/pom.xml +++ b/google-cloud-build/pom.xml @@ -3,7 +3,7 @@ 4.0.0 com.google.cloud google-cloud-build - 3.5.5-SNAPSHOT + 3.5.5 jar Google Cloud Build https://github.com/googleapis/java-cloudbuild @@ -13,7 +13,7 @@ com.google.cloud google-cloud-build-parent - 3.5.5-SNAPSHOT + 3.5.5 google-cloud-build diff --git a/grpc-google-cloud-build-v1/pom.xml b/grpc-google-cloud-build-v1/pom.xml index 09d8b391..dc6654d4 100644 --- a/grpc-google-cloud-build-v1/pom.xml +++ b/grpc-google-cloud-build-v1/pom.xml @@ -4,13 +4,13 @@ 4.0.0 com.google.api.grpc grpc-google-cloud-build-v1 - 3.5.5-SNAPSHOT + 3.5.5 grpc-google-cloud-build-v1 GRPC library for grpc-google-cloud-build-v1 com.google.cloud google-cloud-build-parent - 3.5.5-SNAPSHOT + 3.5.5 diff --git a/pom.xml b/pom.xml index a3ba6e6d..c7ee0229 100644 --- a/pom.xml +++ b/pom.xml @@ -4,7 +4,7 @@ com.google.cloud google-cloud-build-parent pom - 3.5.5-SNAPSHOT + 3.5.5 Google Cloud Build Parent https://github.com/googleapis/java-cloudbuild @@ -62,17 +62,17 @@ com.google.api.grpc proto-google-cloud-build-v1 - 3.5.5-SNAPSHOT + 3.5.5 com.google.cloud google-cloud-build - 3.5.5-SNAPSHOT + 3.5.5 com.google.api.grpc grpc-google-cloud-build-v1 - 3.5.5-SNAPSHOT + 3.5.5 diff --git a/proto-google-cloud-build-v1/pom.xml b/proto-google-cloud-build-v1/pom.xml index 88ebb7e2..172b95de 100644 --- a/proto-google-cloud-build-v1/pom.xml +++ b/proto-google-cloud-build-v1/pom.xml @@ -4,13 +4,13 @@ 4.0.0 com.google.api.grpc proto-google-cloud-build-v1 - 3.5.5-SNAPSHOT + 3.5.5 proto-google-cloud-build-v1 PROTO library for proto-google-cloud-build-v1 com.google.cloud google-cloud-build-parent - 3.5.5-SNAPSHOT + 3.5.5 diff --git a/versions.txt b/versions.txt index 6a771648..905b620b 100644 --- a/versions.txt +++ b/versions.txt @@ -1,6 +1,6 @@ # Format: # module:released-version:current-version -google-cloud-build:3.5.4:3.5.5-SNAPSHOT -grpc-google-cloud-build-v1:3.5.4:3.5.5-SNAPSHOT -proto-google-cloud-build-v1:3.5.4:3.5.5-SNAPSHOT +google-cloud-build:3.5.5:3.5.5 +grpc-google-cloud-build-v1:3.5.5:3.5.5 +proto-google-cloud-build-v1:3.5.5:3.5.5 From 2a755d295e3ba4e4c511f9f44af3f44b8b294591 Mon Sep 17 00:00:00 2001 From: "gcf-owl-bot[bot]" <78513119+gcf-owl-bot[bot]@users.noreply.github.com> Date: Wed, 28 Sep 2022 01:14:26 +0000 Subject: [PATCH 26/38] chore: exclude requirements.txt file from renovate-bot (#1594) (#798) Source-Link: https://github.com/googleapis/synthtool/commit/f58d3135a2fab20e225d98741dbc06d57459b816 Post-Processor: gcr.io/cloud-devrel-public-resources/owlbot-java:latest@sha256:f14e3fefe8e361e85752bd9890c8e56f2fe25f1e89cbb9597e4e3c7a429203a3 --- .github/.OwlBot.lock.yaml | 3 ++- README.md | 6 +++--- renovate.json | 1 + 3 files changed, 6 insertions(+), 4 deletions(-) diff --git a/.github/.OwlBot.lock.yaml b/.github/.OwlBot.lock.yaml index 791e842d..2c3ef720 100644 --- a/.github/.OwlBot.lock.yaml +++ b/.github/.OwlBot.lock.yaml @@ -13,4 +13,5 @@ # limitations under the License. docker: image: gcr.io/cloud-devrel-public-resources/owlbot-java:latest - digest: sha256:6566dc8226f20993af18e5a4e7a2b1ba85a292b02dedb6a1634cf10e1b418fa5 + digest: sha256:f14e3fefe8e361e85752bd9890c8e56f2fe25f1e89cbb9597e4e3c7a429203a3 + diff --git a/README.md b/README.md index b71cd62d..0486aea1 100644 --- a/README.md +++ b/README.md @@ -19,20 +19,20 @@ If you are using Maven, add this to your pom.xml file: com.google.cloud google-cloud-build - 3.5.4 + 3.5.5 ``` If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-build:3.5.4' +implementation 'com.google.cloud:google-cloud-build:3.5.5' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-build" % "3.5.4" +libraryDependencies += "com.google.cloud" % "google-cloud-build" % "3.5.5" ``` ## Authentication diff --git a/renovate.json b/renovate.json index c630b9df..201d65e9 100644 --- a/renovate.json +++ b/renovate.json @@ -10,6 +10,7 @@ ":maintainLockFilesDisabled", ":autodetectPinVersions" ], + "ignorePaths": [".kokoro/requirements.txt"], "packageRules": [ { "packagePatterns": [ From 17d40585a9e7535834770dd522624bb1d59b0dab Mon Sep 17 00:00:00 2001 From: WhiteSource Renovate Date: Wed, 28 Sep 2022 06:52:30 +0200 Subject: [PATCH 27/38] chore(deps): update dependency com.google.cloud:google-cloud-build to v3.5.5 (#812) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit [![Mend Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com) This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [com.google.cloud:google-cloud-build](https://togithub.com/googleapis/java-cloudbuild) | `3.5.4` -> `3.5.5` | [![age](https://badges.renovateapi.com/packages/maven/com.google.cloud:google-cloud-build/3.5.5/age-slim)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://badges.renovateapi.com/packages/maven/com.google.cloud:google-cloud-build/3.5.5/adoption-slim)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://badges.renovateapi.com/packages/maven/com.google.cloud:google-cloud-build/3.5.5/compatibility-slim/3.5.4)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://badges.renovateapi.com/packages/maven/com.google.cloud:google-cloud-build/3.5.5/confidence-slim/3.5.4)](https://docs.renovatebot.com/merge-confidence/) | --- ### Release Notes
googleapis/java-cloudbuild ### [`v3.5.5`](https://togithub.com/googleapis/java-cloudbuild/blob/HEAD/CHANGELOG.md#​355-httpsgithubcomgoogleapisjava-cloudbuildcomparev354v355-2022-09-27) [Compare Source](https://togithub.com/googleapis/java-cloudbuild/compare/v3.5.4...v3.5.5) ##### Dependencies - Update dependency cachetools to v5 ([#​809](https://togithub.com/googleapis/java-cloudbuild/issues/809)) ([ca6c52a](https://togithub.com/googleapis/java-cloudbuild/commit/ca6c52af55b9894ea45e218c64710517b906656e)) - Update dependency certifi to v2022.9.24 ([#​799](https://togithub.com/googleapis/java-cloudbuild/issues/799)) ([22c4ae8](https://togithub.com/googleapis/java-cloudbuild/commit/22c4ae84de213398bc7ba81953d0c4fa8d5f7654)) - Update dependency google-auth to v2.11.1 ([#​800](https://togithub.com/googleapis/java-cloudbuild/issues/800)) ([4a8e780](https://togithub.com/googleapis/java-cloudbuild/commit/4a8e7808320ed561667cbc76e9ca3323781594bc)) - Update dependency jinja2 to v3.1.2 ([#​801](https://togithub.com/googleapis/java-cloudbuild/issues/801)) ([0ccbc5a](https://togithub.com/googleapis/java-cloudbuild/commit/0ccbc5ab0f2d18474f18fd0c84d85ddead5676d3)) - Update dependency keyring to v23.9.3 ([#​802](https://togithub.com/googleapis/java-cloudbuild/issues/802)) ([5a0da57](https://togithub.com/googleapis/java-cloudbuild/commit/5a0da57d3211f49a3d6b61a0310dca850f2d739e)) - Update dependency markupsafe to v2.1.1 ([#​803](https://togithub.com/googleapis/java-cloudbuild/issues/803)) ([3246c6c](https://togithub.com/googleapis/java-cloudbuild/commit/3246c6cfc1101da3bb1706bfb0ec5a5882729924)) - Update dependency protobuf to v3.20.2 ([#​804](https://togithub.com/googleapis/java-cloudbuild/issues/804)) ([571aabe](https://togithub.com/googleapis/java-cloudbuild/commit/571aabed6eceb3d86d73d03e7fb2d98a751875de)) - Update dependency pyjwt to v2.5.0 ([#​805](https://togithub.com/googleapis/java-cloudbuild/issues/805)) ([9de32d3](https://togithub.com/googleapis/java-cloudbuild/commit/9de32d3bfea0b614333ea8601269539c38256863)) - Update dependency requests to v2.28.1 ([#​806](https://togithub.com/googleapis/java-cloudbuild/issues/806)) ([affd465](https://togithub.com/googleapis/java-cloudbuild/commit/affd4651305327b69b6577b3ed3cffb8153447cd)) - Update dependency typing-extensions to v4.3.0 ([#​807](https://togithub.com/googleapis/java-cloudbuild/issues/807)) ([f7b3b2c](https://togithub.com/googleapis/java-cloudbuild/commit/f7b3b2cfcfc4c6e9bdb5cf70cb6fa0faa4503375)) - Update dependency zipp to v3.8.1 ([#​808](https://togithub.com/googleapis/java-cloudbuild/issues/808)) ([8549944](https://togithub.com/googleapis/java-cloudbuild/commit/8549944a8c2769929a564222409a186c70daf404))
--- ### Configuration 📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. 🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] If you want to rebase/retry this PR, click this checkbox. --- This PR has been generated by [Mend Renovate](https://www.mend.io/free-developer-tools/renovate/). View repository job log [here](https://app.renovatebot.com/dashboard#github/googleapis/java-cloudbuild). --- samples/install-without-bom/pom.xml | 2 +- samples/snapshot/pom.xml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/samples/install-without-bom/pom.xml b/samples/install-without-bom/pom.xml index 21aebf26..bf8e5f6e 100644 --- a/samples/install-without-bom/pom.xml +++ b/samples/install-without-bom/pom.xml @@ -29,7 +29,7 @@ com.google.cloud google-cloud-build - 3.5.4 + 3.5.5 diff --git a/samples/snapshot/pom.xml b/samples/snapshot/pom.xml index d46ebaa5..9b0f7e82 100644 --- a/samples/snapshot/pom.xml +++ b/samples/snapshot/pom.xml @@ -28,7 +28,7 @@ com.google.cloud google-cloud-build - 3.5.4 + 3.5.5 From 5cbf28b9c9321111d6dc811d36d59cd4635e7c9b Mon Sep 17 00:00:00 2001 From: WhiteSource Renovate Date: Mon, 3 Oct 2022 15:56:18 +0200 Subject: [PATCH 28/38] deps: update dependency com.google.cloud:google-cloud-shared-dependencies to v3.0.4 (#814) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit [![Mend Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com) This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [com.google.cloud:google-cloud-shared-dependencies](https://togithub.com/googleapis/java-shared-dependencies) | `3.0.3` -> `3.0.4` | [![age](https://badges.renovateapi.com/packages/maven/com.google.cloud:google-cloud-shared-dependencies/3.0.4/age-slim)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://badges.renovateapi.com/packages/maven/com.google.cloud:google-cloud-shared-dependencies/3.0.4/adoption-slim)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://badges.renovateapi.com/packages/maven/com.google.cloud:google-cloud-shared-dependencies/3.0.4/compatibility-slim/3.0.3)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://badges.renovateapi.com/packages/maven/com.google.cloud:google-cloud-shared-dependencies/3.0.4/confidence-slim/3.0.3)](https://docs.renovatebot.com/merge-confidence/) | --- ### Release Notes
googleapis/java-shared-dependencies ### [`v3.0.4`](https://togithub.com/googleapis/java-shared-dependencies/blob/HEAD/CHANGELOG.md#​304-httpsgithubcomgoogleapisjava-shared-dependenciescomparev303v304-2022-10-03) [Compare Source](https://togithub.com/googleapis/java-shared-dependencies/compare/v3.0.3...v3.0.4) ##### Dependencies - Update dependency cachetools to v5 ([#​816](https://togithub.com/googleapis/java-shared-dependencies/issues/816)) ([3f6c408](https://togithub.com/googleapis/java-shared-dependencies/commit/3f6c408210c931c286235f61c7aadea5bf5cfe4d)) - Update dependency certifi to v2022.9.24 ([#​818](https://togithub.com/googleapis/java-shared-dependencies/issues/818)) ([5f04b97](https://togithub.com/googleapis/java-shared-dependencies/commit/5f04b97c2343146600e8c9ee65afdeb58f5743a6)) - Update dependency charset-normalizer to v2.1.1 ([#​822](https://togithub.com/googleapis/java-shared-dependencies/issues/822)) ([6997c5a](https://togithub.com/googleapis/java-shared-dependencies/commit/6997c5acad937ebe3594330de73261a424d42cf3)) - Update dependency click to v8.1.3 ([#​823](https://togithub.com/googleapis/java-shared-dependencies/issues/823)) ([42bf9f8](https://togithub.com/googleapis/java-shared-dependencies/commit/42bf9f834fdafea60f2be7ccbf7d363e058cd7c2)) - Update dependency com.google.protobuf:protobuf-bom to v3.21.7 ([#​837](https://togithub.com/googleapis/java-shared-dependencies/issues/837)) ([d31e507](https://togithub.com/googleapis/java-shared-dependencies/commit/d31e5077c7e036de5e238e9a611df7ced527574a)) - Update dependency gcp-releasetool to v1.8.8 ([#​819](https://togithub.com/googleapis/java-shared-dependencies/issues/819)) ([8245d97](https://togithub.com/googleapis/java-shared-dependencies/commit/8245d975fb12e81454ec7664f9a7c9809bbac697)) - Update dependency gcp-releasetool to v1.8.9 ([#​846](https://togithub.com/googleapis/java-shared-dependencies/issues/846)) ([04e3283](https://togithub.com/googleapis/java-shared-dependencies/commit/04e32831c6e87c372444901013a747d2d02ce38d)) - Update dependency google-api-core to v2.10.1 ([#​824](https://togithub.com/googleapis/java-shared-dependencies/issues/824)) ([818b9aa](https://togithub.com/googleapis/java-shared-dependencies/commit/818b9aa2ac99d8b1f9b39a74b626122aed5f1d94)) - Update dependency google-auth to v2.12.0 ([#​825](https://togithub.com/googleapis/java-shared-dependencies/issues/825)) ([07c544b](https://togithub.com/googleapis/java-shared-dependencies/commit/07c544b5e0fa9f7110bbc957570f7a405962072e)) - Update dependency google-cloud-core to v2.3.2 ([#​820](https://togithub.com/googleapis/java-shared-dependencies/issues/820)) ([2a219e8](https://togithub.com/googleapis/java-shared-dependencies/commit/2a219e86f187ba5ad72f2570bd58ca6100128c43)) - Update dependency google-cloud-storage to v2.5.0 ([#​826](https://togithub.com/googleapis/java-shared-dependencies/issues/826)) ([bb10d18](https://togithub.com/googleapis/java-shared-dependencies/commit/bb10d1858a515f09d365362ffa0110a5b362c96b)) - Update dependency google-crc32c to v1.5.0 ([#​827](https://togithub.com/googleapis/java-shared-dependencies/issues/827)) ([7e5dae6](https://togithub.com/googleapis/java-shared-dependencies/commit/7e5dae60d667cb84b9ee4f6c977bdc35e79e4cf6)) - Update dependency google-resumable-media to v2.4.0 ([#​838](https://togithub.com/googleapis/java-shared-dependencies/issues/838)) ([ad82d63](https://togithub.com/googleapis/java-shared-dependencies/commit/ad82d6378f64039da383509638fb4782908eb4bc)) - Update dependency googleapis-common-protos to v1.56.4 ([#​821](https://togithub.com/googleapis/java-shared-dependencies/issues/821)) ([93d7745](https://togithub.com/googleapis/java-shared-dependencies/commit/93d77458c9bbf84ec367cdb4caaa41e6f71675c6)) - Update dependency importlib-metadata to v4.12.0 ([#​832](https://togithub.com/googleapis/java-shared-dependencies/issues/832)) ([ee19fb1](https://togithub.com/googleapis/java-shared-dependencies/commit/ee19fb1ca5a2a2e1985297e3b72d44de68bc72e3)) - Update dependency importlib-metadata to v4.13.0 ([#​843](https://togithub.com/googleapis/java-shared-dependencies/issues/843)) ([d2ede60](https://togithub.com/googleapis/java-shared-dependencies/commit/d2ede601eee8c875780c7eb5924623537480c509)) - Update dependency importlib-metadata to v5 ([#​845](https://togithub.com/googleapis/java-shared-dependencies/issues/845)) ([03ac7e8](https://togithub.com/googleapis/java-shared-dependencies/commit/03ac7e800274c5f58d2bc4ddd0561bfcdea1bb27)) - Update dependency io.grpc:grpc-bom to v1.49.1 ([#​802](https://togithub.com/googleapis/java-shared-dependencies/issues/802)) ([b8c54bf](https://togithub.com/googleapis/java-shared-dependencies/commit/b8c54bf8f1ddecc788cee151f8afe42de45bdc9d)) - Update dependency io.grpc:grpc-bom to v1.49.2 ([#​842](https://togithub.com/googleapis/java-shared-dependencies/issues/842)) ([1b1cfa2](https://togithub.com/googleapis/java-shared-dependencies/commit/1b1cfa27d05f7732da12721305cf41dcbebda232)) - Update dependency jeepney to v0.8.0 ([#​833](https://togithub.com/googleapis/java-shared-dependencies/issues/833)) ([15d2f9f](https://togithub.com/googleapis/java-shared-dependencies/commit/15d2f9f52b5a3259db0813df3d2424e256ccb372)) - Update dependency jinja2 to v3.1.2 ([#​834](https://togithub.com/googleapis/java-shared-dependencies/issues/834)) ([c188f95](https://togithub.com/googleapis/java-shared-dependencies/commit/c188f95acdb3349f1c4b3ed56e5fffb75e8fbc8d)) - Update dependency keyring to v23.9.3 ([#​828](https://togithub.com/googleapis/java-shared-dependencies/issues/828)) ([b185aaa](https://togithub.com/googleapis/java-shared-dependencies/commit/b185aaae716d4d97cb64f0426cac0e778f11223d)) - Update dependency markupsafe to v2.1.1 ([#​829](https://togithub.com/googleapis/java-shared-dependencies/issues/829)) ([add2825](https://togithub.com/googleapis/java-shared-dependencies/commit/add2825bd34cd80f529dbe0dadb3c84219177916)) - Update dependency org.threeten:threetenbp to v1.6.2 ([#​808](https://togithub.com/googleapis/java-shared-dependencies/issues/808)) ([2d2eabd](https://togithub.com/googleapis/java-shared-dependencies/commit/2d2eabd14d8150207885ea47280c0f7ff3d2962f)) - Update dependency protobuf to v3.20.2 ([#​830](https://togithub.com/googleapis/java-shared-dependencies/issues/830)) ([5afa76f](https://togithub.com/googleapis/java-shared-dependencies/commit/5afa76f9ef4705aecba49abc7bb93982fb1ecf3e)) - Update dependency protobuf to v3.20.3 ([#​839](https://togithub.com/googleapis/java-shared-dependencies/issues/839)) ([d9fc7dd](https://togithub.com/googleapis/java-shared-dependencies/commit/d9fc7ddd3e663458e6ea3f78a3c6241377df0319)) - Update dependency protobuf to v4 ([#​817](https://togithub.com/googleapis/java-shared-dependencies/issues/817)) ([ee8d154](https://togithub.com/googleapis/java-shared-dependencies/commit/ee8d154287ccd256b4dcfa48f28f5ec61a91fe3e)) - Update dependency pyjwt to v2.5.0 ([#​812](https://togithub.com/googleapis/java-shared-dependencies/issues/812)) ([4d4528e](https://togithub.com/googleapis/java-shared-dependencies/commit/4d4528e8ce269d49b99d2dbc4fcda2dc37a058cb)) - Update dependency requests to v2.28.1 ([#​813](https://togithub.com/googleapis/java-shared-dependencies/issues/813)) ([a3a8d89](https://togithub.com/googleapis/java-shared-dependencies/commit/a3a8d89b0117007a7108553c70aa82dd289e1691)) - Update dependency typing-extensions to v4.3.0 ([#​814](https://togithub.com/googleapis/java-shared-dependencies/issues/814)) ([da875e5](https://togithub.com/googleapis/java-shared-dependencies/commit/da875e5e91fa9d8c177e6c3afc9e34242eb914b7)) - Update dependency zipp to v3.8.1 ([#​815](https://togithub.com/googleapis/java-shared-dependencies/issues/815)) ([15585fd](https://togithub.com/googleapis/java-shared-dependencies/commit/15585fd0216013fe93be011f93f391f6269aa777)) - Update gax.version to v2.19.2 ([#​847](https://togithub.com/googleapis/java-shared-dependencies/issues/847)) ([c4afe1f](https://togithub.com/googleapis/java-shared-dependencies/commit/c4afe1fdc88af29ab039cea618d52c15c90e43e9)) - Update google.common-protos.version to v2.9.3 ([#​803](https://togithub.com/googleapis/java-shared-dependencies/issues/803)) ([a3e8e5e](https://togithub.com/googleapis/java-shared-dependencies/commit/a3e8e5eb53a8da14abf3b8d81a4f34fbb2f3b8f9)) - Update google.common-protos.version to v2.9.5 ([#​831](https://togithub.com/googleapis/java-shared-dependencies/issues/831)) ([1c901db](https://togithub.com/googleapis/java-shared-dependencies/commit/1c901db8a7740afaec3e809e51d4d369fbf469c4)) - Update google.common-protos.version to v2.9.6 ([#​844](https://togithub.com/googleapis/java-shared-dependencies/issues/844)) ([9e156be](https://togithub.com/googleapis/java-shared-dependencies/commit/9e156be59bd89959f04252c3045b8cd7a8be8070)) - Update google.core.version to v2.8.13 ([#​804](https://togithub.com/googleapis/java-shared-dependencies/issues/804)) ([45ae571](https://togithub.com/googleapis/java-shared-dependencies/commit/45ae57142bd6d5334eedd46243736b200a459795)) - Update google.core.version to v2.8.14 ([#​805](https://togithub.com/googleapis/java-shared-dependencies/issues/805)) ([02c9397](https://togithub.com/googleapis/java-shared-dependencies/commit/02c9397a84bf3fcca8d04e4c9867cc47689abde2)) - Update google.core.version to v2.8.15 ([#​807](https://togithub.com/googleapis/java-shared-dependencies/issues/807)) ([980856c](https://togithub.com/googleapis/java-shared-dependencies/commit/980856c43981992a3d08f69eac83aeada752d244)) - Update google.core.version to v2.8.16 ([#​810](https://togithub.com/googleapis/java-shared-dependencies/issues/810)) ([c2b2c9a](https://togithub.com/googleapis/java-shared-dependencies/commit/c2b2c9a327fd588f69524bb93a17e5d4ae8f5a42)) - Update google.core.version to v2.8.17 ([#​835](https://togithub.com/googleapis/java-shared-dependencies/issues/835)) ([3def21d](https://togithub.com/googleapis/java-shared-dependencies/commit/3def21df2e4253e3df0da064b6c4e472df079d2b)) - Update google.core.version to v2.8.18 ([#​840](https://togithub.com/googleapis/java-shared-dependencies/issues/840)) ([46566dc](https://togithub.com/googleapis/java-shared-dependencies/commit/46566dc18c4b1ed41c482b4ce21b92651e2f9dc5)) - Update google.core.version to v2.8.19 ([#​841](https://togithub.com/googleapis/java-shared-dependencies/issues/841)) ([99afde9](https://togithub.com/googleapis/java-shared-dependencies/commit/99afde97ea498f549eb75cc58c4ed88edf81b20d)) - Update google.core.version to v2.8.20 ([#​848](https://togithub.com/googleapis/java-shared-dependencies/issues/848)) ([c980c4f](https://togithub.com/googleapis/java-shared-dependencies/commit/c980c4fdfc8890d812b4881ba5b87bfd21269a5f)) - Update iam.version to v1.6.1 ([#​806](https://togithub.com/googleapis/java-shared-dependencies/issues/806)) ([a50158d](https://togithub.com/googleapis/java-shared-dependencies/commit/a50158d3b83cf8e02d8ee08c94e512b5669a927b)) - Update iam.version to v1.6.2 ([#​849](https://togithub.com/googleapis/java-shared-dependencies/issues/849)) ([e43ac96](https://togithub.com/googleapis/java-shared-dependencies/commit/e43ac96bc189a096a9311c9b03e85c86bea07e99))
--- ### Configuration 📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. 🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] If you want to rebase/retry this PR, click this checkbox. --- This PR has been generated by [Mend Renovate](https://www.mend.io/free-developer-tools/renovate/). View repository job log [here](https://app.renovatebot.com/dashboard#github/googleapis/java-cloudbuild). --- pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pom.xml b/pom.xml index c7ee0229..5404320d 100644 --- a/pom.xml +++ b/pom.xml @@ -78,7 +78,7 @@ com.google.cloud google-cloud-shared-dependencies - 3.0.3 + 3.0.4 pom import From e6a52e1081307a8a1870fba9dbd0289e5f5c2554 Mon Sep 17 00:00:00 2001 From: "gcf-owl-bot[bot]" <78513119+gcf-owl-bot[bot]@users.noreply.github.com> Date: Mon, 3 Oct 2022 17:22:15 +0000 Subject: [PATCH 29/38] chore(bazel): update protobuf to v3.21.7 (#813) - [ ] Regenerate this pull request now. PiperOrigin-RevId: 477955264 Source-Link: https://togithub.com/googleapis/googleapis/commit/a724450af76d0001f23602684c49cd6a4b3a5654 Source-Link: https://togithub.com/googleapis/googleapis-gen/commit/4abcbcaec855e74a0b22a4988cf9e0eb61a83094 Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiNGFiY2JjYWVjODU1ZTc0YTBiMjJhNDk4OGNmOWUwZWI2MWE4MzA5NCJ9 --- .../google/cloudbuild/v1/ApprovalConfig.java | 110 +-- .../google/cloudbuild/v1/ApprovalResult.java | 172 ++-- .../cloudbuild/v1/ApproveBuildRequest.java | 134 +-- .../google/cloudbuild/v1/ArtifactResult.java | 145 ++- .../com/google/cloudbuild/v1/Artifacts.java | 300 +++--- .../java/com/google/cloudbuild/v1/Build.java | 935 +++++++----------- .../google/cloudbuild/v1/BuildApproval.java | 156 ++- .../cloudbuild/v1/BuildOperationMetadata.java | 120 +-- .../google/cloudbuild/v1/BuildOptions.java | 453 ++++----- .../com/google/cloudbuild/v1/BuildStep.java | 351 +++---- .../google/cloudbuild/v1/BuildTrigger.java | 436 ++++---- .../com/google/cloudbuild/v1/BuiltImage.java | 146 ++- .../cloudbuild/v1/CancelBuildRequest.java | 138 ++- .../cloudbuild/v1/CreateBuildRequest.java | 146 ++- .../v1/CreateBuildTriggerRequest.java | 148 ++- .../v1/CreateWorkerPoolOperationMetadata.java | 155 ++- .../v1/CreateWorkerPoolRequest.java | 158 ++- .../v1/DeleteBuildTriggerRequest.java | 139 ++- .../v1/DeleteWorkerPoolOperationMetadata.java | 155 ++- .../v1/DeleteWorkerPoolRequest.java | 147 ++- .../com/google/cloudbuild/v1/FileHashes.java | 130 +-- .../google/cloudbuild/v1/GetBuildRequest.java | 138 ++- .../cloudbuild/v1/GetBuildTriggerRequest.java | 138 ++- .../cloudbuild/v1/GetWorkerPoolRequest.java | 112 +-- .../cloudbuild/v1/GitHubEventsConfig.java | 186 ++-- .../java/com/google/cloudbuild/v1/Hash.java | 123 +-- .../google/cloudbuild/v1/InlineSecret.java | 140 ++- .../v1/ListBuildTriggersRequest.java | 150 ++- .../v1/ListBuildTriggersResponse.java | 146 ++- .../cloudbuild/v1/ListBuildsRequest.java | 162 ++- .../cloudbuild/v1/ListBuildsResponse.java | 143 ++- .../cloudbuild/v1/ListWorkerPoolsRequest.java | 136 ++- .../v1/ListWorkerPoolsResponse.java | 145 ++- .../cloudbuild/v1/PrivatePoolV1Config.java | 397 +++----- .../google/cloudbuild/v1/PubsubConfig.java | 151 ++- .../cloudbuild/v1/PullRequestFilter.java | 137 ++- .../com/google/cloudbuild/v1/PushFilter.java | 138 ++- .../v1/ReceiveTriggerWebhookRequest.java | 172 ++-- .../v1/ReceiveTriggerWebhookResponse.java | 100 +- .../com/google/cloudbuild/v1/RepoSource.java | 220 ++--- .../com/google/cloudbuild/v1/Results.java | 216 ++-- .../cloudbuild/v1/RetryBuildRequest.java | 138 ++- .../cloudbuild/v1/RunBuildTriggerRequest.java | 160 ++- .../java/com/google/cloudbuild/v1/Secret.java | 141 ++- .../cloudbuild/v1/SecretManagerSecret.java | 125 +-- .../com/google/cloudbuild/v1/Secrets.java | 164 ++- .../java/com/google/cloudbuild/v1/Source.java | 175 ++-- .../cloudbuild/v1/SourceProvenance.java | 197 ++-- .../google/cloudbuild/v1/StorageSource.java | 136 ++- .../cloudbuild/v1/StorageSourceManifest.java | 136 ++- .../com/google/cloudbuild/v1/TimeSpan.java | 141 +-- .../v1/UpdateBuildTriggerRequest.java | 148 ++- .../v1/UpdateWorkerPoolOperationMetadata.java | 155 ++- .../v1/UpdateWorkerPoolRequest.java | 153 ++- .../java/com/google/cloudbuild/v1/Volume.java | 125 +-- .../google/cloudbuild/v1/WebhookConfig.java | 126 +-- .../com/google/cloudbuild/v1/WorkerPool.java | 280 ++---- 57 files changed, 4177 insertions(+), 6347 deletions(-) diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ApprovalConfig.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ApprovalConfig.java index c22a2f48..e5e49a93 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ApprovalConfig.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ApprovalConfig.java @@ -50,50 +50,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private ApprovalConfig( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 8: - { - approvalRequired_ = input.readBool(); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_ApprovalConfig_descriptor; @@ -146,7 +102,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (approvalRequired_ != false) { output.writeBool(1, approvalRequired_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -158,7 +114,7 @@ public int getSerializedSize() { if (approvalRequired_ != false) { size += com.google.protobuf.CodedOutputStream.computeBoolSize(1, approvalRequired_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -174,7 +130,7 @@ public boolean equals(final java.lang.Object obj) { com.google.cloudbuild.v1.ApprovalConfig other = (com.google.cloudbuild.v1.ApprovalConfig) obj; if (getApprovalRequired() != other.getApprovalRequired()) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -187,7 +143,7 @@ public int hashCode() { hash = (19 * hash) + getDescriptor().hashCode(); hash = (37 * hash) + APPROVAL_REQUIRED_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getApprovalRequired()); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -316,17 +272,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.ApprovalConfig.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -414,7 +363,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.ApprovalConfig other) { if (other.getApprovalRequired() != false) { setApprovalRequired(other.getApprovalRequired()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -429,17 +378,37 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.ApprovalConfig parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + approvalRequired_ = input.readBool(); + + break; + } // case 8 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.cloudbuild.v1.ApprovalConfig) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -533,7 +502,18 @@ public ApprovalConfig parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new ApprovalConfig(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ApprovalResult.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ApprovalResult.java index a3eeb06a..a8789904 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ApprovalResult.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ApprovalResult.java @@ -56,88 +56,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private ApprovalResult( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - approverAccount_ = s; - break; - } - case 26: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (approvalTime_ != null) { - subBuilder = approvalTime_.toBuilder(); - } - approvalTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(approvalTime_); - approvalTime_ = subBuilder.buildPartial(); - } - - break; - } - case 32: - { - int rawValue = input.readEnum(); - - decision_ = rawValue; - break; - } - case 42: - { - java.lang.String s = input.readStringRequireUtf8(); - - comment_ = s; - break; - } - case 50: - { - java.lang.String s = input.readStringRequireUtf8(); - - url_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_ApprovalResult_descriptor; @@ -590,7 +508,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(url_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 6, url_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -615,7 +533,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(url_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(6, url_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -638,7 +556,7 @@ public boolean equals(final java.lang.Object obj) { if (decision_ != other.decision_) return false; if (!getComment().equals(other.getComment())) return false; if (!getUrl().equals(other.getUrl())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -661,7 +579,7 @@ public int hashCode() { hash = (53 * hash) + getComment().hashCode(); hash = (37 * hash) + URL_FIELD_NUMBER; hash = (53 * hash) + getUrl().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -791,17 +709,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.ApprovalResult.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -924,7 +835,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.ApprovalResult other) { url_ = other.url_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -939,17 +850,61 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.ApprovalResult parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 18: + { + approverAccount_ = input.readStringRequireUtf8(); + + break; + } // case 18 + case 26: + { + input.readMessage(getApprovalTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 26 + case 32: + { + decision_ = input.readEnum(); + + break; + } // case 32 + case 42: + { + comment_ = input.readStringRequireUtf8(); + + break; + } // case 42 + case 50: + { + url_ = input.readStringRequireUtf8(); + + break; + } // case 50 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.cloudbuild.v1.ApprovalResult) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1629,7 +1584,18 @@ public ApprovalResult parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new ApprovalResult(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ApproveBuildRequest.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ApproveBuildRequest.java index 61518f1a..1bca640e 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ApproveBuildRequest.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ApproveBuildRequest.java @@ -52,68 +52,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private ApproveBuildRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - case 18: - { - com.google.cloudbuild.v1.ApprovalResult.Builder subBuilder = null; - if (approvalResult_ != null) { - subBuilder = approvalResult_.toBuilder(); - } - approvalResult_ = - input.readMessage( - com.google.cloudbuild.v1.ApprovalResult.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(approvalResult_); - approvalResult_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_ApproveBuildRequest_descriptor; @@ -248,7 +186,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (approvalResult_ != null) { output.writeMessage(2, getApprovalResult()); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -263,7 +201,7 @@ public int getSerializedSize() { if (approvalResult_ != null) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getApprovalResult()); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -284,7 +222,7 @@ public boolean equals(final java.lang.Object obj) { if (hasApprovalResult()) { if (!getApprovalResult().equals(other.getApprovalResult())) return false; } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -301,7 +239,7 @@ public int hashCode() { hash = (37 * hash) + APPROVAL_RESULT_FIELD_NUMBER; hash = (53 * hash) + getApprovalResult().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -430,17 +368,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.ApproveBuildRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -543,7 +474,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.ApproveBuildRequest other) { if (other.hasApprovalResult()) { mergeApprovalResult(other.getApprovalResult()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -558,17 +489,43 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.ApproveBuildRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + input.readMessage(getApprovalResultFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.cloudbuild.v1.ApproveBuildRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -901,7 +858,18 @@ public ApproveBuildRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new ApproveBuildRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ArtifactResult.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ArtifactResult.java index 28af7219..09cfdf56 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ArtifactResult.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ArtifactResult.java @@ -54,67 +54,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private ArtifactResult( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - location_ = s; - break; - } - case 18: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - fileHash_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - fileHash_.add( - input.readMessage( - com.google.cloudbuild.v1.FileHashes.parser(), extensionRegistry)); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - if (((mutable_bitField0_ & 0x00000001) != 0)) { - fileHash_ = java.util.Collections.unmodifiableList(fileHash_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_ArtifactResult_descriptor; @@ -272,7 +211,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io for (int i = 0; i < fileHash_.size(); i++) { output.writeMessage(2, fileHash_.get(i)); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -287,7 +226,7 @@ public int getSerializedSize() { for (int i = 0; i < fileHash_.size(); i++) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, fileHash_.get(i)); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -304,7 +243,7 @@ public boolean equals(final java.lang.Object obj) { if (!getLocation().equals(other.getLocation())) return false; if (!getFileHashList().equals(other.getFileHashList())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -321,7 +260,7 @@ public int hashCode() { hash = (37 * hash) + FILE_HASH_FIELD_NUMBER; hash = (53 * hash) + getFileHashList().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -451,19 +390,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.ArtifactResult.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getFileHashFieldBuilder(); - } } @java.lang.Override @@ -473,10 +403,11 @@ public Builder clear() { if (fileHashBuilder_ == null) { fileHash_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); } else { + fileHash_ = null; fileHashBuilder_.clear(); } + bitField0_ = (bitField0_ & ~0x00000001); return this; } @@ -595,7 +526,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.ArtifactResult other) { } } } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -610,17 +541,50 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.ArtifactResult parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + location_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + com.google.cloudbuild.v1.FileHashes m = + input.readMessage( + com.google.cloudbuild.v1.FileHashes.parser(), extensionRegistry); + if (fileHashBuilder_ == null) { + ensureFileHashIsMutable(); + fileHash_.add(m); + } else { + fileHashBuilder_.addMessage(m); + } + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.cloudbuild.v1.ArtifactResult) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1122,7 +1086,18 @@ public ArtifactResult parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new ArtifactResult(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Artifacts.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Artifacts.java index f7017179..3e83f049 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Artifacts.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Artifacts.java @@ -53,76 +53,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private Artifacts( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - images_ = new com.google.protobuf.LazyStringArrayList(); - mutable_bitField0_ |= 0x00000001; - } - images_.add(s); - break; - } - case 18: - { - com.google.cloudbuild.v1.Artifacts.ArtifactObjects.Builder subBuilder = null; - if (objects_ != null) { - subBuilder = objects_.toBuilder(); - } - objects_ = - input.readMessage( - com.google.cloudbuild.v1.Artifacts.ArtifactObjects.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(objects_); - objects_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - if (((mutable_bitField0_ & 0x00000001) != 0)) { - images_ = images_.getUnmodifiableView(); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_Artifacts_descriptor; @@ -304,82 +234,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private ArtifactObjects( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - location_ = s; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - paths_ = new com.google.protobuf.LazyStringArrayList(); - mutable_bitField0_ |= 0x00000001; - } - paths_.add(s); - break; - } - case 26: - { - com.google.cloudbuild.v1.TimeSpan.Builder subBuilder = null; - if (timing_ != null) { - subBuilder = timing_.toBuilder(); - } - timing_ = - input.readMessage( - com.google.cloudbuild.v1.TimeSpan.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(timing_); - timing_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - if (((mutable_bitField0_ & 0x00000001) != 0)) { - paths_ = paths_.getUnmodifiableView(); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_Artifacts_ArtifactObjects_descriptor; @@ -588,7 +442,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (timing_ != null) { output.writeMessage(3, getTiming()); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -611,7 +465,7 @@ public int getSerializedSize() { if (timing_ != null) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getTiming()); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -633,7 +487,7 @@ public boolean equals(final java.lang.Object obj) { if (hasTiming()) { if (!getTiming().equals(other.getTiming())) return false; } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -654,7 +508,7 @@ public int hashCode() { hash = (37 * hash) + TIMING_FIELD_NUMBER; hash = (53 * hash) + getTiming().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -786,17 +640,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.Artifacts.ArtifactObjects.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -920,7 +767,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.Artifacts.ArtifactObjects othe if (other.hasTiming()) { mergeTiming(other.getTiming()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -935,18 +782,50 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.Artifacts.ArtifactObjects parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + location_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + java.lang.String s = input.readStringRequireUtf8(); + ensurePathsIsMutable(); + paths_.add(s); + break; + } // case 18 + case 26: + { + input.readMessage(getTimingFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloudbuild.v1.Artifacts.ArtifactObjects) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1478,7 +1357,19 @@ public ArtifactObjects parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new ArtifactObjects(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException() + .setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; @@ -1667,7 +1558,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (objects_ != null) { output.writeMessage(2, getObjects()); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -1687,7 +1578,7 @@ public int getSerializedSize() { if (objects_ != null) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getObjects()); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -1707,7 +1598,7 @@ public boolean equals(final java.lang.Object obj) { if (hasObjects()) { if (!getObjects().equals(other.getObjects())) return false; } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -1726,7 +1617,7 @@ public int hashCode() { hash = (37 * hash) + OBJECTS_FIELD_NUMBER; hash = (53 * hash) + getObjects().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -1855,17 +1746,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.Artifacts.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -1978,7 +1862,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.Artifacts other) { if (other.hasObjects()) { mergeObjects(other.getObjects()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -1993,17 +1877,44 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.Artifacts parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureImagesIsMutable(); + images_.add(s); + break; + } // case 10 + case 18: + { + input.readMessage(getObjectsFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.cloudbuild.v1.Artifacts) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -2503,7 +2414,18 @@ public Artifacts parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new Artifacts(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Build.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Build.java index df735995..9a9f98f7 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Build.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Build.java @@ -79,407 +79,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private Build( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - id_ = s; - break; - } - case 16: - { - int rawValue = input.readEnum(); - - status_ = rawValue; - break; - } - case 26: - { - com.google.cloudbuild.v1.Source.Builder subBuilder = null; - if (source_ != null) { - subBuilder = source_.toBuilder(); - } - source_ = - input.readMessage(com.google.cloudbuild.v1.Source.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(source_); - source_ = subBuilder.buildPartial(); - } - - break; - } - case 50: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (createTime_ != null) { - subBuilder = createTime_.toBuilder(); - } - createTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(createTime_); - createTime_ = subBuilder.buildPartial(); - } - - break; - } - case 58: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (startTime_ != null) { - subBuilder = startTime_.toBuilder(); - } - startTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(startTime_); - startTime_ = subBuilder.buildPartial(); - } - - break; - } - case 66: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (finishTime_ != null) { - subBuilder = finishTime_.toBuilder(); - } - finishTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(finishTime_); - finishTime_ = subBuilder.buildPartial(); - } - - break; - } - case 82: - { - com.google.cloudbuild.v1.Results.Builder subBuilder = null; - if (results_ != null) { - subBuilder = results_.toBuilder(); - } - results_ = - input.readMessage(com.google.cloudbuild.v1.Results.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(results_); - results_ = subBuilder.buildPartial(); - } - - break; - } - case 90: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - steps_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - steps_.add( - input.readMessage( - com.google.cloudbuild.v1.BuildStep.parser(), extensionRegistry)); - break; - } - case 98: - { - com.google.protobuf.Duration.Builder subBuilder = null; - if (timeout_ != null) { - subBuilder = timeout_.toBuilder(); - } - timeout_ = - input.readMessage(com.google.protobuf.Duration.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(timeout_); - timeout_ = subBuilder.buildPartial(); - } - - break; - } - case 106: - { - java.lang.String s = input.readStringRequireUtf8(); - if (!((mutable_bitField0_ & 0x00000002) != 0)) { - images_ = new com.google.protobuf.LazyStringArrayList(); - mutable_bitField0_ |= 0x00000002; - } - images_.add(s); - break; - } - case 130: - { - java.lang.String s = input.readStringRequireUtf8(); - - projectId_ = s; - break; - } - case 154: - { - java.lang.String s = input.readStringRequireUtf8(); - - logsBucket_ = s; - break; - } - case 170: - { - com.google.cloudbuild.v1.SourceProvenance.Builder subBuilder = null; - if (sourceProvenance_ != null) { - subBuilder = sourceProvenance_.toBuilder(); - } - sourceProvenance_ = - input.readMessage( - com.google.cloudbuild.v1.SourceProvenance.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(sourceProvenance_); - sourceProvenance_ = subBuilder.buildPartial(); - } - - break; - } - case 178: - { - java.lang.String s = input.readStringRequireUtf8(); - - buildTriggerId_ = s; - break; - } - case 186: - { - com.google.cloudbuild.v1.BuildOptions.Builder subBuilder = null; - if (options_ != null) { - subBuilder = options_.toBuilder(); - } - options_ = - input.readMessage( - com.google.cloudbuild.v1.BuildOptions.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(options_); - options_ = subBuilder.buildPartial(); - } - - break; - } - case 194: - { - java.lang.String s = input.readStringRequireUtf8(); - - statusDetail_ = s; - break; - } - case 202: - { - java.lang.String s = input.readStringRequireUtf8(); - - logUrl_ = s; - break; - } - case 234: - { - if (!((mutable_bitField0_ & 0x00000004) != 0)) { - substitutions_ = - com.google.protobuf.MapField.newMapField( - SubstitutionsDefaultEntryHolder.defaultEntry); - mutable_bitField0_ |= 0x00000004; - } - com.google.protobuf.MapEntry substitutions__ = - input.readMessage( - SubstitutionsDefaultEntryHolder.defaultEntry.getParserForType(), - extensionRegistry); - substitutions_ - .getMutableMap() - .put(substitutions__.getKey(), substitutions__.getValue()); - break; - } - case 250: - { - java.lang.String s = input.readStringRequireUtf8(); - if (!((mutable_bitField0_ & 0x00000008) != 0)) { - tags_ = new com.google.protobuf.LazyStringArrayList(); - mutable_bitField0_ |= 0x00000008; - } - tags_.add(s); - break; - } - case 258: - { - if (!((mutable_bitField0_ & 0x00000010) != 0)) { - secrets_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000010; - } - secrets_.add( - input.readMessage(com.google.cloudbuild.v1.Secret.parser(), extensionRegistry)); - break; - } - case 266: - { - if (!((mutable_bitField0_ & 0x00000020) != 0)) { - timing_ = - com.google.protobuf.MapField.newMapField(TimingDefaultEntryHolder.defaultEntry); - mutable_bitField0_ |= 0x00000020; - } - com.google.protobuf.MapEntry - timing__ = - input.readMessage( - TimingDefaultEntryHolder.defaultEntry.getParserForType(), - extensionRegistry); - timing_.getMutableMap().put(timing__.getKey(), timing__.getValue()); - break; - } - case 298: - { - com.google.cloudbuild.v1.Artifacts.Builder subBuilder = null; - if (artifacts_ != null) { - subBuilder = artifacts_.toBuilder(); - } - artifacts_ = - input.readMessage(com.google.cloudbuild.v1.Artifacts.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(artifacts_); - artifacts_ = subBuilder.buildPartial(); - } - - break; - } - case 322: - { - com.google.protobuf.Duration.Builder subBuilder = null; - if (queueTtl_ != null) { - subBuilder = queueTtl_.toBuilder(); - } - queueTtl_ = - input.readMessage(com.google.protobuf.Duration.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(queueTtl_); - queueTtl_ = subBuilder.buildPartial(); - } - - break; - } - case 338: - { - java.lang.String s = input.readStringRequireUtf8(); - - serviceAccount_ = s; - break; - } - case 354: - { - com.google.cloudbuild.v1.BuildApproval.Builder subBuilder = null; - if (approval_ != null) { - subBuilder = approval_.toBuilder(); - } - approval_ = - input.readMessage( - com.google.cloudbuild.v1.BuildApproval.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(approval_); - approval_ = subBuilder.buildPartial(); - } - - break; - } - case 362: - { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - case 378: - { - com.google.cloudbuild.v1.Secrets.Builder subBuilder = null; - if (availableSecrets_ != null) { - subBuilder = availableSecrets_.toBuilder(); - } - availableSecrets_ = - input.readMessage(com.google.cloudbuild.v1.Secrets.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(availableSecrets_); - availableSecrets_ = subBuilder.buildPartial(); - } - - break; - } - case 394: - { - if (!((mutable_bitField0_ & 0x00000040) != 0)) { - warnings_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000040; - } - warnings_.add( - input.readMessage( - com.google.cloudbuild.v1.Build.Warning.parser(), extensionRegistry)); - break; - } - case 410: - { - com.google.cloudbuild.v1.Build.FailureInfo.Builder subBuilder = null; - if (failureInfo_ != null) { - subBuilder = failureInfo_.toBuilder(); - } - failureInfo_ = - input.readMessage( - com.google.cloudbuild.v1.Build.FailureInfo.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(failureInfo_); - failureInfo_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - if (((mutable_bitField0_ & 0x00000001) != 0)) { - steps_ = java.util.Collections.unmodifiableList(steps_); - } - if (((mutable_bitField0_ & 0x00000002) != 0)) { - images_ = images_.getUnmodifiableView(); - } - if (((mutable_bitField0_ & 0x00000008) != 0)) { - tags_ = tags_.getUnmodifiableView(); - } - if (((mutable_bitField0_ & 0x00000010) != 0)) { - secrets_ = java.util.Collections.unmodifiableList(secrets_); - } - if (((mutable_bitField0_ & 0x00000040) != 0)) { - warnings_ = java.util.Collections.unmodifiableList(warnings_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_Build_descriptor; @@ -910,59 +509,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private Warning( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - text_ = s; - break; - } - case 16: - { - int rawValue = input.readEnum(); - - priority_ = rawValue; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_Build_Warning_descriptor; @@ -1263,7 +809,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io != com.google.cloudbuild.v1.Build.Warning.Priority.PRIORITY_UNSPECIFIED.getNumber()) { output.writeEnum(2, priority_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -1279,7 +825,7 @@ public int getSerializedSize() { != com.google.cloudbuild.v1.Build.Warning.Priority.PRIORITY_UNSPECIFIED.getNumber()) { size += com.google.protobuf.CodedOutputStream.computeEnumSize(2, priority_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -1296,7 +842,7 @@ public boolean equals(final java.lang.Object obj) { if (!getText().equals(other.getText())) return false; if (priority_ != other.priority_) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -1311,7 +857,7 @@ public int hashCode() { hash = (53 * hash) + getText().hashCode(); hash = (37 * hash) + PRIORITY_FIELD_NUMBER; hash = (53 * hash) + priority_; - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -1442,17 +988,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.Build.Warning.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -1549,7 +1088,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.Build.Warning other) { if (other.priority_ != 0) { setPriorityValue(other.getPriorityValue()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -1564,17 +1103,43 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.Build.Warning parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + text_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 16: + { + priority_ = input.readEnum(); + + break; + } // case 16 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.cloudbuild.v1.Build.Warning) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1810,7 +1375,19 @@ public Warning parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new Warning(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException() + .setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; @@ -1919,59 +1496,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private FailureInfo( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 8: - { - int rawValue = input.readEnum(); - - type_ = rawValue; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - detail_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_Build_FailureInfo_descriptor; @@ -2342,7 +1866,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(detail_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 2, detail_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -2359,7 +1883,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(detail_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, detail_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -2377,7 +1901,7 @@ public boolean equals(final java.lang.Object obj) { if (type_ != other.type_) return false; if (!getDetail().equals(other.getDetail())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -2392,7 +1916,7 @@ public int hashCode() { hash = (53 * hash) + type_; hash = (37 * hash) + DETAIL_FIELD_NUMBER; hash = (53 * hash) + getDetail().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -2523,17 +2047,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.Build.FailureInfo.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -2630,7 +2147,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.Build.FailureInfo other) { detail_ = other.detail_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -2645,17 +2162,43 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.Build.FailureInfo parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + type_ = input.readEnum(); + + break; + } // case 8 + case 18: + { + detail_ = input.readStringRequireUtf8(); + + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.cloudbuild.v1.Build.FailureInfo) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -2891,7 +2434,19 @@ public FailureInfo parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new FailureInfo(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException() + .setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; @@ -4760,7 +4315,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (failureInfo_ != null) { output.writeMessage(51, getFailureInfo()); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -4880,7 +4435,7 @@ public int getSerializedSize() { if (failureInfo_ != null) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(51, getFailureInfo()); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -4963,7 +4518,7 @@ public boolean equals(final java.lang.Object obj) { if (hasFailureInfo()) { if (!getFailureInfo().equals(other.getFailureInfo())) return false; } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -5072,7 +4627,7 @@ public int hashCode() { hash = (37 * hash) + FAILURE_INFO_FIELD_NUMBER; hash = (53 * hash) + getFailureInfo().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -5237,21 +4792,10 @@ protected com.google.protobuf.MapField internalGetMutableMapField(int number) { } // Construct using com.google.cloudbuild.v1.Build.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getStepsFieldBuilder(); - getSecretsFieldBuilder(); - getWarningsFieldBuilder(); - } } @java.lang.Override @@ -5275,10 +4819,11 @@ public Builder clear() { } if (stepsBuilder_ == null) { steps_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); } else { + steps_ = null; stepsBuilder_.clear(); } + bitField0_ = (bitField0_ & ~0x00000001); if (resultsBuilder_ == null) { results_ = null; } else { @@ -5346,10 +4891,11 @@ public Builder clear() { bitField0_ = (bitField0_ & ~0x00000008); if (secretsBuilder_ == null) { secrets_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000010); } else { + secrets_ = null; secretsBuilder_.clear(); } + bitField0_ = (bitField0_ & ~0x00000010); internalGetMutableTiming().clear(); if (approvalBuilder_ == null) { approval_ = null; @@ -5367,10 +4913,11 @@ public Builder clear() { } if (warningsBuilder_ == null) { warnings_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000040); } else { + warnings_ = null; warningsBuilder_.clear(); } + bitField0_ = (bitField0_ & ~0x00000040); if (failureInfoBuilder_ == null) { failureInfo_ = null; } else { @@ -5745,7 +5292,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.Build other) { if (other.hasFailureInfo()) { mergeFailureInfo(other.getFailureInfo()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -5760,17 +5307,240 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.Build parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + id_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 16: + { + status_ = input.readEnum(); + + break; + } // case 16 + case 26: + { + input.readMessage(getSourceFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 26 + case 50: + { + input.readMessage(getCreateTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 50 + case 58: + { + input.readMessage(getStartTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 58 + case 66: + { + input.readMessage(getFinishTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 66 + case 82: + { + input.readMessage(getResultsFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 82 + case 90: + { + com.google.cloudbuild.v1.BuildStep m = + input.readMessage( + com.google.cloudbuild.v1.BuildStep.parser(), extensionRegistry); + if (stepsBuilder_ == null) { + ensureStepsIsMutable(); + steps_.add(m); + } else { + stepsBuilder_.addMessage(m); + } + break; + } // case 90 + case 98: + { + input.readMessage(getTimeoutFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 98 + case 106: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureImagesIsMutable(); + images_.add(s); + break; + } // case 106 + case 130: + { + projectId_ = input.readStringRequireUtf8(); + + break; + } // case 130 + case 154: + { + logsBucket_ = input.readStringRequireUtf8(); + + break; + } // case 154 + case 170: + { + input.readMessage( + getSourceProvenanceFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 170 + case 178: + { + buildTriggerId_ = input.readStringRequireUtf8(); + + break; + } // case 178 + case 186: + { + input.readMessage(getOptionsFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 186 + case 194: + { + statusDetail_ = input.readStringRequireUtf8(); + + break; + } // case 194 + case 202: + { + logUrl_ = input.readStringRequireUtf8(); + + break; + } // case 202 + case 234: + { + com.google.protobuf.MapEntry substitutions__ = + input.readMessage( + SubstitutionsDefaultEntryHolder.defaultEntry.getParserForType(), + extensionRegistry); + internalGetMutableSubstitutions() + .getMutableMap() + .put(substitutions__.getKey(), substitutions__.getValue()); + break; + } // case 234 + case 250: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureTagsIsMutable(); + tags_.add(s); + break; + } // case 250 + case 258: + { + com.google.cloudbuild.v1.Secret m = + input.readMessage(com.google.cloudbuild.v1.Secret.parser(), extensionRegistry); + if (secretsBuilder_ == null) { + ensureSecretsIsMutable(); + secrets_.add(m); + } else { + secretsBuilder_.addMessage(m); + } + break; + } // case 258 + case 266: + { + com.google.protobuf.MapEntry + timing__ = + input.readMessage( + TimingDefaultEntryHolder.defaultEntry.getParserForType(), + extensionRegistry); + internalGetMutableTiming() + .getMutableMap() + .put(timing__.getKey(), timing__.getValue()); + break; + } // case 266 + case 298: + { + input.readMessage(getArtifactsFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 298 + case 322: + { + input.readMessage(getQueueTtlFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 322 + case 338: + { + serviceAccount_ = input.readStringRequireUtf8(); + + break; + } // case 338 + case 354: + { + input.readMessage(getApprovalFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 354 + case 362: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 362 + case 378: + { + input.readMessage( + getAvailableSecretsFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 378 + case 394: + { + com.google.cloudbuild.v1.Build.Warning m = + input.readMessage( + com.google.cloudbuild.v1.Build.Warning.parser(), extensionRegistry); + if (warningsBuilder_ == null) { + ensureWarningsIsMutable(); + warnings_.add(m); + } else { + warningsBuilder_.addMessage(m); + } + break; + } // case 394 + case 410: + { + input.readMessage(getFailureInfoFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 410 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.cloudbuild.v1.Build) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -11329,7 +11099,18 @@ public Build parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new Build(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildApproval.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildApproval.java index 064ebaca..b1944729 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildApproval.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildApproval.java @@ -53,84 +53,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private BuildApproval( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 8: - { - int rawValue = input.readEnum(); - - state_ = rawValue; - break; - } - case 18: - { - com.google.cloudbuild.v1.ApprovalConfig.Builder subBuilder = null; - if (config_ != null) { - subBuilder = config_.toBuilder(); - } - config_ = - input.readMessage( - com.google.cloudbuild.v1.ApprovalConfig.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(config_); - config_ = subBuilder.buildPartial(); - } - - break; - } - case 26: - { - com.google.cloudbuild.v1.ApprovalResult.Builder subBuilder = null; - if (result_ != null) { - subBuilder = result_.toBuilder(); - } - result_ = - input.readMessage( - com.google.cloudbuild.v1.ApprovalResult.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(result_); - result_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_BuildApproval_descriptor; @@ -514,7 +436,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (result_ != null) { output.writeMessage(3, getResult()); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -532,7 +454,7 @@ public int getSerializedSize() { if (result_ != null) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getResult()); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -556,7 +478,7 @@ public boolean equals(final java.lang.Object obj) { if (hasResult()) { if (!getResult().equals(other.getResult())) return false; } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -577,7 +499,7 @@ public int hashCode() { hash = (37 * hash) + RESULT_FIELD_NUMBER; hash = (53 * hash) + getResult().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -707,17 +629,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.BuildApproval.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -833,7 +748,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.BuildApproval other) { if (other.hasResult()) { mergeResult(other.getResult()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -848,17 +763,49 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.BuildApproval parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + state_ = input.readEnum(); + + break; + } // case 8 + case 18: + { + input.readMessage(getConfigFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 18 + case 26: + { + input.readMessage(getResultFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.cloudbuild.v1.BuildApproval) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1401,7 +1348,18 @@ public BuildApproval parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new BuildApproval(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildOperationMetadata.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildOperationMetadata.java index 3c8b842f..8b45f99b 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildOperationMetadata.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildOperationMetadata.java @@ -50,60 +50,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private BuildOperationMetadata( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - com.google.cloudbuild.v1.Build.Builder subBuilder = null; - if (build_ != null) { - subBuilder = build_.toBuilder(); - } - build_ = - input.readMessage(com.google.cloudbuild.v1.Build.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(build_); - build_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_BuildOperationMetadata_descriptor; @@ -182,7 +128,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (build_ != null) { output.writeMessage(1, getBuild()); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -194,7 +140,7 @@ public int getSerializedSize() { if (build_ != null) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getBuild()); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -214,7 +160,7 @@ public boolean equals(final java.lang.Object obj) { if (hasBuild()) { if (!getBuild().equals(other.getBuild())) return false; } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -229,7 +175,7 @@ public int hashCode() { hash = (37 * hash) + BUILD_FIELD_NUMBER; hash = (53 * hash) + getBuild().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -358,17 +304,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.BuildOperationMetadata.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -465,7 +404,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.BuildOperationMetadata other) if (other.hasBuild()) { mergeBuild(other.getBuild()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -480,17 +419,37 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.BuildOperationMetadata parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage(getBuildFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.cloudbuild.v1.BuildOperationMetadata) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -705,7 +664,18 @@ public BuildOperationMetadata parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new BuildOperationMetadata(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildOptions.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildOptions.java index 66cfcbbf..9585805a 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildOptions.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildOptions.java @@ -61,181 +61,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private BuildOptions( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 8: - { - int rawValue = input.readEnum(); - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - sourceProvenanceHash_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - sourceProvenanceHash_.add(rawValue); - break; - } - case 10: - { - int length = input.readRawVarint32(); - int oldLimit = input.pushLimit(length); - while (input.getBytesUntilLimit() > 0) { - int rawValue = input.readEnum(); - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - sourceProvenanceHash_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - sourceProvenanceHash_.add(rawValue); - } - input.popLimit(oldLimit); - break; - } - case 16: - { - int rawValue = input.readEnum(); - - requestedVerifyOption_ = rawValue; - break; - } - case 24: - { - int rawValue = input.readEnum(); - - machineType_ = rawValue; - break; - } - case 32: - { - int rawValue = input.readEnum(); - - substitutionOption_ = rawValue; - break; - } - case 40: - { - int rawValue = input.readEnum(); - - logStreamingOption_ = rawValue; - break; - } - case 48: - { - diskSizeGb_ = input.readInt64(); - break; - } - case 58: - { - java.lang.String s = input.readStringRequireUtf8(); - - workerPool_ = s; - break; - } - case 88: - { - int rawValue = input.readEnum(); - - logging_ = rawValue; - break; - } - case 98: - { - java.lang.String s = input.readStringRequireUtf8(); - if (!((mutable_bitField0_ & 0x00000002) != 0)) { - env_ = new com.google.protobuf.LazyStringArrayList(); - mutable_bitField0_ |= 0x00000002; - } - env_.add(s); - break; - } - case 106: - { - java.lang.String s = input.readStringRequireUtf8(); - if (!((mutable_bitField0_ & 0x00000004) != 0)) { - secretEnv_ = new com.google.protobuf.LazyStringArrayList(); - mutable_bitField0_ |= 0x00000004; - } - secretEnv_.add(s); - break; - } - case 114: - { - if (!((mutable_bitField0_ & 0x00000008) != 0)) { - volumes_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000008; - } - volumes_.add( - input.readMessage(com.google.cloudbuild.v1.Volume.parser(), extensionRegistry)); - break; - } - case 136: - { - dynamicSubstitutions_ = input.readBool(); - break; - } - case 154: - { - com.google.cloudbuild.v1.BuildOptions.PoolOption.Builder subBuilder = null; - if (pool_ != null) { - subBuilder = pool_.toBuilder(); - } - pool_ = - input.readMessage( - com.google.cloudbuild.v1.BuildOptions.PoolOption.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(pool_); - pool_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - if (((mutable_bitField0_ & 0x00000001) != 0)) { - sourceProvenanceHash_ = java.util.Collections.unmodifiableList(sourceProvenanceHash_); - } - if (((mutable_bitField0_ & 0x00000002) != 0)) { - env_ = env_.getUnmodifiableView(); - } - if (((mutable_bitField0_ & 0x00000004) != 0)) { - secretEnv_ = secretEnv_.getUnmodifiableView(); - } - if (((mutable_bitField0_ & 0x00000008) != 0)) { - volumes_ = java.util.Collections.unmodifiableList(volumes_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_BuildOptions_descriptor; @@ -1194,52 +1019,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private PoolOption( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_BuildOptions_PoolOption_descriptor; @@ -1327,7 +1106,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -1339,7 +1118,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -1356,7 +1135,7 @@ public boolean equals(final java.lang.Object obj) { (com.google.cloudbuild.v1.BuildOptions.PoolOption) obj; if (!getName().equals(other.getName())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -1369,7 +1148,7 @@ public int hashCode() { hash = (19 * hash) + getDescriptor().hashCode(); hash = (37 * hash) + NAME_FIELD_NUMBER; hash = (53 * hash) + getName().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -1503,17 +1282,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.BuildOptions.PoolOption.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -1605,7 +1377,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.BuildOptions.PoolOption other) name_ = other.name_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -1620,18 +1392,37 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.BuildOptions.PoolOption parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloudbuild.v1.BuildOptions.PoolOption) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1789,7 +1580,19 @@ public PoolOption parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new PoolOption(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException() + .setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; @@ -2579,7 +2382,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (pool_ != null) { output.writeMessage(19, getPool()); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -2652,7 +2455,7 @@ public int getSerializedSize() { if (pool_ != null) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(19, getPool()); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -2683,7 +2486,7 @@ public boolean equals(final java.lang.Object obj) { if (!getEnvList().equals(other.getEnvList())) return false; if (!getSecretEnvList().equals(other.getSecretEnvList())) return false; if (!getVolumesList().equals(other.getVolumesList())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -2730,7 +2533,7 @@ public int hashCode() { hash = (37 * hash) + VOLUMES_FIELD_NUMBER; hash = (53 * hash) + getVolumesList().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -2858,19 +2661,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.BuildOptions.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getVolumesFieldBuilder(); - } } @java.lang.Override @@ -2906,10 +2700,11 @@ public Builder clear() { bitField0_ = (bitField0_ & ~0x00000004); if (volumesBuilder_ == null) { volumes_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000008); } else { + volumes_ = null; volumesBuilder_.clear(); } + bitField0_ = (bitField0_ & ~0x00000008); return this; } @@ -3109,7 +2904,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.BuildOptions other) { } } } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -3124,17 +2919,130 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.BuildOptions parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + int tmpRaw = input.readEnum(); + ensureSourceProvenanceHashIsMutable(); + sourceProvenanceHash_.add(tmpRaw); + break; + } // case 8 + case 10: + { + int length = input.readRawVarint32(); + int oldLimit = input.pushLimit(length); + while (input.getBytesUntilLimit() > 0) { + int tmpRaw = input.readEnum(); + ensureSourceProvenanceHashIsMutable(); + sourceProvenanceHash_.add(tmpRaw); + } + input.popLimit(oldLimit); + break; + } // case 10 + case 16: + { + requestedVerifyOption_ = input.readEnum(); + + break; + } // case 16 + case 24: + { + machineType_ = input.readEnum(); + + break; + } // case 24 + case 32: + { + substitutionOption_ = input.readEnum(); + + break; + } // case 32 + case 40: + { + logStreamingOption_ = input.readEnum(); + + break; + } // case 40 + case 48: + { + diskSizeGb_ = input.readInt64(); + + break; + } // case 48 + case 58: + { + workerPool_ = input.readStringRequireUtf8(); + + break; + } // case 58 + case 88: + { + logging_ = input.readEnum(); + + break; + } // case 88 + case 98: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureEnvIsMutable(); + env_.add(s); + break; + } // case 98 + case 106: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureSecretEnvIsMutable(); + secretEnv_.add(s); + break; + } // case 106 + case 114: + { + com.google.cloudbuild.v1.Volume m = + input.readMessage(com.google.cloudbuild.v1.Volume.parser(), extensionRegistry); + if (volumesBuilder_ == null) { + ensureVolumesIsMutable(); + volumes_.add(m); + } else { + volumesBuilder_.addMessage(m); + } + break; + } // case 114 + case 136: + { + dynamicSubstitutions_ = input.readBool(); + + break; + } // case 136 + case 154: + { + input.readMessage(getPoolFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 154 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.cloudbuild.v1.BuildOptions) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -5252,7 +5160,18 @@ public BuildOptions parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new BuildOptions(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildStep.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildStep.java index 0af9ad5d..caaaa505 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildStep.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildStep.java @@ -62,198 +62,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private BuildStep( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - env_ = new com.google.protobuf.LazyStringArrayList(); - mutable_bitField0_ |= 0x00000001; - } - env_.add(s); - break; - } - case 26: - { - java.lang.String s = input.readStringRequireUtf8(); - if (!((mutable_bitField0_ & 0x00000002) != 0)) { - args_ = new com.google.protobuf.LazyStringArrayList(); - mutable_bitField0_ |= 0x00000002; - } - args_.add(s); - break; - } - case 34: - { - java.lang.String s = input.readStringRequireUtf8(); - - dir_ = s; - break; - } - case 42: - { - java.lang.String s = input.readStringRequireUtf8(); - - id_ = s; - break; - } - case 50: - { - java.lang.String s = input.readStringRequireUtf8(); - if (!((mutable_bitField0_ & 0x00000004) != 0)) { - waitFor_ = new com.google.protobuf.LazyStringArrayList(); - mutable_bitField0_ |= 0x00000004; - } - waitFor_.add(s); - break; - } - case 58: - { - java.lang.String s = input.readStringRequireUtf8(); - - entrypoint_ = s; - break; - } - case 66: - { - java.lang.String s = input.readStringRequireUtf8(); - if (!((mutable_bitField0_ & 0x00000008) != 0)) { - secretEnv_ = new com.google.protobuf.LazyStringArrayList(); - mutable_bitField0_ |= 0x00000008; - } - secretEnv_.add(s); - break; - } - case 74: - { - if (!((mutable_bitField0_ & 0x00000010) != 0)) { - volumes_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000010; - } - volumes_.add( - input.readMessage(com.google.cloudbuild.v1.Volume.parser(), extensionRegistry)); - break; - } - case 82: - { - com.google.cloudbuild.v1.TimeSpan.Builder subBuilder = null; - if (timing_ != null) { - subBuilder = timing_.toBuilder(); - } - timing_ = - input.readMessage(com.google.cloudbuild.v1.TimeSpan.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(timing_); - timing_ = subBuilder.buildPartial(); - } - - break; - } - case 90: - { - com.google.protobuf.Duration.Builder subBuilder = null; - if (timeout_ != null) { - subBuilder = timeout_.toBuilder(); - } - timeout_ = - input.readMessage(com.google.protobuf.Duration.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(timeout_); - timeout_ = subBuilder.buildPartial(); - } - - break; - } - case 96: - { - int rawValue = input.readEnum(); - - status_ = rawValue; - break; - } - case 106: - { - com.google.cloudbuild.v1.TimeSpan.Builder subBuilder = null; - if (pullTiming_ != null) { - subBuilder = pullTiming_.toBuilder(); - } - pullTiming_ = - input.readMessage(com.google.cloudbuild.v1.TimeSpan.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(pullTiming_); - pullTiming_ = subBuilder.buildPartial(); - } - - break; - } - case 154: - { - java.lang.String s = input.readStringRequireUtf8(); - - script_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - if (((mutable_bitField0_ & 0x00000001) != 0)) { - env_ = env_.getUnmodifiableView(); - } - if (((mutable_bitField0_ & 0x00000002) != 0)) { - args_ = args_.getUnmodifiableView(); - } - if (((mutable_bitField0_ & 0x00000004) != 0)) { - waitFor_ = waitFor_.getUnmodifiableView(); - } - if (((mutable_bitField0_ & 0x00000008) != 0)) { - secretEnv_ = secretEnv_.getUnmodifiableView(); - } - if (((mutable_bitField0_ & 0x00000010) != 0)) { - volumes_ = java.util.Collections.unmodifiableList(volumes_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_BuildStep_descriptor; @@ -1207,7 +1015,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(script_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 19, script_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -1278,7 +1086,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(script_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(19, script_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -1316,7 +1124,7 @@ public boolean equals(final java.lang.Object obj) { } if (status_ != other.status_) return false; if (!getScript().equals(other.getScript())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -1371,7 +1179,7 @@ public int hashCode() { hash = (53 * hash) + status_; hash = (37 * hash) + SCRIPT_FIELD_NUMBER; hash = (53 * hash) + getScript().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -1499,19 +1307,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.BuildStep.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getVolumesFieldBuilder(); - } } @java.lang.Override @@ -1535,10 +1334,11 @@ public Builder clear() { bitField0_ = (bitField0_ & ~0x00000008); if (volumesBuilder_ == null) { volumes_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000010); } else { + volumes_ = null; volumesBuilder_.clear(); } + bitField0_ = (bitField0_ & ~0x00000010); if (timingBuilder_ == null) { timing_ = null; } else { @@ -1786,7 +1586,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.BuildStep other) { script_ = other.script_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -1801,17 +1601,125 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.BuildStep parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureEnvIsMutable(); + env_.add(s); + break; + } // case 18 + case 26: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureArgsIsMutable(); + args_.add(s); + break; + } // case 26 + case 34: + { + dir_ = input.readStringRequireUtf8(); + + break; + } // case 34 + case 42: + { + id_ = input.readStringRequireUtf8(); + + break; + } // case 42 + case 50: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureWaitForIsMutable(); + waitFor_.add(s); + break; + } // case 50 + case 58: + { + entrypoint_ = input.readStringRequireUtf8(); + + break; + } // case 58 + case 66: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureSecretEnvIsMutable(); + secretEnv_.add(s); + break; + } // case 66 + case 74: + { + com.google.cloudbuild.v1.Volume m = + input.readMessage(com.google.cloudbuild.v1.Volume.parser(), extensionRegistry); + if (volumesBuilder_ == null) { + ensureVolumesIsMutable(); + volumes_.add(m); + } else { + volumesBuilder_.addMessage(m); + } + break; + } // case 74 + case 82: + { + input.readMessage(getTimingFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 82 + case 90: + { + input.readMessage(getTimeoutFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 90 + case 96: + { + status_ = input.readEnum(); + + break; + } // case 96 + case 106: + { + input.readMessage(getPullTimingFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 106 + case 154: + { + script_ = input.readStringRequireUtf8(); + + break; + } // case 154 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.cloudbuild.v1.BuildStep) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -4426,7 +4334,18 @@ public BuildStep parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new BuildStep(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildTrigger.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildTrigger.java index fd08e901..114dc76a 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildTrigger.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildTrigger.java @@ -61,256 +61,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private BuildTrigger( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - id_ = s; - break; - } - case 34: - { - com.google.cloudbuild.v1.Build.Builder subBuilder = null; - if (buildTemplateCase_ == 4) { - subBuilder = ((com.google.cloudbuild.v1.Build) buildTemplate_).toBuilder(); - } - buildTemplate_ = - input.readMessage(com.google.cloudbuild.v1.Build.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.cloudbuild.v1.Build) buildTemplate_); - buildTemplate_ = subBuilder.buildPartial(); - } - buildTemplateCase_ = 4; - break; - } - case 42: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (createTime_ != null) { - subBuilder = createTime_.toBuilder(); - } - createTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(createTime_); - createTime_ = subBuilder.buildPartial(); - } - - break; - } - case 58: - { - com.google.cloudbuild.v1.RepoSource.Builder subBuilder = null; - if (triggerTemplate_ != null) { - subBuilder = triggerTemplate_.toBuilder(); - } - triggerTemplate_ = - input.readMessage( - com.google.cloudbuild.v1.RepoSource.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(triggerTemplate_); - triggerTemplate_ = subBuilder.buildPartial(); - } - - break; - } - case 66: - { - java.lang.String s = input.readStringRequireUtf8(); - buildTemplateCase_ = 8; - buildTemplate_ = s; - break; - } - case 72: - { - disabled_ = input.readBool(); - break; - } - case 82: - { - java.lang.String s = input.readStringRequireUtf8(); - - description_ = s; - break; - } - case 90: - { - if (!((mutable_bitField0_ & 0x00000002) != 0)) { - substitutions_ = - com.google.protobuf.MapField.newMapField( - SubstitutionsDefaultEntryHolder.defaultEntry); - mutable_bitField0_ |= 0x00000002; - } - com.google.protobuf.MapEntry substitutions__ = - input.readMessage( - SubstitutionsDefaultEntryHolder.defaultEntry.getParserForType(), - extensionRegistry); - substitutions_ - .getMutableMap() - .put(substitutions__.getKey(), substitutions__.getValue()); - break; - } - case 106: - { - com.google.cloudbuild.v1.GitHubEventsConfig.Builder subBuilder = null; - if (github_ != null) { - subBuilder = github_.toBuilder(); - } - github_ = - input.readMessage( - com.google.cloudbuild.v1.GitHubEventsConfig.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(github_); - github_ = subBuilder.buildPartial(); - } - - break; - } - case 122: - { - java.lang.String s = input.readStringRequireUtf8(); - if (!((mutable_bitField0_ & 0x00000004) != 0)) { - ignoredFiles_ = new com.google.protobuf.LazyStringArrayList(); - mutable_bitField0_ |= 0x00000004; - } - ignoredFiles_.add(s); - break; - } - case 130: - { - java.lang.String s = input.readStringRequireUtf8(); - if (!((mutable_bitField0_ & 0x00000008) != 0)) { - includedFiles_ = new com.google.protobuf.LazyStringArrayList(); - mutable_bitField0_ |= 0x00000008; - } - includedFiles_.add(s); - break; - } - case 144: - { - buildTemplate_ = input.readBool(); - buildTemplateCase_ = 18; - break; - } - case 154: - { - java.lang.String s = input.readStringRequireUtf8(); - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - tags_ = new com.google.protobuf.LazyStringArrayList(); - mutable_bitField0_ |= 0x00000001; - } - tags_.add(s); - break; - } - case 170: - { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - case 234: - { - com.google.cloudbuild.v1.PubsubConfig.Builder subBuilder = null; - if (pubsubConfig_ != null) { - subBuilder = pubsubConfig_.toBuilder(); - } - pubsubConfig_ = - input.readMessage( - com.google.cloudbuild.v1.PubsubConfig.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(pubsubConfig_); - pubsubConfig_ = subBuilder.buildPartial(); - } - - break; - } - case 242: - { - java.lang.String s = input.readStringRequireUtf8(); - - filter_ = s; - break; - } - case 250: - { - com.google.cloudbuild.v1.WebhookConfig.Builder subBuilder = null; - if (webhookConfig_ != null) { - subBuilder = webhookConfig_.toBuilder(); - } - webhookConfig_ = - input.readMessage( - com.google.cloudbuild.v1.WebhookConfig.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(webhookConfig_); - webhookConfig_ = subBuilder.buildPartial(); - } - - break; - } - case 266: - { - java.lang.String s = input.readStringRequireUtf8(); - - serviceAccount_ = s; - break; - } - case 274: - { - java.lang.String s = input.readStringRequireUtf8(); - - resourceName_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - if (((mutable_bitField0_ & 0x00000004) != 0)) { - ignoredFiles_ = ignoredFiles_.getUnmodifiableView(); - } - if (((mutable_bitField0_ & 0x00000008) != 0)) { - includedFiles_ = includedFiles_.getUnmodifiableView(); - } - if (((mutable_bitField0_ & 0x00000001) != 0)) { - tags_ = tags_.getUnmodifiableView(); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_BuildTrigger_descriptor; @@ -1561,7 +1311,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(resourceName_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 34, resourceName_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -1653,7 +1403,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(resourceName_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(34, resourceName_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -1713,7 +1463,7 @@ public boolean equals(final java.lang.Object obj) { case 0: default: } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -1790,7 +1540,7 @@ public int hashCode() { case 0: default: } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -1939,17 +1689,10 @@ protected com.google.protobuf.MapField internalGetMutableMapField(int number) { } // Construct using com.google.cloudbuild.v1.BuildTrigger.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -1989,6 +1732,9 @@ public Builder clear() { webhookConfig_ = null; webhookConfigBuilder_ = null; } + if (buildBuilder_ != null) { + buildBuilder_.clear(); + } if (createTimeBuilder_ == null) { createTime_ = null; } else { @@ -2244,7 +1990,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.BuildTrigger other) { break; } } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -2259,17 +2005,154 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.BuildTrigger parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + id_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 34: + { + input.readMessage(getBuildFieldBuilder().getBuilder(), extensionRegistry); + buildTemplateCase_ = 4; + break; + } // case 34 + case 42: + { + input.readMessage(getCreateTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 42 + case 58: + { + input.readMessage(getTriggerTemplateFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 58 + case 66: + { + java.lang.String s = input.readStringRequireUtf8(); + buildTemplateCase_ = 8; + buildTemplate_ = s; + break; + } // case 66 + case 72: + { + disabled_ = input.readBool(); + + break; + } // case 72 + case 82: + { + description_ = input.readStringRequireUtf8(); + + break; + } // case 82 + case 90: + { + com.google.protobuf.MapEntry substitutions__ = + input.readMessage( + SubstitutionsDefaultEntryHolder.defaultEntry.getParserForType(), + extensionRegistry); + internalGetMutableSubstitutions() + .getMutableMap() + .put(substitutions__.getKey(), substitutions__.getValue()); + break; + } // case 90 + case 106: + { + input.readMessage(getGithubFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 106 + case 122: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureIgnoredFilesIsMutable(); + ignoredFiles_.add(s); + break; + } // case 122 + case 130: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureIncludedFilesIsMutable(); + includedFiles_.add(s); + break; + } // case 130 + case 144: + { + buildTemplate_ = input.readBool(); + buildTemplateCase_ = 18; + break; + } // case 144 + case 154: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureTagsIsMutable(); + tags_.add(s); + break; + } // case 154 + case 170: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 170 + case 234: + { + input.readMessage(getPubsubConfigFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 234 + case 242: + { + filter_ = input.readStringRequireUtf8(); + + break; + } // case 242 + case 250: + { + input.readMessage(getWebhookConfigFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 250 + case 266: + { + serviceAccount_ = input.readStringRequireUtf8(); + + break; + } // case 266 + case 274: + { + resourceName_ = input.readStringRequireUtf8(); + + break; + } // case 274 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.cloudbuild.v1.BuildTrigger) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -5293,7 +5176,18 @@ public BuildTrigger parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new BuildTrigger(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuiltImage.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuiltImage.java index ae326f68..e1c862ff 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuiltImage.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuiltImage.java @@ -53,74 +53,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private BuiltImage( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - case 26: - { - java.lang.String s = input.readStringRequireUtf8(); - - digest_ = s; - break; - } - case 34: - { - com.google.cloudbuild.v1.TimeSpan.Builder subBuilder = null; - if (pushTiming_ != null) { - subBuilder = pushTiming_.toBuilder(); - } - pushTiming_ = - input.readMessage(com.google.cloudbuild.v1.TimeSpan.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(pushTiming_); - pushTiming_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_BuiltImage_descriptor; @@ -313,7 +245,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (pushTiming_ != null) { output.writeMessage(4, getPushTiming()); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -331,7 +263,7 @@ public int getSerializedSize() { if (pushTiming_ != null) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, getPushTiming()); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -352,7 +284,7 @@ public boolean equals(final java.lang.Object obj) { if (hasPushTiming()) { if (!getPushTiming().equals(other.getPushTiming())) return false; } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -371,7 +303,7 @@ public int hashCode() { hash = (37 * hash) + PUSH_TIMING_FIELD_NUMBER; hash = (53 * hash) + getPushTiming().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -499,17 +431,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.BuiltImage.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -618,7 +543,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.BuiltImage other) { if (other.hasPushTiming()) { mergePushTiming(other.getPushTiming()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -633,17 +558,49 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.BuiltImage parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 26: + { + digest_ = input.readStringRequireUtf8(); + + break; + } // case 26 + case 34: + { + input.readMessage(getPushTimingFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 34 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.cloudbuild.v1.BuiltImage) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1099,7 +1056,18 @@ public BuiltImage parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new BuiltImage(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CancelBuildRequest.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CancelBuildRequest.java index c54166bf..a3fa1cc6 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CancelBuildRequest.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CancelBuildRequest.java @@ -54,66 +54,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private CancelBuildRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - projectId_ = s; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - id_ = s; - break; - } - case 34: - { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_CancelBuildRequest_descriptor; @@ -301,7 +241,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 4, name_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -319,7 +259,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, name_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -338,7 +278,7 @@ public boolean equals(final java.lang.Object obj) { if (!getName().equals(other.getName())) return false; if (!getProjectId().equals(other.getProjectId())) return false; if (!getId().equals(other.getId())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -355,7 +295,7 @@ public int hashCode() { hash = (53 * hash) + getProjectId().hashCode(); hash = (37 * hash) + ID_FIELD_NUMBER; hash = (53 * hash) + getId().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -484,17 +424,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.CancelBuildRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -597,7 +530,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.CancelBuildRequest other) { id_ = other.id_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -612,17 +545,49 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.CancelBuildRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + projectId_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + id_ = input.readStringRequireUtf8(); + + break; + } // case 18 + case 34: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 34 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.cloudbuild.v1.CancelBuildRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -981,7 +946,18 @@ public CancelBuildRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new CancelBuildRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CreateBuildRequest.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CreateBuildRequest.java index a7b36427..931ea670 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CreateBuildRequest.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CreateBuildRequest.java @@ -53,74 +53,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private CreateBuildRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - projectId_ = s; - break; - } - case 18: - { - com.google.cloudbuild.v1.Build.Builder subBuilder = null; - if (build_ != null) { - subBuilder = build_.toBuilder(); - } - build_ = - input.readMessage(com.google.cloudbuild.v1.Build.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(build_); - build_ = subBuilder.buildPartial(); - } - - break; - } - case 34: - { - java.lang.String s = input.readStringRequireUtf8(); - - parent_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_CreateBuildRequest_descriptor; @@ -308,7 +240,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 4, parent_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -326,7 +258,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, parent_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -348,7 +280,7 @@ public boolean equals(final java.lang.Object obj) { if (hasBuild()) { if (!getBuild().equals(other.getBuild())) return false; } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -367,7 +299,7 @@ public int hashCode() { hash = (37 * hash) + BUILD_FIELD_NUMBER; hash = (53 * hash) + getBuild().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -496,17 +428,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.CreateBuildRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -616,7 +541,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.CreateBuildRequest other) { if (other.hasBuild()) { mergeBuild(other.getBuild()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -631,17 +556,49 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.CreateBuildRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + projectId_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + input.readMessage(getBuildFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 18 + case 34: + { + parent_ = input.readStringRequireUtf8(); + + break; + } // case 34 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.cloudbuild.v1.CreateBuildRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1091,7 +1048,18 @@ public CreateBuildRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new CreateBuildRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CreateBuildTriggerRequest.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CreateBuildTriggerRequest.java index 55982878..4eab64ab 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CreateBuildTriggerRequest.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CreateBuildTriggerRequest.java @@ -53,75 +53,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private CreateBuildTriggerRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - projectId_ = s; - break; - } - case 18: - { - com.google.cloudbuild.v1.BuildTrigger.Builder subBuilder = null; - if (trigger_ != null) { - subBuilder = trigger_.toBuilder(); - } - trigger_ = - input.readMessage( - com.google.cloudbuild.v1.BuildTrigger.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(trigger_); - trigger_ = subBuilder.buildPartial(); - } - - break; - } - case 26: - { - java.lang.String s = input.readStringRequireUtf8(); - - parent_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_CreateBuildTriggerRequest_descriptor; @@ -312,7 +243,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 3, parent_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -330,7 +261,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, parent_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -352,7 +283,7 @@ public boolean equals(final java.lang.Object obj) { if (hasTrigger()) { if (!getTrigger().equals(other.getTrigger())) return false; } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -371,7 +302,7 @@ public int hashCode() { hash = (37 * hash) + TRIGGER_FIELD_NUMBER; hash = (53 * hash) + getTrigger().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -500,17 +431,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.CreateBuildTriggerRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -621,7 +545,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.CreateBuildTriggerRequest othe if (other.hasTrigger()) { mergeTrigger(other.getTrigger()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -636,18 +560,49 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.CreateBuildTriggerRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + projectId_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + input.readMessage(getTriggerFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 18 + case 26: + { + parent_ = input.readStringRequireUtf8(); + + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloudbuild.v1.CreateBuildTriggerRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1103,7 +1058,18 @@ public CreateBuildTriggerRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new CreateBuildTriggerRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CreateWorkerPoolOperationMetadata.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CreateWorkerPoolOperationMetadata.java index dd5e5abc..51eb3660 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CreateWorkerPoolOperationMetadata.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CreateWorkerPoolOperationMetadata.java @@ -53,82 +53,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private CreateWorkerPoolOperationMetadata( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - workerPool_ = s; - break; - } - case 18: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (createTime_ != null) { - subBuilder = createTime_.toBuilder(); - } - createTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(createTime_); - createTime_ = subBuilder.buildPartial(); - } - - break; - } - case 26: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (completeTime_ != null) { - subBuilder = completeTime_.toBuilder(); - } - completeTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(completeTime_); - completeTime_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_CreateWorkerPoolOperationMetadata_descriptor; @@ -314,7 +238,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (completeTime_ != null) { output.writeMessage(3, getCompleteTime()); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -332,7 +256,7 @@ public int getSerializedSize() { if (completeTime_ != null) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getCompleteTime()); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -357,7 +281,7 @@ public boolean equals(final java.lang.Object obj) { if (hasCompleteTime()) { if (!getCompleteTime().equals(other.getCompleteTime())) return false; } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -378,7 +302,7 @@ public int hashCode() { hash = (37 * hash) + COMPLETE_TIME_FIELD_NUMBER; hash = (53 * hash) + getCompleteTime().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -508,17 +432,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.CreateWorkerPoolOperationMetadata.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -636,7 +553,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.CreateWorkerPoolOperationMetad if (other.hasCompleteTime()) { mergeCompleteTime(other.getCompleteTime()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -651,18 +568,49 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.CreateWorkerPoolOperationMetadata parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + workerPool_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + input.readMessage(getCreateTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 18 + case 26: + { + input.readMessage(getCompleteTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloudbuild.v1.CreateWorkerPoolOperationMetadata) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1182,7 +1130,18 @@ public CreateWorkerPoolOperationMetadata parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new CreateWorkerPoolOperationMetadata(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CreateWorkerPoolRequest.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CreateWorkerPoolRequest.java index d83d9287..c9f1b35d 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CreateWorkerPoolRequest.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CreateWorkerPoolRequest.java @@ -53,80 +53,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private CreateWorkerPoolRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - parent_ = s; - break; - } - case 18: - { - com.google.cloudbuild.v1.WorkerPool.Builder subBuilder = null; - if (workerPool_ != null) { - subBuilder = workerPool_.toBuilder(); - } - workerPool_ = - input.readMessage( - com.google.cloudbuild.v1.WorkerPool.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(workerPool_); - workerPool_ = subBuilder.buildPartial(); - } - - break; - } - case 26: - { - java.lang.String s = input.readStringRequireUtf8(); - - workerPoolId_ = s; - break; - } - case 32: - { - validateOnly_ = input.readBool(); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_CreateWorkerPoolRequest_descriptor; @@ -355,7 +281,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (validateOnly_ != false) { output.writeBool(4, validateOnly_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -376,7 +302,7 @@ public int getSerializedSize() { if (validateOnly_ != false) { size += com.google.protobuf.CodedOutputStream.computeBoolSize(4, validateOnly_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -399,7 +325,7 @@ public boolean equals(final java.lang.Object obj) { } if (!getWorkerPoolId().equals(other.getWorkerPoolId())) return false; if (getValidateOnly() != other.getValidateOnly()) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -420,7 +346,7 @@ public int hashCode() { hash = (53 * hash) + getWorkerPoolId().hashCode(); hash = (37 * hash) + VALIDATE_ONLY_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getValidateOnly()); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -549,17 +475,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.CreateWorkerPoolRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -676,7 +595,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.CreateWorkerPoolRequest other) if (other.getValidateOnly() != false) { setValidateOnly(other.getValidateOnly()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -691,17 +610,55 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.CreateWorkerPoolRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + parent_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + input.readMessage(getWorkerPoolFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 18 + case 26: + { + workerPoolId_ = input.readStringRequireUtf8(); + + break; + } // case 26 + case 32: + { + validateOnly_ = input.readBool(); + + break; + } // case 32 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.cloudbuild.v1.CreateWorkerPoolRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1247,7 +1204,18 @@ public CreateWorkerPoolRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new CreateWorkerPoolRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/DeleteBuildTriggerRequest.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/DeleteBuildTriggerRequest.java index 84d3d1f4..faa1af31 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/DeleteBuildTriggerRequest.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/DeleteBuildTriggerRequest.java @@ -54,66 +54,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private DeleteBuildTriggerRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - projectId_ = s; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - triggerId_ = s; - break; - } - case 26: - { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_DeleteBuildTriggerRequest_descriptor; @@ -301,7 +241,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 3, name_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -319,7 +259,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, name_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -338,7 +278,7 @@ public boolean equals(final java.lang.Object obj) { if (!getName().equals(other.getName())) return false; if (!getProjectId().equals(other.getProjectId())) return false; if (!getTriggerId().equals(other.getTriggerId())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -355,7 +295,7 @@ public int hashCode() { hash = (53 * hash) + getProjectId().hashCode(); hash = (37 * hash) + TRIGGER_ID_FIELD_NUMBER; hash = (53 * hash) + getTriggerId().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -484,17 +424,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.DeleteBuildTriggerRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -598,7 +531,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.DeleteBuildTriggerRequest othe triggerId_ = other.triggerId_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -613,18 +546,49 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.DeleteBuildTriggerRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + projectId_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + triggerId_ = input.readStringRequireUtf8(); + + break; + } // case 18 + case 26: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloudbuild.v1.DeleteBuildTriggerRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -983,7 +947,18 @@ public DeleteBuildTriggerRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new DeleteBuildTriggerRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/DeleteWorkerPoolOperationMetadata.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/DeleteWorkerPoolOperationMetadata.java index 10a771d6..03e78475 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/DeleteWorkerPoolOperationMetadata.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/DeleteWorkerPoolOperationMetadata.java @@ -53,82 +53,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private DeleteWorkerPoolOperationMetadata( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - workerPool_ = s; - break; - } - case 18: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (createTime_ != null) { - subBuilder = createTime_.toBuilder(); - } - createTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(createTime_); - createTime_ = subBuilder.buildPartial(); - } - - break; - } - case 26: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (completeTime_ != null) { - subBuilder = completeTime_.toBuilder(); - } - completeTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(completeTime_); - completeTime_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_DeleteWorkerPoolOperationMetadata_descriptor; @@ -314,7 +238,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (completeTime_ != null) { output.writeMessage(3, getCompleteTime()); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -332,7 +256,7 @@ public int getSerializedSize() { if (completeTime_ != null) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getCompleteTime()); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -357,7 +281,7 @@ public boolean equals(final java.lang.Object obj) { if (hasCompleteTime()) { if (!getCompleteTime().equals(other.getCompleteTime())) return false; } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -378,7 +302,7 @@ public int hashCode() { hash = (37 * hash) + COMPLETE_TIME_FIELD_NUMBER; hash = (53 * hash) + getCompleteTime().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -508,17 +432,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.DeleteWorkerPoolOperationMetadata.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -636,7 +553,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.DeleteWorkerPoolOperationMetad if (other.hasCompleteTime()) { mergeCompleteTime(other.getCompleteTime()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -651,18 +568,49 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.DeleteWorkerPoolOperationMetadata parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + workerPool_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + input.readMessage(getCreateTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 18 + case 26: + { + input.readMessage(getCompleteTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloudbuild.v1.DeleteWorkerPoolOperationMetadata) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1182,7 +1130,18 @@ public DeleteWorkerPoolOperationMetadata parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new DeleteWorkerPoolOperationMetadata(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/DeleteWorkerPoolRequest.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/DeleteWorkerPoolRequest.java index 676390d9..23e433f9 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/DeleteWorkerPoolRequest.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/DeleteWorkerPoolRequest.java @@ -53,69 +53,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private DeleteWorkerPoolRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - etag_ = s; - break; - } - case 24: - { - allowMissing_ = input.readBool(); - break; - } - case 32: - { - validateOnly_ = input.readBool(); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_DeleteWorkerPoolRequest_descriptor; @@ -303,7 +240,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (validateOnly_ != false) { output.writeBool(4, validateOnly_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -324,7 +261,7 @@ public int getSerializedSize() { if (validateOnly_ != false) { size += com.google.protobuf.CodedOutputStream.computeBoolSize(4, validateOnly_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -344,7 +281,7 @@ public boolean equals(final java.lang.Object obj) { if (!getEtag().equals(other.getEtag())) return false; if (getAllowMissing() != other.getAllowMissing()) return false; if (getValidateOnly() != other.getValidateOnly()) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -363,7 +300,7 @@ public int hashCode() { hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getAllowMissing()); hash = (37 * hash) + VALIDATE_ONLY_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getValidateOnly()); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -492,17 +429,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.DeleteWorkerPoolRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -611,7 +541,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.DeleteWorkerPoolRequest other) if (other.getValidateOnly() != false) { setValidateOnly(other.getValidateOnly()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -626,17 +556,55 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.DeleteWorkerPoolRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + etag_ = input.readStringRequireUtf8(); + + break; + } // case 18 + case 24: + { + allowMissing_ = input.readBool(); + + break; + } // case 24 + case 32: + { + validateOnly_ = input.readBool(); + + break; + } // case 32 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.cloudbuild.v1.DeleteWorkerPoolRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1019,7 +987,18 @@ public DeleteWorkerPoolRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new DeleteWorkerPoolRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/FileHashes.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/FileHashes.java index 1f4d7574..4955822c 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/FileHashes.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/FileHashes.java @@ -53,59 +53,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private FileHashes( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - fileHash_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - fileHash_.add( - input.readMessage(com.google.cloudbuild.v1.Hash.parser(), extensionRegistry)); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - if (((mutable_bitField0_ & 0x00000001) != 0)) { - fileHash_ = java.util.Collections.unmodifiableList(fileHash_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_FileHashes_descriptor; @@ -207,7 +154,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io for (int i = 0; i < fileHash_.size(); i++) { output.writeMessage(1, fileHash_.get(i)); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -219,7 +166,7 @@ public int getSerializedSize() { for (int i = 0; i < fileHash_.size(); i++) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, fileHash_.get(i)); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -235,7 +182,7 @@ public boolean equals(final java.lang.Object obj) { com.google.cloudbuild.v1.FileHashes other = (com.google.cloudbuild.v1.FileHashes) obj; if (!getFileHashList().equals(other.getFileHashList())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -250,7 +197,7 @@ public int hashCode() { hash = (37 * hash) + FILE_HASH_FIELD_NUMBER; hash = (53 * hash) + getFileHashList().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -379,19 +326,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.FileHashes.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getFileHashFieldBuilder(); - } } @java.lang.Override @@ -399,10 +337,11 @@ public Builder clear() { super.clear(); if (fileHashBuilder_ == null) { fileHash_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); } else { + fileHash_ = null; fileHashBuilder_.clear(); } + bitField0_ = (bitField0_ & ~0x00000001); return this; } @@ -515,7 +454,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.FileHashes other) { } } } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -530,17 +469,43 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.FileHashes parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.cloudbuild.v1.Hash m = + input.readMessage(com.google.cloudbuild.v1.Hash.parser(), extensionRegistry); + if (fileHashBuilder_ == null) { + ensureFileHashIsMutable(); + fileHash_.add(m); + } else { + fileHashBuilder_.addMessage(m); + } + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.cloudbuild.v1.FileHashes) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -924,7 +889,18 @@ public FileHashes parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new FileHashes(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GetBuildRequest.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GetBuildRequest.java index 8070af7c..21469ddb 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GetBuildRequest.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GetBuildRequest.java @@ -54,66 +54,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private GetBuildRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - projectId_ = s; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - id_ = s; - break; - } - case 34: - { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_GetBuildRequest_descriptor; @@ -301,7 +241,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 4, name_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -319,7 +259,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, name_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -337,7 +277,7 @@ public boolean equals(final java.lang.Object obj) { if (!getName().equals(other.getName())) return false; if (!getProjectId().equals(other.getProjectId())) return false; if (!getId().equals(other.getId())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -354,7 +294,7 @@ public int hashCode() { hash = (53 * hash) + getProjectId().hashCode(); hash = (37 * hash) + ID_FIELD_NUMBER; hash = (53 * hash) + getId().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -483,17 +423,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.GetBuildRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -596,7 +529,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.GetBuildRequest other) { id_ = other.id_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -611,17 +544,49 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.GetBuildRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + projectId_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + id_ = input.readStringRequireUtf8(); + + break; + } // case 18 + case 34: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 34 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.cloudbuild.v1.GetBuildRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -980,7 +945,18 @@ public GetBuildRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new GetBuildRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GetBuildTriggerRequest.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GetBuildTriggerRequest.java index 28fb6f1a..9798f12f 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GetBuildTriggerRequest.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GetBuildTriggerRequest.java @@ -54,66 +54,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private GetBuildTriggerRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - projectId_ = s; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - triggerId_ = s; - break; - } - case 26: - { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_GetBuildTriggerRequest_descriptor; @@ -301,7 +241,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 3, name_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -319,7 +259,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, name_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -338,7 +278,7 @@ public boolean equals(final java.lang.Object obj) { if (!getName().equals(other.getName())) return false; if (!getProjectId().equals(other.getProjectId())) return false; if (!getTriggerId().equals(other.getTriggerId())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -355,7 +295,7 @@ public int hashCode() { hash = (53 * hash) + getProjectId().hashCode(); hash = (37 * hash) + TRIGGER_ID_FIELD_NUMBER; hash = (53 * hash) + getTriggerId().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -484,17 +424,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.GetBuildTriggerRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -598,7 +531,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.GetBuildTriggerRequest other) triggerId_ = other.triggerId_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -613,17 +546,49 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.GetBuildTriggerRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + projectId_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + triggerId_ = input.readStringRequireUtf8(); + + break; + } // case 18 + case 26: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.cloudbuild.v1.GetBuildTriggerRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -982,7 +947,18 @@ public GetBuildTriggerRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new GetBuildTriggerRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GetWorkerPoolRequest.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GetWorkerPoolRequest.java index 7d2137ba..192beb8d 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GetWorkerPoolRequest.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GetWorkerPoolRequest.java @@ -52,52 +52,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private GetWorkerPoolRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_GetWorkerPoolRequest_descriptor; @@ -185,7 +139,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -197,7 +151,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -214,7 +168,7 @@ public boolean equals(final java.lang.Object obj) { (com.google.cloudbuild.v1.GetWorkerPoolRequest) obj; if (!getName().equals(other.getName())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -227,7 +181,7 @@ public int hashCode() { hash = (19 * hash) + getDescriptor().hashCode(); hash = (37 * hash) + NAME_FIELD_NUMBER; hash = (53 * hash) + getName().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -356,17 +310,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.GetWorkerPoolRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -455,7 +402,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.GetWorkerPoolRequest other) { name_ = other.name_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -470,17 +417,37 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.GetWorkerPoolRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.cloudbuild.v1.GetWorkerPoolRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -637,7 +604,18 @@ public GetWorkerPoolRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new GetWorkerPoolRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GitHubEventsConfig.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GitHubEventsConfig.java index d77d5043..782d2155 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GitHubEventsConfig.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GitHubEventsConfig.java @@ -55,96 +55,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private GitHubEventsConfig( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 8: - { - installationId_ = input.readInt64(); - break; - } - case 34: - { - com.google.cloudbuild.v1.PullRequestFilter.Builder subBuilder = null; - if (eventCase_ == 4) { - subBuilder = ((com.google.cloudbuild.v1.PullRequestFilter) event_).toBuilder(); - } - event_ = - input.readMessage( - com.google.cloudbuild.v1.PullRequestFilter.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.cloudbuild.v1.PullRequestFilter) event_); - event_ = subBuilder.buildPartial(); - } - eventCase_ = 4; - break; - } - case 42: - { - com.google.cloudbuild.v1.PushFilter.Builder subBuilder = null; - if (eventCase_ == 5) { - subBuilder = ((com.google.cloudbuild.v1.PushFilter) event_).toBuilder(); - } - event_ = - input.readMessage( - com.google.cloudbuild.v1.PushFilter.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.cloudbuild.v1.PushFilter) event_); - event_ = subBuilder.buildPartial(); - } - eventCase_ = 5; - break; - } - case 50: - { - java.lang.String s = input.readStringRequireUtf8(); - - owner_ = s; - break; - } - case 58: - { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_GitHubEventsConfig_descriptor; @@ -463,7 +373,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 7, name_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -491,7 +401,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(7, name_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -521,7 +431,7 @@ public boolean equals(final java.lang.Object obj) { case 0: default: } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -550,7 +460,7 @@ public int hashCode() { case 0: default: } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -681,17 +591,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.GitHubEventsConfig.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -703,6 +606,12 @@ public Builder clear() { name_ = ""; + if (pullRequestBuilder_ != null) { + pullRequestBuilder_.clear(); + } + if (pushBuilder_ != null) { + pushBuilder_.clear(); + } eventCase_ = 0; event_ = null; return this; @@ -826,7 +735,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.GitHubEventsConfig other) { break; } } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -841,17 +750,61 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.GitHubEventsConfig parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + installationId_ = input.readInt64(); + + break; + } // case 8 + case 34: + { + input.readMessage(getPullRequestFieldBuilder().getBuilder(), extensionRegistry); + eventCase_ = 4; + break; + } // case 34 + case 42: + { + input.readMessage(getPushFieldBuilder().getBuilder(), extensionRegistry); + eventCase_ = 5; + break; + } // case 42 + case 50: + { + owner_ = input.readStringRequireUtf8(); + + break; + } // case 50 + case 58: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 58 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.cloudbuild.v1.GitHubEventsConfig) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1605,7 +1558,18 @@ public GitHubEventsConfig parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new GitHubEventsConfig(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Hash.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Hash.java index 673ee6fe..78889a60 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Hash.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Hash.java @@ -53,57 +53,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private Hash( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 8: - { - int rawValue = input.readEnum(); - - type_ = rawValue; - break; - } - case 18: - { - value_ = input.readBytes(); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_Hash_descriptor; @@ -349,7 +298,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!value_.isEmpty()) { output.writeBytes(2, value_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -364,7 +313,7 @@ public int getSerializedSize() { if (!value_.isEmpty()) { size += com.google.protobuf.CodedOutputStream.computeBytesSize(2, value_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -381,7 +330,7 @@ public boolean equals(final java.lang.Object obj) { if (type_ != other.type_) return false; if (!getValue().equals(other.getValue())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -396,7 +345,7 @@ public int hashCode() { hash = (53 * hash) + type_; hash = (37 * hash) + VALUE_FIELD_NUMBER; hash = (53 * hash) + getValue().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -523,17 +472,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.Hash.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -626,7 +568,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.Hash other) { if (other.getValue() != com.google.protobuf.ByteString.EMPTY) { setValue(other.getValue()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -641,17 +583,43 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.Hash parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 8: + { + type_ = input.readEnum(); + + break; + } // case 8 + case 18: + { + value_ = input.readBytes(); + + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.cloudbuild.v1.Hash) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -833,7 +801,18 @@ public Hash parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new Hash(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/InlineSecret.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/InlineSecret.java index 700185db..c76b39ee 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/InlineSecret.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/InlineSecret.java @@ -53,68 +53,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private InlineSecret( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - kmsKeyName_ = s; - break; - } - case 18: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - envMap_ = - com.google.protobuf.MapField.newMapField(EnvMapDefaultEntryHolder.defaultEntry); - mutable_bitField0_ |= 0x00000001; - } - com.google.protobuf.MapEntry - envMap__ = - input.readMessage( - EnvMapDefaultEntryHolder.defaultEntry.getParserForType(), - extensionRegistry); - envMap_.getMutableMap().put(envMap__.getKey(), envMap__.getValue()); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_InlineSecret_descriptor; @@ -331,7 +269,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io } com.google.protobuf.GeneratedMessageV3.serializeStringMapTo( output, internalGetEnvMap(), EnvMapDefaultEntryHolder.defaultEntry, 2); - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -353,7 +291,7 @@ public int getSerializedSize() { .build(); size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, envMap__); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -370,7 +308,7 @@ public boolean equals(final java.lang.Object obj) { if (!getKmsKeyName().equals(other.getKmsKeyName())) return false; if (!internalGetEnvMap().equals(other.internalGetEnvMap())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -387,7 +325,7 @@ public int hashCode() { hash = (37 * hash) + ENV_MAP_FIELD_NUMBER; hash = (53 * hash) + internalGetEnvMap().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -536,17 +474,10 @@ protected com.google.protobuf.MapField internalGetMutableMapField(int number) { } // Construct using com.google.cloudbuild.v1.InlineSecret.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -640,7 +571,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.InlineSecret other) { onChanged(); } internalGetMutableEnvMap().mergeFrom(other.internalGetEnvMap()); - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -655,17 +586,49 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.InlineSecret parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + kmsKeyName_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + com.google.protobuf.MapEntry + envMap__ = + input.readMessage( + EnvMapDefaultEntryHolder.defaultEntry.getParserForType(), + extensionRegistry); + internalGetMutableEnvMap() + .getMutableMap() + .put(envMap__.getKey(), envMap__.getValue()); + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.cloudbuild.v1.InlineSecret) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1004,7 +967,18 @@ public InlineSecret parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new InlineSecret(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildTriggersRequest.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildTriggersRequest.java index 8ef0f4e4..dc2fafad 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildTriggersRequest.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildTriggersRequest.java @@ -54,71 +54,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private ListBuildTriggersRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - projectId_ = s; - break; - } - case 16: - { - pageSize_ = input.readInt32(); - break; - } - case 26: - { - java.lang.String s = input.readStringRequireUtf8(); - - pageToken_ = s; - break; - } - case 34: - { - java.lang.String s = input.readStringRequireUtf8(); - - parent_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_ListBuildTriggersRequest_descriptor; @@ -327,7 +262,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 4, parent_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -348,7 +283,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, parent_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -368,7 +303,7 @@ public boolean equals(final java.lang.Object obj) { if (!getProjectId().equals(other.getProjectId())) return false; if (getPageSize() != other.getPageSize()) return false; if (!getPageToken().equals(other.getPageToken())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -387,7 +322,7 @@ public int hashCode() { hash = (53 * hash) + getPageSize(); hash = (37 * hash) + PAGE_TOKEN_FIELD_NUMBER; hash = (53 * hash) + getPageToken().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -516,17 +451,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.ListBuildTriggersRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -636,7 +564,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.ListBuildTriggersRequest other pageToken_ = other.pageToken_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -651,18 +579,55 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.ListBuildTriggersRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + projectId_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 16: + { + pageSize_ = input.readInt32(); + + break; + } // case 16 + case 26: + { + pageToken_ = input.readStringRequireUtf8(); + + break; + } // case 26 + case 34: + { + parent_ = input.readStringRequireUtf8(); + + break; + } // case 34 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloudbuild.v1.ListBuildTriggersRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1073,7 +1038,18 @@ public ListBuildTriggersRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new ListBuildTriggersRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildTriggersResponse.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildTriggersResponse.java index d0764c63..b554bd7d 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildTriggersResponse.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildTriggersResponse.java @@ -53,67 +53,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private ListBuildTriggersResponse( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - triggers_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - triggers_.add( - input.readMessage( - com.google.cloudbuild.v1.BuildTrigger.parser(), extensionRegistry)); - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - nextPageToken_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - if (((mutable_bitField0_ & 0x00000001) != 0)) { - triggers_ = java.util.Collections.unmodifiableList(triggers_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_ListBuildTriggersResponse_descriptor; @@ -267,7 +206,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(nextPageToken_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 2, nextPageToken_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -282,7 +221,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(nextPageToken_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, nextPageToken_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -300,7 +239,7 @@ public boolean equals(final java.lang.Object obj) { if (!getTriggersList().equals(other.getTriggersList())) return false; if (!getNextPageToken().equals(other.getNextPageToken())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -317,7 +256,7 @@ public int hashCode() { } hash = (37 * hash) + NEXT_PAGE_TOKEN_FIELD_NUMBER; hash = (53 * hash) + getNextPageToken().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -446,19 +385,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.ListBuildTriggersResponse.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getTriggersFieldBuilder(); - } } @java.lang.Override @@ -466,10 +396,11 @@ public Builder clear() { super.clear(); if (triggersBuilder_ == null) { triggers_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); } else { + triggers_ = null; triggersBuilder_.clear(); } + bitField0_ = (bitField0_ & ~0x00000001); nextPageToken_ = ""; return this; @@ -591,7 +522,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.ListBuildTriggersResponse othe nextPageToken_ = other.nextPageToken_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -606,18 +537,50 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.ListBuildTriggersResponse parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.cloudbuild.v1.BuildTrigger m = + input.readMessage( + com.google.cloudbuild.v1.BuildTrigger.parser(), extensionRegistry); + if (triggersBuilder_ == null) { + ensureTriggersIsMutable(); + triggers_.add(m); + } else { + triggersBuilder_.addMessage(m); + } + break; + } // case 10 + case 18: + { + nextPageToken_ = input.readStringRequireUtf8(); + + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloudbuild.v1.ListBuildTriggersResponse) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1109,7 +1072,18 @@ public ListBuildTriggersResponse parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new ListBuildTriggersResponse(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildsRequest.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildsRequest.java index 37269406..c429dda2 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildsRequest.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildsRequest.java @@ -55,78 +55,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private ListBuildsRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - projectId_ = s; - break; - } - case 16: - { - pageSize_ = input.readInt32(); - break; - } - case 26: - { - java.lang.String s = input.readStringRequireUtf8(); - - pageToken_ = s; - break; - } - case 66: - { - java.lang.String s = input.readStringRequireUtf8(); - - filter_ = s; - break; - } - case 74: - { - java.lang.String s = input.readStringRequireUtf8(); - - parent_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_ListBuildsRequest_descriptor; @@ -397,7 +325,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 9, parent_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -421,7 +349,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(9, parent_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -442,7 +370,7 @@ public boolean equals(final java.lang.Object obj) { if (getPageSize() != other.getPageSize()) return false; if (!getPageToken().equals(other.getPageToken())) return false; if (!getFilter().equals(other.getFilter())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -463,7 +391,7 @@ public int hashCode() { hash = (53 * hash) + getPageToken().hashCode(); hash = (37 * hash) + FILTER_FIELD_NUMBER; hash = (53 * hash) + getFilter().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -592,17 +520,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.ListBuildsRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -718,7 +639,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.ListBuildsRequest other) { filter_ = other.filter_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -733,17 +654,61 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.ListBuildsRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + projectId_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 16: + { + pageSize_ = input.readInt32(); + + break; + } // case 16 + case 26: + { + pageToken_ = input.readStringRequireUtf8(); + + break; + } // case 26 + case 66: + { + filter_ = input.readStringRequireUtf8(); + + break; + } // case 66 + case 74: + { + parent_ = input.readStringRequireUtf8(); + + break; + } // case 74 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.cloudbuild.v1.ListBuildsRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1285,7 +1250,18 @@ public ListBuildsRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new ListBuildsRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildsResponse.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildsResponse.java index 12fa376e..ddf00fb1 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildsResponse.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildsResponse.java @@ -53,66 +53,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private ListBuildsResponse( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - builds_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - builds_.add( - input.readMessage(com.google.cloudbuild.v1.Build.parser(), extensionRegistry)); - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - nextPageToken_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - if (((mutable_bitField0_ & 0x00000001) != 0)) { - builds_ = java.util.Collections.unmodifiableList(builds_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_ListBuildsResponse_descriptor; @@ -268,7 +208,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(nextPageToken_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 2, nextPageToken_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -283,7 +223,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(nextPageToken_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, nextPageToken_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -301,7 +241,7 @@ public boolean equals(final java.lang.Object obj) { if (!getBuildsList().equals(other.getBuildsList())) return false; if (!getNextPageToken().equals(other.getNextPageToken())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -318,7 +258,7 @@ public int hashCode() { } hash = (37 * hash) + NEXT_PAGE_TOKEN_FIELD_NUMBER; hash = (53 * hash) + getNextPageToken().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -447,19 +387,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.ListBuildsResponse.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getBuildsFieldBuilder(); - } } @java.lang.Override @@ -467,10 +398,11 @@ public Builder clear() { super.clear(); if (buildsBuilder_ == null) { builds_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); } else { + builds_ = null; buildsBuilder_.clear(); } + bitField0_ = (bitField0_ & ~0x00000001); nextPageToken_ = ""; return this; @@ -591,7 +523,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.ListBuildsResponse other) { nextPageToken_ = other.nextPageToken_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -606,17 +538,49 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.ListBuildsResponse parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.cloudbuild.v1.Build m = + input.readMessage(com.google.cloudbuild.v1.Build.parser(), extensionRegistry); + if (buildsBuilder_ == null) { + ensureBuildsIsMutable(); + builds_.add(m); + } else { + buildsBuilder_.addMessage(m); + } + break; + } // case 10 + case 18: + { + nextPageToken_ = input.readStringRequireUtf8(); + + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.cloudbuild.v1.ListBuildsResponse) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1111,7 +1075,18 @@ public ListBuildsResponse parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new ListBuildsResponse(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListWorkerPoolsRequest.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListWorkerPoolsRequest.java index 38f64972..b5fa8093 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListWorkerPoolsRequest.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListWorkerPoolsRequest.java @@ -53,64 +53,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private ListWorkerPoolsRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - parent_ = s; - break; - } - case 16: - { - pageSize_ = input.readInt32(); - break; - } - case 26: - { - java.lang.String s = input.readStringRequireUtf8(); - - pageToken_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_ListWorkerPoolsRequest_descriptor; @@ -274,7 +216,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(pageToken_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 3, pageToken_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -292,7 +234,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(pageToken_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, pageToken_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -311,7 +253,7 @@ public boolean equals(final java.lang.Object obj) { if (!getParent().equals(other.getParent())) return false; if (getPageSize() != other.getPageSize()) return false; if (!getPageToken().equals(other.getPageToken())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -328,7 +270,7 @@ public int hashCode() { hash = (53 * hash) + getPageSize(); hash = (37 * hash) + PAGE_TOKEN_FIELD_NUMBER; hash = (53 * hash) + getPageToken().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -457,17 +399,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.ListWorkerPoolsRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -570,7 +505,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.ListWorkerPoolsRequest other) pageToken_ = other.pageToken_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -585,17 +520,49 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.ListWorkerPoolsRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + parent_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 16: + { + pageSize_ = input.readInt32(); + + break; + } // case 16 + case 26: + { + pageToken_ = input.readStringRequireUtf8(); + + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.cloudbuild.v1.ListWorkerPoolsRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -918,7 +885,18 @@ public ListWorkerPoolsRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new ListWorkerPoolsRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListWorkerPoolsResponse.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListWorkerPoolsResponse.java index 87fb6b94..d4a6099b 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListWorkerPoolsResponse.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListWorkerPoolsResponse.java @@ -53,67 +53,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private ListWorkerPoolsResponse( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - workerPools_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - workerPools_.add( - input.readMessage( - com.google.cloudbuild.v1.WorkerPool.parser(), extensionRegistry)); - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - nextPageToken_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - if (((mutable_bitField0_ & 0x00000001) != 0)) { - workerPools_ = java.util.Collections.unmodifiableList(workerPools_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_ListWorkerPoolsResponse_descriptor; @@ -271,7 +210,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(nextPageToken_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 2, nextPageToken_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -286,7 +225,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(nextPageToken_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, nextPageToken_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -304,7 +243,7 @@ public boolean equals(final java.lang.Object obj) { if (!getWorkerPoolsList().equals(other.getWorkerPoolsList())) return false; if (!getNextPageToken().equals(other.getNextPageToken())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -321,7 +260,7 @@ public int hashCode() { } hash = (37 * hash) + NEXT_PAGE_TOKEN_FIELD_NUMBER; hash = (53 * hash) + getNextPageToken().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -450,19 +389,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.ListWorkerPoolsResponse.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getWorkerPoolsFieldBuilder(); - } } @java.lang.Override @@ -470,10 +400,11 @@ public Builder clear() { super.clear(); if (workerPoolsBuilder_ == null) { workerPools_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); } else { + workerPools_ = null; workerPoolsBuilder_.clear(); } + bitField0_ = (bitField0_ & ~0x00000001); nextPageToken_ = ""; return this; @@ -595,7 +526,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.ListWorkerPoolsResponse other) nextPageToken_ = other.nextPageToken_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -610,17 +541,50 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.ListWorkerPoolsResponse parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.cloudbuild.v1.WorkerPool m = + input.readMessage( + com.google.cloudbuild.v1.WorkerPool.parser(), extensionRegistry); + if (workerPoolsBuilder_ == null) { + ensureWorkerPoolsIsMutable(); + workerPools_.add(m); + } else { + workerPoolsBuilder_.addMessage(m); + } + break; + } // case 10 + case 18: + { + nextPageToken_ = input.readStringRequireUtf8(); + + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.cloudbuild.v1.ListWorkerPoolsResponse) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1122,7 +1086,18 @@ public ListWorkerPoolsResponse parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new ListWorkerPoolsResponse(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/PrivatePoolV1Config.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/PrivatePoolV1Config.java index 0dbbb29c..b939aca1 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/PrivatePoolV1Config.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/PrivatePoolV1Config.java @@ -50,79 +50,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private PrivatePoolV1Config( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig.Builder subBuilder = null; - if (workerConfig_ != null) { - subBuilder = workerConfig_.toBuilder(); - } - workerConfig_ = - input.readMessage( - com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(workerConfig_); - workerConfig_ = subBuilder.buildPartial(); - } - - break; - } - case 18: - { - com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig.Builder subBuilder = null; - if (networkConfig_ != null) { - subBuilder = networkConfig_.toBuilder(); - } - networkConfig_ = - input.readMessage( - com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig.parser(), - extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(networkConfig_); - networkConfig_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_PrivatePoolV1Config_descriptor; @@ -226,57 +153,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private WorkerConfig( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - machineType_ = s; - break; - } - case 16: - { - diskSizeGb_ = input.readInt64(); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_PrivatePoolV1Config_WorkerConfig_descriptor; @@ -389,7 +265,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (diskSizeGb_ != 0L) { output.writeInt64(2, diskSizeGb_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -404,7 +280,7 @@ public int getSerializedSize() { if (diskSizeGb_ != 0L) { size += com.google.protobuf.CodedOutputStream.computeInt64Size(2, diskSizeGb_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -422,7 +298,7 @@ public boolean equals(final java.lang.Object obj) { if (!getMachineType().equals(other.getMachineType())) return false; if (getDiskSizeGb() != other.getDiskSizeGb()) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -437,7 +313,7 @@ public int hashCode() { hash = (53 * hash) + getMachineType().hashCode(); hash = (37 * hash) + DISK_SIZE_GB_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getDiskSizeGb()); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -570,17 +446,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -678,7 +547,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConf if (other.getDiskSizeGb() != 0L) { setDiskSizeGb(other.getDiskSizeGb()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -693,18 +562,43 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + machineType_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 16: + { + diskSizeGb_ = input.readInt64(); + + break; + } // case 16 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -926,7 +820,19 @@ public WorkerConfig parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new WorkerConfig(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException() + .setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; @@ -1057,59 +963,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private NetworkConfig( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - peeredNetwork_ = s; - break; - } - case 16: - { - int rawValue = input.readEnum(); - - egressOption_ = rawValue; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_PrivatePoolV1Config_NetworkConfig_descriptor; @@ -1423,7 +1276,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io .getNumber()) { output.writeEnum(2, egressOption_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -1441,7 +1294,7 @@ public int getSerializedSize() { .getNumber()) { size += com.google.protobuf.CodedOutputStream.computeEnumSize(2, egressOption_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -1459,7 +1312,7 @@ public boolean equals(final java.lang.Object obj) { if (!getPeeredNetwork().equals(other.getPeeredNetwork())) return false; if (egressOption_ != other.egressOption_) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -1474,7 +1327,7 @@ public int hashCode() { hash = (53 * hash) + getPeeredNetwork().hashCode(); hash = (37 * hash) + EGRESS_OPTION_FIELD_NUMBER; hash = (53 * hash) + egressOption_; - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -1606,17 +1459,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -1716,7 +1562,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkCon if (other.egressOption_ != 0) { setEgressOptionValue(other.getEgressOptionValue()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -1731,18 +1577,43 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + peeredNetwork_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 16: + { + egressOption_ = input.readEnum(); + + break; + } // case 16 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -2037,7 +1908,19 @@ public NetworkConfig parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new NetworkConfig(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException() + .setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; @@ -2177,7 +2060,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (networkConfig_ != null) { output.writeMessage(2, getNetworkConfig()); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -2192,7 +2075,7 @@ public int getSerializedSize() { if (networkConfig_ != null) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getNetworkConfig()); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -2216,7 +2099,7 @@ public boolean equals(final java.lang.Object obj) { if (hasNetworkConfig()) { if (!getNetworkConfig().equals(other.getNetworkConfig())) return false; } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -2235,7 +2118,7 @@ public int hashCode() { hash = (37 * hash) + NETWORK_CONFIG_FIELD_NUMBER; hash = (53 * hash) + getNetworkConfig().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -2364,17 +2247,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.PrivatePoolV1Config.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -2484,7 +2360,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.PrivatePoolV1Config other) { if (other.hasNetworkConfig()) { mergeNetworkConfig(other.getNetworkConfig()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -2499,17 +2375,43 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.PrivatePoolV1Config parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage(getWorkerConfigFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 10 + case 18: + { + input.readMessage(getNetworkConfigFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.cloudbuild.v1.PrivatePoolV1Config) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -2943,7 +2845,18 @@ public PrivatePoolV1Config parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new PrivatePoolV1Config(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/PubsubConfig.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/PubsubConfig.java index 73fc2729..8f06a140 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/PubsubConfig.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/PubsubConfig.java @@ -56,73 +56,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private PubsubConfig( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - subscription_ = s; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - topic_ = s; - break; - } - case 26: - { - java.lang.String s = input.readStringRequireUtf8(); - - serviceAccountEmail_ = s; - break; - } - case 32: - { - int rawValue = input.readEnum(); - - state_ = rawValue; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_PubsubConfig_descriptor; @@ -559,7 +492,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (state_ != com.google.cloudbuild.v1.PubsubConfig.State.STATE_UNSPECIFIED.getNumber()) { output.writeEnum(4, state_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -580,7 +513,7 @@ public int getSerializedSize() { if (state_ != com.google.cloudbuild.v1.PubsubConfig.State.STATE_UNSPECIFIED.getNumber()) { size += com.google.protobuf.CodedOutputStream.computeEnumSize(4, state_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -599,7 +532,7 @@ public boolean equals(final java.lang.Object obj) { if (!getTopic().equals(other.getTopic())) return false; if (!getServiceAccountEmail().equals(other.getServiceAccountEmail())) return false; if (state_ != other.state_) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -618,7 +551,7 @@ public int hashCode() { hash = (53 * hash) + getServiceAccountEmail().hashCode(); hash = (37 * hash) + STATE_FIELD_NUMBER; hash = (53 * hash) + state_; - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -747,17 +680,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.PubsubConfig.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -866,7 +792,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.PubsubConfig other) { if (other.state_ != 0) { setStateValue(other.getStateValue()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -881,17 +807,55 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.PubsubConfig parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + subscription_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + topic_ = input.readStringRequireUtf8(); + + break; + } // case 18 + case 26: + { + serviceAccountEmail_ = input.readStringRequireUtf8(); + + break; + } // case 26 + case 32: + { + state_ = input.readEnum(); + + break; + } // case 32 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.cloudbuild.v1.PubsubConfig) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1361,7 +1325,18 @@ public PubsubConfig parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new PubsubConfig(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/PullRequestFilter.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/PullRequestFilter.java index b9a184c1..62dec8c8 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/PullRequestFilter.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/PullRequestFilter.java @@ -53,64 +53,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private PullRequestFilter( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - gitRefCase_ = 2; - gitRef_ = s; - break; - } - case 40: - { - int rawValue = input.readEnum(); - - commentControl_ = rawValue; - break; - } - case 48: - { - invertRegex_ = input.readBool(); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_PullRequestFilter_descriptor; @@ -492,7 +434,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (invertRegex_ != false) { output.writeBool(6, invertRegex_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -512,7 +454,7 @@ public int getSerializedSize() { if (invertRegex_ != false) { size += com.google.protobuf.CodedOutputStream.computeBoolSize(6, invertRegex_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -538,7 +480,7 @@ public boolean equals(final java.lang.Object obj) { case 0: default: } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -561,7 +503,7 @@ public int hashCode() { case 0: default: } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -691,17 +633,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.PullRequestFilter.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -814,7 +749,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.PullRequestFilter other) { break; } } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -829,17 +764,50 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.PullRequestFilter parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 18: + { + java.lang.String s = input.readStringRequireUtf8(); + gitRefCase_ = 2; + gitRef_ = s; + break; + } // case 18 + case 40: + { + commentControl_ = input.readEnum(); + + break; + } // case 40 + case 48: + { + invertRegex_ = input.readBool(); + + break; + } // case 48 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.cloudbuild.v1.PullRequestFilter) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1191,7 +1159,18 @@ public PullRequestFilter parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new PullRequestFilter(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/PushFilter.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/PushFilter.java index be907a5e..7f7d5c41 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/PushFilter.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/PushFilter.java @@ -50,64 +50,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private PushFilter( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - gitRefCase_ = 2; - gitRef_ = s; - break; - } - case 26: - { - java.lang.String s = input.readStringRequireUtf8(); - gitRefCase_ = 3; - gitRef_ = s; - break; - } - case 32: - { - invertRegex_ = input.readBool(); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_PushFilter_descriptor; @@ -364,7 +306,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (invertRegex_ != false) { output.writeBool(4, invertRegex_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -382,7 +324,7 @@ public int getSerializedSize() { if (invertRegex_ != false) { size += com.google.protobuf.CodedOutputStream.computeBoolSize(4, invertRegex_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -409,7 +351,7 @@ public boolean equals(final java.lang.Object obj) { case 0: default: } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -434,7 +376,7 @@ public int hashCode() { case 0: default: } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -562,17 +504,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.PushFilter.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -688,7 +623,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.PushFilter other) { break; } } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -703,17 +638,51 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.PushFilter parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 18: + { + java.lang.String s = input.readStringRequireUtf8(); + gitRefCase_ = 2; + gitRef_ = s; + break; + } // case 18 + case 26: + { + java.lang.String s = input.readStringRequireUtf8(); + gitRefCase_ = 3; + gitRef_ = s; + break; + } // case 26 + case 32: + { + invertRegex_ = input.readBool(); + + break; + } // case 32 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.cloudbuild.v1.PushFilter) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1110,7 +1079,18 @@ public PushFilter parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new PushFilter(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ReceiveTriggerWebhookRequest.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ReceiveTriggerWebhookRequest.java index 1d092a6b..8623b6b1 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ReceiveTriggerWebhookRequest.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ReceiveTriggerWebhookRequest.java @@ -56,87 +56,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private ReceiveTriggerWebhookRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - com.google.api.HttpBody.Builder subBuilder = null; - if (body_ != null) { - subBuilder = body_.toBuilder(); - } - body_ = input.readMessage(com.google.api.HttpBody.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(body_); - body_ = subBuilder.buildPartial(); - } - - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - projectId_ = s; - break; - } - case 26: - { - java.lang.String s = input.readStringRequireUtf8(); - - trigger_ = s; - break; - } - case 34: - { - java.lang.String s = input.readStringRequireUtf8(); - - secret_ = s; - break; - } - case 42: - { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_ReceiveTriggerWebhookRequest_descriptor; @@ -425,7 +344,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 5, name_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -449,7 +368,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(5, name_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -473,7 +392,7 @@ public boolean equals(final java.lang.Object obj) { if (!getProjectId().equals(other.getProjectId())) return false; if (!getTrigger().equals(other.getTrigger())) return false; if (!getSecret().equals(other.getSecret())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -496,7 +415,7 @@ public int hashCode() { hash = (53 * hash) + getTrigger().hashCode(); hash = (37 * hash) + SECRET_FIELD_NUMBER; hash = (53 * hash) + getSecret().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -627,17 +546,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -762,7 +674,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest o secret_ = other.secret_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -777,18 +689,61 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage(getBodyFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 10 + case 18: + { + projectId_ = input.readStringRequireUtf8(); + + break; + } // case 18 + case 26: + { + trigger_ = input.readStringRequireUtf8(); + + break; + } // case 26 + case 34: + { + secret_ = input.readStringRequireUtf8(); + + break; + } // case 34 + case 42: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 42 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1430,7 +1385,18 @@ public ReceiveTriggerWebhookRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new ReceiveTriggerWebhookRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ReceiveTriggerWebhookResponse.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ReceiveTriggerWebhookResponse.java index a3c5f69d..39b4a63e 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ReceiveTriggerWebhookResponse.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ReceiveTriggerWebhookResponse.java @@ -51,45 +51,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private ReceiveTriggerWebhookResponse( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_ReceiveTriggerWebhookResponse_descriptor; @@ -119,7 +80,7 @@ public final boolean isInitialized() { @java.lang.Override public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -128,7 +89,7 @@ public int getSerializedSize() { if (size != -1) return size; size = 0; - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -144,7 +105,7 @@ public boolean equals(final java.lang.Object obj) { com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse other = (com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse) obj; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -155,7 +116,7 @@ public int hashCode() { } int hash = 41; hash = (19 * hash) + getDescriptor().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -286,17 +247,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -379,7 +333,7 @@ public Builder mergeFrom(com.google.protobuf.Message other) { public Builder mergeFrom(com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse other) { if (other == com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse.getDefaultInstance()) return this; - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -394,18 +348,31 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -441,7 +408,18 @@ public ReceiveTriggerWebhookResponse parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new ReceiveTriggerWebhookResponse(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/RepoSource.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/RepoSource.java index e7145b72..3e4790e5 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/RepoSource.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/RepoSource.java @@ -54,110 +54,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private RepoSource( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - projectId_ = s; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - repoName_ = s; - break; - } - case 26: - { - java.lang.String s = input.readStringRequireUtf8(); - revisionCase_ = 3; - revision_ = s; - break; - } - case 34: - { - java.lang.String s = input.readStringRequireUtf8(); - revisionCase_ = 4; - revision_ = s; - break; - } - case 42: - { - java.lang.String s = input.readStringRequireUtf8(); - revisionCase_ = 5; - revision_ = s; - break; - } - case 58: - { - java.lang.String s = input.readStringRequireUtf8(); - - dir_ = s; - break; - } - case 64: - { - invertRegex_ = input.readBool(); - break; - } - case 74: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - substitutions_ = - com.google.protobuf.MapField.newMapField( - SubstitutionsDefaultEntryHolder.defaultEntry); - mutable_bitField0_ |= 0x00000001; - } - com.google.protobuf.MapEntry substitutions__ = - input.readMessage( - SubstitutionsDefaultEntryHolder.defaultEntry.getParserForType(), - extensionRegistry); - substitutions_ - .getMutableMap() - .put(substitutions__.getKey(), substitutions__.getValue()); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_RepoSource_descriptor; @@ -770,7 +666,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io } com.google.protobuf.GeneratedMessageV3.serializeStringMapTo( output, internalGetSubstitutions(), SubstitutionsDefaultEntryHolder.defaultEntry, 9); - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -810,7 +706,7 @@ public int getSerializedSize() { .build(); size += com.google.protobuf.CodedOutputStream.computeMessageSize(9, substitutions__); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -844,7 +740,7 @@ public boolean equals(final java.lang.Object obj) { case 0: default: } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -883,7 +779,7 @@ public int hashCode() { case 0: default: } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -1031,17 +927,10 @@ protected com.google.protobuf.MapField internalGetMutableMapField(int number) { } // Construct using com.google.cloudbuild.v1.RepoSource.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -1193,7 +1082,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.RepoSource other) { break; } } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -1208,17 +1097,87 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.RepoSource parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + projectId_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + repoName_ = input.readStringRequireUtf8(); + + break; + } // case 18 + case 26: + { + java.lang.String s = input.readStringRequireUtf8(); + revisionCase_ = 3; + revision_ = s; + break; + } // case 26 + case 34: + { + java.lang.String s = input.readStringRequireUtf8(); + revisionCase_ = 4; + revision_ = s; + break; + } // case 34 + case 42: + { + java.lang.String s = input.readStringRequireUtf8(); + revisionCase_ = 5; + revision_ = s; + break; + } // case 42 + case 58: + { + dir_ = input.readStringRequireUtf8(); + + break; + } // case 58 + case 64: + { + invertRegex_ = input.readBool(); + + break; + } // case 64 + case 74: + { + com.google.protobuf.MapEntry substitutions__ = + input.readMessage( + SubstitutionsDefaultEntryHolder.defaultEntry.getParserForType(), + extensionRegistry); + internalGetMutableSubstitutions() + .getMutableMap() + .put(substitutions__.getKey(), substitutions__.getValue()); + break; + } // case 74 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.cloudbuild.v1.RepoSource) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -2252,7 +2211,18 @@ public RepoSource parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new RepoSource(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Results.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Results.java index 699e530c..ae128f3e 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Results.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Results.java @@ -55,112 +55,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private Results( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 18: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - images_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - images_.add( - input.readMessage( - com.google.cloudbuild.v1.BuiltImage.parser(), extensionRegistry)); - break; - } - case 26: - { - java.lang.String s = input.readStringRequireUtf8(); - if (!((mutable_bitField0_ & 0x00000002) != 0)) { - buildStepImages_ = new com.google.protobuf.LazyStringArrayList(); - mutable_bitField0_ |= 0x00000002; - } - buildStepImages_.add(s); - break; - } - case 34: - { - java.lang.String s = input.readStringRequireUtf8(); - - artifactManifest_ = s; - break; - } - case 40: - { - numArtifacts_ = input.readInt64(); - break; - } - case 50: - { - if (!((mutable_bitField0_ & 0x00000004) != 0)) { - buildStepOutputs_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000004; - } - buildStepOutputs_.add(input.readBytes()); - break; - } - case 58: - { - com.google.cloudbuild.v1.TimeSpan.Builder subBuilder = null; - if (artifactTiming_ != null) { - subBuilder = artifactTiming_.toBuilder(); - } - artifactTiming_ = - input.readMessage(com.google.cloudbuild.v1.TimeSpan.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(artifactTiming_); - artifactTiming_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - if (((mutable_bitField0_ & 0x00000001) != 0)) { - images_ = java.util.Collections.unmodifiableList(images_); - } - if (((mutable_bitField0_ & 0x00000002) != 0)) { - buildStepImages_ = buildStepImages_.getUnmodifiableView(); - } - if (((mutable_bitField0_ & 0x00000004) != 0)) { - buildStepOutputs_ = java.util.Collections.unmodifiableList(buildStepOutputs_); // C - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_Results_descriptor; @@ -515,7 +409,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (artifactTiming_ != null) { output.writeMessage(7, getArtifactTiming()); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -553,7 +447,7 @@ public int getSerializedSize() { if (artifactTiming_ != null) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(7, getArtifactTiming()); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -577,7 +471,7 @@ public boolean equals(final java.lang.Object obj) { if (hasArtifactTiming()) { if (!getArtifactTiming().equals(other.getArtifactTiming())) return false; } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -608,7 +502,7 @@ public int hashCode() { hash = (37 * hash) + ARTIFACT_TIMING_FIELD_NUMBER; hash = (53 * hash) + getArtifactTiming().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -736,19 +630,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.Results.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getImagesFieldBuilder(); - } } @java.lang.Override @@ -756,10 +641,11 @@ public Builder clear() { super.clear(); if (imagesBuilder_ == null) { images_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); } else { + images_ = null; imagesBuilder_.clear(); } + bitField0_ = (bitField0_ & ~0x00000001); buildStepImages_ = com.google.protobuf.LazyStringArrayList.EMPTY; bitField0_ = (bitField0_ & ~0x00000002); artifactManifest_ = ""; @@ -933,7 +819,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.Results other) { if (other.hasArtifactTiming()) { mergeArtifactTiming(other.getArtifactTiming()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -948,17 +834,76 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.Results parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 18: + { + com.google.cloudbuild.v1.BuiltImage m = + input.readMessage( + com.google.cloudbuild.v1.BuiltImage.parser(), extensionRegistry); + if (imagesBuilder_ == null) { + ensureImagesIsMutable(); + images_.add(m); + } else { + imagesBuilder_.addMessage(m); + } + break; + } // case 18 + case 26: + { + java.lang.String s = input.readStringRequireUtf8(); + ensureBuildStepImagesIsMutable(); + buildStepImages_.add(s); + break; + } // case 26 + case 34: + { + artifactManifest_ = input.readStringRequireUtf8(); + + break; + } // case 34 + case 40: + { + numArtifacts_ = input.readInt64(); + + break; + } // case 40 + case 50: + { + com.google.protobuf.ByteString v = input.readBytes(); + ensureBuildStepOutputsIsMutable(); + buildStepOutputs_.add(v); + break; + } // case 50 + case 58: + { + input.readMessage(getArtifactTimingFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 58 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.cloudbuild.v1.Results) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -2027,7 +1972,18 @@ public Results parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new Results(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/RetryBuildRequest.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/RetryBuildRequest.java index 9fd2c74f..417e668d 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/RetryBuildRequest.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/RetryBuildRequest.java @@ -54,66 +54,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private RetryBuildRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - projectId_ = s; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - id_ = s; - break; - } - case 26: - { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_RetryBuildRequest_descriptor; @@ -301,7 +241,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 3, name_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -319,7 +259,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, name_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -338,7 +278,7 @@ public boolean equals(final java.lang.Object obj) { if (!getName().equals(other.getName())) return false; if (!getProjectId().equals(other.getProjectId())) return false; if (!getId().equals(other.getId())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -355,7 +295,7 @@ public int hashCode() { hash = (53 * hash) + getProjectId().hashCode(); hash = (37 * hash) + ID_FIELD_NUMBER; hash = (53 * hash) + getId().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -484,17 +424,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.RetryBuildRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -597,7 +530,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.RetryBuildRequest other) { id_ = other.id_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -612,17 +545,49 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.RetryBuildRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + projectId_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + id_ = input.readStringRequireUtf8(); + + break; + } // case 18 + case 26: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.cloudbuild.v1.RetryBuildRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -981,7 +946,18 @@ public RetryBuildRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new RetryBuildRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/RunBuildTriggerRequest.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/RunBuildTriggerRequest.java index 63391bbf..2d80a3f1 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/RunBuildTriggerRequest.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/RunBuildTriggerRequest.java @@ -54,82 +54,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private RunBuildTriggerRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - projectId_ = s; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - triggerId_ = s; - break; - } - case 26: - { - com.google.cloudbuild.v1.RepoSource.Builder subBuilder = null; - if (source_ != null) { - subBuilder = source_.toBuilder(); - } - source_ = - input.readMessage( - com.google.cloudbuild.v1.RepoSource.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(source_); - source_ = subBuilder.buildPartial(); - } - - break; - } - case 34: - { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_RunBuildTriggerRequest_descriptor; @@ -366,7 +290,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 4, name_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -387,7 +311,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, name_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -410,7 +334,7 @@ public boolean equals(final java.lang.Object obj) { if (hasSource()) { if (!getSource().equals(other.getSource())) return false; } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -431,7 +355,7 @@ public int hashCode() { hash = (37 * hash) + SOURCE_FIELD_NUMBER; hash = (53 * hash) + getSource().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -560,17 +484,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.RunBuildTriggerRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -688,7 +605,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.RunBuildTriggerRequest other) if (other.hasSource()) { mergeSource(other.getSource()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -703,17 +620,55 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.RunBuildTriggerRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + projectId_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + triggerId_ = input.readStringRequireUtf8(); + + break; + } // case 18 + case 26: + { + input.readMessage(getSourceFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 26 + case 34: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 34 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.cloudbuild.v1.RunBuildTriggerRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1253,7 +1208,18 @@ public RunBuildTriggerRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new RunBuildTriggerRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Secret.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Secret.java index f5e14c0a..eb3e7bc0 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Secret.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Secret.java @@ -56,69 +56,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private Secret( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - kmsKeyName_ = s; - break; - } - case 26: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - secretEnv_ = - com.google.protobuf.MapField.newMapField( - SecretEnvDefaultEntryHolder.defaultEntry); - mutable_bitField0_ |= 0x00000001; - } - com.google.protobuf.MapEntry - secretEnv__ = - input.readMessage( - SecretEnvDefaultEntryHolder.defaultEntry.getParserForType(), - extensionRegistry); - secretEnv_.getMutableMap().put(secretEnv__.getKey(), secretEnv__.getValue()); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_Secret_descriptor; @@ -332,7 +269,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io } com.google.protobuf.GeneratedMessageV3.serializeStringMapTo( output, internalGetSecretEnv(), SecretEnvDefaultEntryHolder.defaultEntry, 3); - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -354,7 +291,7 @@ public int getSerializedSize() { .build(); size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, secretEnv__); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -371,7 +308,7 @@ public boolean equals(final java.lang.Object obj) { if (!getKmsKeyName().equals(other.getKmsKeyName())) return false; if (!internalGetSecretEnv().equals(other.internalGetSecretEnv())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -388,7 +325,7 @@ public int hashCode() { hash = (37 * hash) + SECRET_ENV_FIELD_NUMBER; hash = (53 * hash) + internalGetSecretEnv().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -539,17 +476,10 @@ protected com.google.protobuf.MapField internalGetMutableMapField(int number) { } // Construct using com.google.cloudbuild.v1.Secret.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -642,7 +572,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.Secret other) { onChanged(); } internalGetMutableSecretEnv().mergeFrom(other.internalGetSecretEnv()); - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -657,17 +587,49 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.Secret parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + kmsKeyName_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 26: + { + com.google.protobuf.MapEntry + secretEnv__ = + input.readMessage( + SecretEnvDefaultEntryHolder.defaultEntry.getParserForType(), + extensionRegistry); + internalGetMutableSecretEnv() + .getMutableMap() + .put(secretEnv__.getKey(), secretEnv__.getValue()); + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.cloudbuild.v1.Secret) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1003,7 +965,18 @@ public Secret parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new Secret(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/SecretManagerSecret.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/SecretManagerSecret.java index 4a0f3d4e..c665fee4 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/SecretManagerSecret.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/SecretManagerSecret.java @@ -53,59 +53,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private SecretManagerSecret( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - versionName_ = s; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - env_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_SecretManagerSecret_descriptor; @@ -245,7 +192,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(env_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 2, env_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -260,7 +207,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(env_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, env_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -278,7 +225,7 @@ public boolean equals(final java.lang.Object obj) { if (!getVersionName().equals(other.getVersionName())) return false; if (!getEnv().equals(other.getEnv())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -293,7 +240,7 @@ public int hashCode() { hash = (53 * hash) + getVersionName().hashCode(); hash = (37 * hash) + ENV_FIELD_NUMBER; hash = (53 * hash) + getEnv().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -422,17 +369,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.SecretManagerSecret.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -528,7 +468,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.SecretManagerSecret other) { env_ = other.env_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -543,17 +483,43 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.SecretManagerSecret parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + versionName_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + env_ = input.readStringRequireUtf8(); + + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.cloudbuild.v1.SecretManagerSecret) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -816,7 +782,18 @@ public SecretManagerSecret parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new SecretManagerSecret(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Secrets.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Secrets.java index d176845e..a9b171f6 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Secrets.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Secrets.java @@ -53,75 +53,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private Secrets( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - secretManager_ = - new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; - } - secretManager_.add( - input.readMessage( - com.google.cloudbuild.v1.SecretManagerSecret.parser(), extensionRegistry)); - break; - } - case 18: - { - if (!((mutable_bitField0_ & 0x00000002) != 0)) { - inline_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000002; - } - inline_.add( - input.readMessage( - com.google.cloudbuild.v1.InlineSecret.parser(), extensionRegistry)); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - if (((mutable_bitField0_ & 0x00000001) != 0)) { - secretManager_ = java.util.Collections.unmodifiableList(secretManager_); - } - if (((mutable_bitField0_ & 0x00000002) != 0)) { - inline_ = java.util.Collections.unmodifiableList(inline_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_Secrets_descriptor; @@ -300,7 +231,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io for (int i = 0; i < inline_.size(); i++) { output.writeMessage(2, inline_.get(i)); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -315,7 +246,7 @@ public int getSerializedSize() { for (int i = 0; i < inline_.size(); i++) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, inline_.get(i)); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -332,7 +263,7 @@ public boolean equals(final java.lang.Object obj) { if (!getSecretManagerList().equals(other.getSecretManagerList())) return false; if (!getInlineList().equals(other.getInlineList())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -351,7 +282,7 @@ public int hashCode() { hash = (37 * hash) + INLINE_FIELD_NUMBER; hash = (53 * hash) + getInlineList().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -479,20 +410,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.Secrets.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { - getSecretManagerFieldBuilder(); - getInlineFieldBuilder(); - } } @java.lang.Override @@ -500,16 +421,18 @@ public Builder clear() { super.clear(); if (secretManagerBuilder_ == null) { secretManager_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); } else { + secretManager_ = null; secretManagerBuilder_.clear(); } + bitField0_ = (bitField0_ & ~0x00000001); if (inlineBuilder_ == null) { inline_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000002); } else { + inline_ = null; inlineBuilder_.clear(); } + bitField0_ = (bitField0_ & ~0x00000002); return this; } @@ -658,7 +581,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.Secrets other) { } } } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -673,17 +596,57 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.Secrets parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + com.google.cloudbuild.v1.SecretManagerSecret m = + input.readMessage( + com.google.cloudbuild.v1.SecretManagerSecret.parser(), extensionRegistry); + if (secretManagerBuilder_ == null) { + ensureSecretManagerIsMutable(); + secretManager_.add(m); + } else { + secretManagerBuilder_.addMessage(m); + } + break; + } // case 10 + case 18: + { + com.google.cloudbuild.v1.InlineSecret m = + input.readMessage( + com.google.cloudbuild.v1.InlineSecret.parser(), extensionRegistry); + if (inlineBuilder_ == null) { + ensureInlineIsMutable(); + inline_.add(m); + } else { + inlineBuilder_.addMessage(m); + } + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.cloudbuild.v1.Secrets) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1442,7 +1405,18 @@ public Secrets parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new Secrets(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Source.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Source.java index 034b4180..4d34efcd 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Source.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Source.java @@ -50,93 +50,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private Source( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 18: - { - com.google.cloudbuild.v1.StorageSource.Builder subBuilder = null; - if (sourceCase_ == 2) { - subBuilder = ((com.google.cloudbuild.v1.StorageSource) source_).toBuilder(); - } - source_ = - input.readMessage( - com.google.cloudbuild.v1.StorageSource.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.cloudbuild.v1.StorageSource) source_); - source_ = subBuilder.buildPartial(); - } - sourceCase_ = 2; - break; - } - case 26: - { - com.google.cloudbuild.v1.RepoSource.Builder subBuilder = null; - if (sourceCase_ == 3) { - subBuilder = ((com.google.cloudbuild.v1.RepoSource) source_).toBuilder(); - } - source_ = - input.readMessage( - com.google.cloudbuild.v1.RepoSource.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.cloudbuild.v1.RepoSource) source_); - source_ = subBuilder.buildPartial(); - } - sourceCase_ = 3; - break; - } - case 66: - { - com.google.cloudbuild.v1.StorageSourceManifest.Builder subBuilder = null; - if (sourceCase_ == 8) { - subBuilder = ((com.google.cloudbuild.v1.StorageSourceManifest) source_).toBuilder(); - } - source_ = - input.readMessage( - com.google.cloudbuild.v1.StorageSourceManifest.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.cloudbuild.v1.StorageSourceManifest) source_); - source_ = subBuilder.buildPartial(); - } - sourceCase_ = 8; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_Source_descriptor; @@ -387,7 +300,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (sourceCase_ == 8) { output.writeMessage(8, (com.google.cloudbuild.v1.StorageSourceManifest) source_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -411,7 +324,7 @@ public int getSerializedSize() { com.google.protobuf.CodedOutputStream.computeMessageSize( 8, (com.google.cloudbuild.v1.StorageSourceManifest) source_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -440,7 +353,7 @@ public boolean equals(final java.lang.Object obj) { case 0: default: } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -467,7 +380,7 @@ public int hashCode() { case 0: default: } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -594,22 +507,24 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.Source.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override public Builder clear() { super.clear(); + if (storageSourceBuilder_ != null) { + storageSourceBuilder_.clear(); + } + if (repoSourceBuilder_ != null) { + repoSourceBuilder_.clear(); + } + if (storageSourceManifestBuilder_ != null) { + storageSourceManifestBuilder_.clear(); + } sourceCase_ = 0; source_ = null; return this; @@ -730,7 +645,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.Source other) { break; } } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -745,17 +660,50 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.Source parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 18: + { + input.readMessage(getStorageSourceFieldBuilder().getBuilder(), extensionRegistry); + sourceCase_ = 2; + break; + } // case 18 + case 26: + { + input.readMessage(getRepoSourceFieldBuilder().getBuilder(), extensionRegistry); + sourceCase_ = 3; + break; + } // case 26 + case 66: + { + input.readMessage( + getStorageSourceManifestFieldBuilder().getBuilder(), extensionRegistry); + sourceCase_ = 8; + break; + } // case 66 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.cloudbuild.v1.Source) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1471,7 +1419,18 @@ public Source parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new Source(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/SourceProvenance.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/SourceProvenance.java index b0ed0376..4acc6d33 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/SourceProvenance.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/SourceProvenance.java @@ -51,110 +51,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private SourceProvenance( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 26: - { - com.google.cloudbuild.v1.StorageSource.Builder subBuilder = null; - if (resolvedStorageSource_ != null) { - subBuilder = resolvedStorageSource_.toBuilder(); - } - resolvedStorageSource_ = - input.readMessage( - com.google.cloudbuild.v1.StorageSource.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(resolvedStorageSource_); - resolvedStorageSource_ = subBuilder.buildPartial(); - } - - break; - } - case 34: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - fileHashes_ = - com.google.protobuf.MapField.newMapField( - FileHashesDefaultEntryHolder.defaultEntry); - mutable_bitField0_ |= 0x00000001; - } - com.google.protobuf.MapEntry - fileHashes__ = - input.readMessage( - FileHashesDefaultEntryHolder.defaultEntry.getParserForType(), - extensionRegistry); - fileHashes_.getMutableMap().put(fileHashes__.getKey(), fileHashes__.getValue()); - break; - } - case 50: - { - com.google.cloudbuild.v1.RepoSource.Builder subBuilder = null; - if (resolvedRepoSource_ != null) { - subBuilder = resolvedRepoSource_.toBuilder(); - } - resolvedRepoSource_ = - input.readMessage( - com.google.cloudbuild.v1.RepoSource.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(resolvedRepoSource_); - resolvedRepoSource_ = subBuilder.buildPartial(); - } - - break; - } - case 74: - { - com.google.cloudbuild.v1.StorageSourceManifest.Builder subBuilder = null; - if (resolvedStorageSourceManifest_ != null) { - subBuilder = resolvedStorageSourceManifest_.toBuilder(); - } - resolvedStorageSourceManifest_ = - input.readMessage( - com.google.cloudbuild.v1.StorageSourceManifest.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(resolvedStorageSourceManifest_); - resolvedStorageSourceManifest_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_SourceProvenance_descriptor; @@ -510,7 +406,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (resolvedStorageSourceManifest_ != null) { output.writeMessage(9, getResolvedStorageSourceManifest()); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -542,7 +438,7 @@ public int getSerializedSize() { com.google.protobuf.CodedOutputStream.computeMessageSize( 9, getResolvedStorageSourceManifest()); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -573,7 +469,7 @@ public boolean equals(final java.lang.Object obj) { return false; } if (!internalGetFileHashes().equals(other.internalGetFileHashes())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -600,7 +496,7 @@ public int hashCode() { hash = (37 * hash) + FILE_HASHES_FIELD_NUMBER; hash = (53 * hash) + internalGetFileHashes().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -750,17 +646,10 @@ protected com.google.protobuf.MapField internalGetMutableMapField(int number) { } // Construct using com.google.cloudbuild.v1.SourceProvenance.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -889,7 +778,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.SourceProvenance other) { mergeResolvedStorageSourceManifest(other.getResolvedStorageSourceManifest()); } internalGetMutableFileHashes().mergeFrom(other.internalGetFileHashes()); - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -904,17 +793,64 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.SourceProvenance parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 26: + { + input.readMessage( + getResolvedStorageSourceFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 26 + case 34: + { + com.google.protobuf.MapEntry + fileHashes__ = + input.readMessage( + FileHashesDefaultEntryHolder.defaultEntry.getParserForType(), + extensionRegistry); + internalGetMutableFileHashes() + .getMutableMap() + .put(fileHashes__.getKey(), fileHashes__.getValue()); + break; + } // case 34 + case 50: + { + input.readMessage( + getResolvedRepoSourceFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 50 + case 74: + { + input.readMessage( + getResolvedStorageSourceManifestFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 74 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.cloudbuild.v1.SourceProvenance) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1799,7 +1735,18 @@ public SourceProvenance parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new SourceProvenance(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/StorageSource.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/StorageSource.java index 8bb494df..10190454 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/StorageSource.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/StorageSource.java @@ -53,64 +53,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private StorageSource( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - bucket_ = s; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - object_ = s; - break; - } - case 24: - { - generation_ = input.readInt64(); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_StorageSource_descriptor; @@ -274,7 +216,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (generation_ != 0L) { output.writeInt64(3, generation_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -292,7 +234,7 @@ public int getSerializedSize() { if (generation_ != 0L) { size += com.google.protobuf.CodedOutputStream.computeInt64Size(3, generation_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -310,7 +252,7 @@ public boolean equals(final java.lang.Object obj) { if (!getBucket().equals(other.getBucket())) return false; if (!getObject().equals(other.getObject())) return false; if (getGeneration() != other.getGeneration()) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -327,7 +269,7 @@ public int hashCode() { hash = (53 * hash) + getObject().hashCode(); hash = (37 * hash) + GENERATION_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getGeneration()); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -456,17 +398,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.StorageSource.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -568,7 +503,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.StorageSource other) { if (other.getGeneration() != 0L) { setGeneration(other.getGeneration()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -583,17 +518,49 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.StorageSource parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + bucket_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + object_ = input.readStringRequireUtf8(); + + break; + } // case 18 + case 24: + { + generation_ = input.readInt64(); + + break; + } // case 24 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.cloudbuild.v1.StorageSource) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -916,7 +883,18 @@ public StorageSource parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new StorageSource(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/StorageSourceManifest.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/StorageSourceManifest.java index b01adb60..759ecdf3 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/StorageSourceManifest.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/StorageSourceManifest.java @@ -55,64 +55,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private StorageSourceManifest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - bucket_ = s; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - object_ = s; - break; - } - case 24: - { - generation_ = input.readInt64(); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_StorageSourceManifest_descriptor; @@ -274,7 +216,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (generation_ != 0L) { output.writeInt64(3, generation_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -292,7 +234,7 @@ public int getSerializedSize() { if (generation_ != 0L) { size += com.google.protobuf.CodedOutputStream.computeInt64Size(3, generation_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -311,7 +253,7 @@ public boolean equals(final java.lang.Object obj) { if (!getBucket().equals(other.getBucket())) return false; if (!getObject().equals(other.getObject())) return false; if (getGeneration() != other.getGeneration()) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -328,7 +270,7 @@ public int hashCode() { hash = (53 * hash) + getObject().hashCode(); hash = (37 * hash) + GENERATION_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getGeneration()); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -459,17 +401,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.StorageSourceManifest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -571,7 +506,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.StorageSourceManifest other) { if (other.getGeneration() != 0L) { setGeneration(other.getGeneration()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -586,17 +521,49 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.StorageSourceManifest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + bucket_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + object_ = input.readStringRequireUtf8(); + + break; + } // case 18 + case 24: + { + generation_ = input.readInt64(); + + break; + } // case 24 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.cloudbuild.v1.StorageSourceManifest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -914,7 +881,18 @@ public StorageSourceManifest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new StorageSourceManifest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/TimeSpan.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/TimeSpan.java index b8e69344..6cb27f99 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/TimeSpan.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/TimeSpan.java @@ -50,75 +50,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private TimeSpan( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (startTime_ != null) { - subBuilder = startTime_.toBuilder(); - } - startTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(startTime_); - startTime_ = subBuilder.buildPartial(); - } - - break; - } - case 18: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (endTime_ != null) { - subBuilder = endTime_.toBuilder(); - } - endTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(endTime_); - endTime_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_TimeSpan_descriptor; @@ -246,7 +177,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (endTime_ != null) { output.writeMessage(2, getEndTime()); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -261,7 +192,7 @@ public int getSerializedSize() { if (endTime_ != null) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getEndTime()); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -284,7 +215,7 @@ public boolean equals(final java.lang.Object obj) { if (hasEndTime()) { if (!getEndTime().equals(other.getEndTime())) return false; } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -303,7 +234,7 @@ public int hashCode() { hash = (37 * hash) + END_TIME_FIELD_NUMBER; hash = (53 * hash) + getEndTime().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -431,17 +362,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.TimeSpan.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -550,7 +474,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.TimeSpan other) { if (other.hasEndTime()) { mergeEndTime(other.getEndTime()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -565,17 +489,43 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.TimeSpan parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage(getStartTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 10 + case 18: + { + input.readMessage(getEndTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.cloudbuild.v1.TimeSpan) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -969,7 +919,18 @@ public TimeSpan parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new TimeSpan(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/UpdateBuildTriggerRequest.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/UpdateBuildTriggerRequest.java index ec4d261c..cb3c6155 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/UpdateBuildTriggerRequest.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/UpdateBuildTriggerRequest.java @@ -53,75 +53,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private UpdateBuildTriggerRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - projectId_ = s; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - triggerId_ = s; - break; - } - case 26: - { - com.google.cloudbuild.v1.BuildTrigger.Builder subBuilder = null; - if (trigger_ != null) { - subBuilder = trigger_.toBuilder(); - } - trigger_ = - input.readMessage( - com.google.cloudbuild.v1.BuildTrigger.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(trigger_); - trigger_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_UpdateBuildTriggerRequest_descriptor; @@ -310,7 +241,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (trigger_ != null) { output.writeMessage(3, getTrigger()); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -328,7 +259,7 @@ public int getSerializedSize() { if (trigger_ != null) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getTrigger()); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -350,7 +281,7 @@ public boolean equals(final java.lang.Object obj) { if (hasTrigger()) { if (!getTrigger().equals(other.getTrigger())) return false; } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -369,7 +300,7 @@ public int hashCode() { hash = (37 * hash) + TRIGGER_FIELD_NUMBER; hash = (53 * hash) + getTrigger().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -498,17 +429,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.UpdateBuildTriggerRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -619,7 +543,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.UpdateBuildTriggerRequest othe if (other.hasTrigger()) { mergeTrigger(other.getTrigger()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -634,18 +558,49 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.UpdateBuildTriggerRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + projectId_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + triggerId_ = input.readStringRequireUtf8(); + + break; + } // case 18 + case 26: + { + input.readMessage(getTriggerFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloudbuild.v1.UpdateBuildTriggerRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1096,7 +1051,18 @@ public UpdateBuildTriggerRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new UpdateBuildTriggerRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/UpdateWorkerPoolOperationMetadata.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/UpdateWorkerPoolOperationMetadata.java index 32034363..0fe35ae1 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/UpdateWorkerPoolOperationMetadata.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/UpdateWorkerPoolOperationMetadata.java @@ -53,82 +53,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private UpdateWorkerPoolOperationMetadata( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - workerPool_ = s; - break; - } - case 18: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (createTime_ != null) { - subBuilder = createTime_.toBuilder(); - } - createTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(createTime_); - createTime_ = subBuilder.buildPartial(); - } - - break; - } - case 26: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (completeTime_ != null) { - subBuilder = completeTime_.toBuilder(); - } - completeTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(completeTime_); - completeTime_ = subBuilder.buildPartial(); - } - - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_UpdateWorkerPoolOperationMetadata_descriptor; @@ -314,7 +238,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (completeTime_ != null) { output.writeMessage(3, getCompleteTime()); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -332,7 +256,7 @@ public int getSerializedSize() { if (completeTime_ != null) { size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getCompleteTime()); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -357,7 +281,7 @@ public boolean equals(final java.lang.Object obj) { if (hasCompleteTime()) { if (!getCompleteTime().equals(other.getCompleteTime())) return false; } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -378,7 +302,7 @@ public int hashCode() { hash = (37 * hash) + COMPLETE_TIME_FIELD_NUMBER; hash = (53 * hash) + getCompleteTime().hashCode(); } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -508,17 +432,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.UpdateWorkerPoolOperationMetadata.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -636,7 +553,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.UpdateWorkerPoolOperationMetad if (other.hasCompleteTime()) { mergeCompleteTime(other.getCompleteTime()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -651,18 +568,49 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.UpdateWorkerPoolOperationMetadata parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + workerPool_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + input.readMessage(getCreateTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 18 + case 26: + { + input.readMessage(getCompleteTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 26 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = - (com.google.cloudbuild.v1.UpdateWorkerPoolOperationMetadata) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1182,7 +1130,18 @@ public UpdateWorkerPoolOperationMetadata parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new UpdateWorkerPoolOperationMetadata(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/UpdateWorkerPoolRequest.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/UpdateWorkerPoolRequest.java index c234b2d3..e3b2dd15 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/UpdateWorkerPoolRequest.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/UpdateWorkerPoolRequest.java @@ -50,81 +50,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private UpdateWorkerPoolRequest( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - com.google.cloudbuild.v1.WorkerPool.Builder subBuilder = null; - if (workerPool_ != null) { - subBuilder = workerPool_.toBuilder(); - } - workerPool_ = - input.readMessage( - com.google.cloudbuild.v1.WorkerPool.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(workerPool_); - workerPool_ = subBuilder.buildPartial(); - } - - break; - } - case 18: - { - com.google.protobuf.FieldMask.Builder subBuilder = null; - if (updateMask_ != null) { - subBuilder = updateMask_.toBuilder(); - } - updateMask_ = - input.readMessage(com.google.protobuf.FieldMask.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(updateMask_); - updateMask_ = subBuilder.buildPartial(); - } - - break; - } - case 32: - { - validateOnly_ = input.readBool(); - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_UpdateWorkerPoolRequest_descriptor; @@ -288,7 +213,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (validateOnly_ != false) { output.writeBool(4, validateOnly_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -306,7 +231,7 @@ public int getSerializedSize() { if (validateOnly_ != false) { size += com.google.protobuf.CodedOutputStream.computeBoolSize(4, validateOnly_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -331,7 +256,7 @@ public boolean equals(final java.lang.Object obj) { if (!getUpdateMask().equals(other.getUpdateMask())) return false; } if (getValidateOnly() != other.getValidateOnly()) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -352,7 +277,7 @@ public int hashCode() { } hash = (37 * hash) + VALIDATE_ONLY_FIELD_NUMBER; hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getValidateOnly()); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -481,17 +406,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.UpdateWorkerPoolRequest.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -608,7 +526,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.UpdateWorkerPoolRequest other) if (other.getValidateOnly() != false) { setValidateOnly(other.getValidateOnly()); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -623,17 +541,49 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.UpdateWorkerPoolRequest parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + input.readMessage(getWorkerPoolFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 10 + case 18: + { + input.readMessage(getUpdateMaskFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 18 + case 32: + { + validateOnly_ = input.readBool(); + + break; + } // case 32 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.cloudbuild.v1.UpdateWorkerPoolRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1128,7 +1078,18 @@ public UpdateWorkerPoolRequest parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new UpdateWorkerPoolRequest(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Volume.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Volume.java index 182cf435..68bc60e7 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Volume.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Volume.java @@ -54,59 +54,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private Volume( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - path_ = s; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_Volume_descriptor; @@ -247,7 +194,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(path_)) { com.google.protobuf.GeneratedMessageV3.writeString(output, 2, path_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -262,7 +209,7 @@ public int getSerializedSize() { if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(path_)) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, path_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -279,7 +226,7 @@ public boolean equals(final java.lang.Object obj) { if (!getName().equals(other.getName())) return false; if (!getPath().equals(other.getPath())) return false; - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -294,7 +241,7 @@ public int hashCode() { hash = (53 * hash) + getName().hashCode(); hash = (37 * hash) + PATH_FIELD_NUMBER; hash = (53 * hash) + getPath().hashCode(); - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -422,17 +369,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.Volume.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -527,7 +467,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.Volume other) { path_ = other.path_; onChanged(); } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -542,17 +482,43 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.Volume parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + path_ = input.readStringRequireUtf8(); + + break; + } // case 18 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.cloudbuild.v1.Volume) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -820,7 +786,18 @@ public Volume parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new Volume(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/WebhookConfig.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/WebhookConfig.java index fcc0064a..6ea37005 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/WebhookConfig.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/WebhookConfig.java @@ -53,59 +53,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private WebhookConfig( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 26: - { - java.lang.String s = input.readStringRequireUtf8(); - authMethodCase_ = 3; - authMethod_ = s; - break; - } - case 32: - { - int rawValue = input.readEnum(); - - state_ = rawValue; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_WebhookConfig_descriptor; @@ -457,7 +404,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (state_ != com.google.cloudbuild.v1.WebhookConfig.State.STATE_UNSPECIFIED.getNumber()) { output.writeEnum(4, state_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -472,7 +419,7 @@ public int getSerializedSize() { if (state_ != com.google.cloudbuild.v1.WebhookConfig.State.STATE_UNSPECIFIED.getNumber()) { size += com.google.protobuf.CodedOutputStream.computeEnumSize(4, state_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -496,7 +443,7 @@ public boolean equals(final java.lang.Object obj) { case 0: default: } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -517,7 +464,7 @@ public int hashCode() { case 0: default: } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -647,17 +594,10 @@ public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { } // Construct using com.google.cloudbuild.v1.WebhookConfig.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -764,7 +704,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.WebhookConfig other) { break; } } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -779,17 +719,44 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.WebhookConfig parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 26: + { + java.lang.String s = input.readStringRequireUtf8(); + authMethodCase_ = 3; + authMethod_ = s; + break; + } // case 26 + case 32: + { + state_ = input.readEnum(); + + break; + } // case 32 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.cloudbuild.v1.WebhookConfig) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -1081,7 +1048,18 @@ public WebhookConfig parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new WebhookConfig(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/WorkerPool.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/WorkerPool.java index 5e49521c..8f38b614 100644 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/WorkerPool.java +++ b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/WorkerPool.java @@ -66,157 +66,6 @@ public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } - private WorkerPool( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - this(); - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - - name_ = s; - break; - } - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - - displayName_ = s; - break; - } - case 26: - { - java.lang.String s = input.readStringRequireUtf8(); - - uid_ = s; - break; - } - case 34: - { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - annotations_ = - com.google.protobuf.MapField.newMapField( - AnnotationsDefaultEntryHolder.defaultEntry); - mutable_bitField0_ |= 0x00000001; - } - com.google.protobuf.MapEntry annotations__ = - input.readMessage( - AnnotationsDefaultEntryHolder.defaultEntry.getParserForType(), - extensionRegistry); - annotations_.getMutableMap().put(annotations__.getKey(), annotations__.getValue()); - break; - } - case 42: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (createTime_ != null) { - subBuilder = createTime_.toBuilder(); - } - createTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(createTime_); - createTime_ = subBuilder.buildPartial(); - } - - break; - } - case 50: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (updateTime_ != null) { - subBuilder = updateTime_.toBuilder(); - } - updateTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(updateTime_); - updateTime_ = subBuilder.buildPartial(); - } - - break; - } - case 58: - { - com.google.protobuf.Timestamp.Builder subBuilder = null; - if (deleteTime_ != null) { - subBuilder = deleteTime_.toBuilder(); - } - deleteTime_ = - input.readMessage(com.google.protobuf.Timestamp.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(deleteTime_); - deleteTime_ = subBuilder.buildPartial(); - } - - break; - } - case 64: - { - int rawValue = input.readEnum(); - - state_ = rawValue; - break; - } - case 90: - { - java.lang.String s = input.readStringRequireUtf8(); - - etag_ = s; - break; - } - case 98: - { - com.google.cloudbuild.v1.PrivatePoolV1Config.Builder subBuilder = null; - if (configCase_ == 12) { - subBuilder = ((com.google.cloudbuild.v1.PrivatePoolV1Config) config_).toBuilder(); - } - config_ = - input.readMessage( - com.google.cloudbuild.v1.PrivatePoolV1Config.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom((com.google.cloudbuild.v1.PrivatePoolV1Config) config_); - config_ = subBuilder.buildPartial(); - } - configCase_ = 12; - break; - } - default: - { - if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { - done = true; - } - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.cloudbuild.v1.Cloudbuild .internal_static_google_devtools_cloudbuild_v1_WorkerPool_descriptor; @@ -1092,7 +941,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io if (configCase_ == 12) { output.writeMessage(12, (com.google.cloudbuild.v1.PrivatePoolV1Config) config_); } - unknownFields.writeTo(output); + getUnknownFields().writeTo(output); } @java.lang.Override @@ -1140,7 +989,7 @@ public int getSerializedSize() { com.google.protobuf.CodedOutputStream.computeMessageSize( 12, (com.google.cloudbuild.v1.PrivatePoolV1Config) config_); } - size += unknownFields.getSerializedSize(); + size += getUnknownFields().getSerializedSize(); memoizedSize = size; return size; } @@ -1181,7 +1030,7 @@ public boolean equals(final java.lang.Object obj) { case 0: default: } - if (!unknownFields.equals(other.unknownFields)) return false; + if (!getUnknownFields().equals(other.getUnknownFields())) return false; return true; } @@ -1226,7 +1075,7 @@ public int hashCode() { case 0: default: } - hash = (29 * hash) + unknownFields.hashCode(); + hash = (29 * hash) + getUnknownFields().hashCode(); memoizedHashCode = hash; return hash; } @@ -1384,17 +1233,10 @@ protected com.google.protobuf.MapField internalGetMutableMapField(int number) { } // Construct using com.google.cloudbuild.v1.WorkerPool.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } + private Builder() {} private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); - maybeForceBuilderInitialization(); - } - - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } @java.lang.Override @@ -1427,6 +1269,9 @@ public Builder clear() { } state_ = 0; + if (privatePoolV1ConfigBuilder_ != null) { + privatePoolV1ConfigBuilder_.clear(); + } etag_ = ""; configCase_ = 0; @@ -1577,7 +1422,7 @@ public Builder mergeFrom(com.google.cloudbuild.v1.WorkerPool other) { break; } } - this.mergeUnknownFields(other.unknownFields); + this.mergeUnknownFields(other.getUnknownFields()); onChanged(); return this; } @@ -1592,17 +1437,97 @@ public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - com.google.cloudbuild.v1.WorkerPool parsedMessage = null; + if (extensionRegistry == null) { + throw new java.lang.NullPointerException(); + } try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); + boolean done = false; + while (!done) { + int tag = input.readTag(); + switch (tag) { + case 0: + done = true; + break; + case 10: + { + name_ = input.readStringRequireUtf8(); + + break; + } // case 10 + case 18: + { + displayName_ = input.readStringRequireUtf8(); + + break; + } // case 18 + case 26: + { + uid_ = input.readStringRequireUtf8(); + + break; + } // case 26 + case 34: + { + com.google.protobuf.MapEntry annotations__ = + input.readMessage( + AnnotationsDefaultEntryHolder.defaultEntry.getParserForType(), + extensionRegistry); + internalGetMutableAnnotations() + .getMutableMap() + .put(annotations__.getKey(), annotations__.getValue()); + break; + } // case 34 + case 42: + { + input.readMessage(getCreateTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 42 + case 50: + { + input.readMessage(getUpdateTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 50 + case 58: + { + input.readMessage(getDeleteTimeFieldBuilder().getBuilder(), extensionRegistry); + + break; + } // case 58 + case 64: + { + state_ = input.readEnum(); + + break; + } // case 64 + case 90: + { + etag_ = input.readStringRequireUtf8(); + + break; + } // case 90 + case 98: + { + input.readMessage( + getPrivatePoolV1ConfigFieldBuilder().getBuilder(), extensionRegistry); + configCase_ = 12; + break; + } // case 98 + default: + { + if (!super.parseUnknownField(input, extensionRegistry, tag)) { + done = true; // was an endgroup tag + } + break; + } // default: + } // switch (tag) + } // while (!done) } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (com.google.cloudbuild.v1.WorkerPool) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } + onChanged(); + } // finally return this; } @@ -3222,7 +3147,18 @@ public WorkerPool parsePartialFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { - return new WorkerPool(input, extensionRegistry); + Builder builder = newBuilder(); + try { + builder.mergeFrom(input, extensionRegistry); + } catch (com.google.protobuf.InvalidProtocolBufferException e) { + throw e.setUnfinishedMessage(builder.buildPartial()); + } catch (com.google.protobuf.UninitializedMessageException e) { + throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); + } catch (java.io.IOException e) { + throw new com.google.protobuf.InvalidProtocolBufferException(e) + .setUnfinishedMessage(builder.buildPartial()); + } + return builder.buildPartial(); } }; From cf3e07ad4c1cdbf96006a3eb4c502214336e9e92 Mon Sep 17 00:00:00 2001 From: "release-please[bot]" <55107282+release-please[bot]@users.noreply.github.com> Date: Tue, 4 Oct 2022 20:50:13 +0000 Subject: [PATCH 30/38] chore(main): release 3.5.6-SNAPSHOT (#811) :robot: I have created a release *beep* *boop* --- ### Updating meta-information for bleeding-edge SNAPSHOT release. --- This PR was generated with [Release Please](https://togithub.com/googleapis/release-please). See [documentation](https://togithub.com/googleapis/release-please#release-please). --- google-cloud-build-bom/pom.xml | 8 ++++---- google-cloud-build/pom.xml | 4 ++-- grpc-google-cloud-build-v1/pom.xml | 4 ++-- pom.xml | 8 ++++---- proto-google-cloud-build-v1/pom.xml | 4 ++-- versions.txt | 6 +++--- 6 files changed, 17 insertions(+), 17 deletions(-) diff --git a/google-cloud-build-bom/pom.xml b/google-cloud-build-bom/pom.xml index 8b1f498c..e46684e8 100644 --- a/google-cloud-build-bom/pom.xml +++ b/google-cloud-build-bom/pom.xml @@ -3,7 +3,7 @@ 4.0.0 com.google.cloud google-cloud-build-bom - 3.5.5 + 3.5.6-SNAPSHOT pom com.google.cloud @@ -52,17 +52,17 @@ com.google.cloud google-cloud-build - 3.5.5 + 3.5.6-SNAPSHOT com.google.api.grpc grpc-google-cloud-build-v1 - 3.5.5 + 3.5.6-SNAPSHOT com.google.api.grpc proto-google-cloud-build-v1 - 3.5.5 + 3.5.6-SNAPSHOT
diff --git a/google-cloud-build/pom.xml b/google-cloud-build/pom.xml index 033dcdcc..30ecf7a7 100644 --- a/google-cloud-build/pom.xml +++ b/google-cloud-build/pom.xml @@ -3,7 +3,7 @@ 4.0.0 com.google.cloud google-cloud-build - 3.5.5 + 3.5.6-SNAPSHOT jar Google Cloud Build https://github.com/googleapis/java-cloudbuild @@ -13,7 +13,7 @@ com.google.cloud google-cloud-build-parent - 3.5.5 + 3.5.6-SNAPSHOT google-cloud-build diff --git a/grpc-google-cloud-build-v1/pom.xml b/grpc-google-cloud-build-v1/pom.xml index dc6654d4..70b43b95 100644 --- a/grpc-google-cloud-build-v1/pom.xml +++ b/grpc-google-cloud-build-v1/pom.xml @@ -4,13 +4,13 @@ 4.0.0 com.google.api.grpc grpc-google-cloud-build-v1 - 3.5.5 + 3.5.6-SNAPSHOT grpc-google-cloud-build-v1 GRPC library for grpc-google-cloud-build-v1 com.google.cloud google-cloud-build-parent - 3.5.5 + 3.5.6-SNAPSHOT diff --git a/pom.xml b/pom.xml index 5404320d..4aa37039 100644 --- a/pom.xml +++ b/pom.xml @@ -4,7 +4,7 @@ com.google.cloud google-cloud-build-parent pom - 3.5.5 + 3.5.6-SNAPSHOT Google Cloud Build Parent https://github.com/googleapis/java-cloudbuild @@ -62,17 +62,17 @@ com.google.api.grpc proto-google-cloud-build-v1 - 3.5.5 + 3.5.6-SNAPSHOT com.google.cloud google-cloud-build - 3.5.5 + 3.5.6-SNAPSHOT com.google.api.grpc grpc-google-cloud-build-v1 - 3.5.5 + 3.5.6-SNAPSHOT diff --git a/proto-google-cloud-build-v1/pom.xml b/proto-google-cloud-build-v1/pom.xml index 172b95de..1b6de4c2 100644 --- a/proto-google-cloud-build-v1/pom.xml +++ b/proto-google-cloud-build-v1/pom.xml @@ -4,13 +4,13 @@ 4.0.0 com.google.api.grpc proto-google-cloud-build-v1 - 3.5.5 + 3.5.6-SNAPSHOT proto-google-cloud-build-v1 PROTO library for proto-google-cloud-build-v1 com.google.cloud google-cloud-build-parent - 3.5.5 + 3.5.6-SNAPSHOT diff --git a/versions.txt b/versions.txt index 905b620b..ec4141a7 100644 --- a/versions.txt +++ b/versions.txt @@ -1,6 +1,6 @@ # Format: # module:released-version:current-version -google-cloud-build:3.5.5:3.5.5 -grpc-google-cloud-build-v1:3.5.5:3.5.5 -proto-google-cloud-build-v1:3.5.5:3.5.5 +google-cloud-build:3.5.5:3.5.6-SNAPSHOT +grpc-google-cloud-build-v1:3.5.5:3.5.6-SNAPSHOT +proto-google-cloud-build-v1:3.5.5:3.5.6-SNAPSHOT From 2a9e358cd64329bda13d6ce64fffff1c415fb967 Mon Sep 17 00:00:00 2001 From: "release-please[bot]" <55107282+release-please[bot]@users.noreply.github.com> Date: Tue, 4 Oct 2022 21:04:15 +0000 Subject: [PATCH 31/38] chore(main): release 3.5.6 (#815) :robot: I have created a release *beep* *boop* --- ## [3.5.6](https://togithub.com/googleapis/java-cloudbuild/compare/v3.5.5...v3.5.6) (2022-10-04) ### Dependencies * Update dependency com.google.cloud:google-cloud-shared-dependencies to v3.0.4 ([#814](https://togithub.com/googleapis/java-cloudbuild/issues/814)) ([5cbf28b](https://togithub.com/googleapis/java-cloudbuild/commit/5cbf28b9c9321111d6dc811d36d59cd4635e7c9b)) --- This PR was generated with [Release Please](https://togithub.com/googleapis/release-please). See [documentation](https://togithub.com/googleapis/release-please#release-please). --- CHANGELOG.md | 7 +++++++ google-cloud-build-bom/pom.xml | 8 ++++---- google-cloud-build/pom.xml | 4 ++-- grpc-google-cloud-build-v1/pom.xml | 4 ++-- pom.xml | 8 ++++---- proto-google-cloud-build-v1/pom.xml | 4 ++-- versions.txt | 6 +++--- 7 files changed, 24 insertions(+), 17 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index daa7640b..34e40d01 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,12 @@ # Changelog +## [3.5.6](https://github.com/googleapis/java-cloudbuild/compare/v3.5.5...v3.5.6) (2022-10-04) + + +### Dependencies + +* Update dependency com.google.cloud:google-cloud-shared-dependencies to v3.0.4 ([#814](https://github.com/googleapis/java-cloudbuild/issues/814)) ([5cbf28b](https://github.com/googleapis/java-cloudbuild/commit/5cbf28b9c9321111d6dc811d36d59cd4635e7c9b)) + ## [3.5.5](https://github.com/googleapis/java-cloudbuild/compare/v3.5.4...v3.5.5) (2022-09-27) diff --git a/google-cloud-build-bom/pom.xml b/google-cloud-build-bom/pom.xml index e46684e8..06dc5b66 100644 --- a/google-cloud-build-bom/pom.xml +++ b/google-cloud-build-bom/pom.xml @@ -3,7 +3,7 @@ 4.0.0 com.google.cloud google-cloud-build-bom - 3.5.6-SNAPSHOT + 3.5.6 pom com.google.cloud @@ -52,17 +52,17 @@ com.google.cloud google-cloud-build - 3.5.6-SNAPSHOT + 3.5.6 com.google.api.grpc grpc-google-cloud-build-v1 - 3.5.6-SNAPSHOT + 3.5.6 com.google.api.grpc proto-google-cloud-build-v1 - 3.5.6-SNAPSHOT + 3.5.6 diff --git a/google-cloud-build/pom.xml b/google-cloud-build/pom.xml index 30ecf7a7..09eed651 100644 --- a/google-cloud-build/pom.xml +++ b/google-cloud-build/pom.xml @@ -3,7 +3,7 @@ 4.0.0 com.google.cloud google-cloud-build - 3.5.6-SNAPSHOT + 3.5.6 jar Google Cloud Build https://github.com/googleapis/java-cloudbuild @@ -13,7 +13,7 @@ com.google.cloud google-cloud-build-parent - 3.5.6-SNAPSHOT + 3.5.6 google-cloud-build diff --git a/grpc-google-cloud-build-v1/pom.xml b/grpc-google-cloud-build-v1/pom.xml index 70b43b95..71c764ed 100644 --- a/grpc-google-cloud-build-v1/pom.xml +++ b/grpc-google-cloud-build-v1/pom.xml @@ -4,13 +4,13 @@ 4.0.0 com.google.api.grpc grpc-google-cloud-build-v1 - 3.5.6-SNAPSHOT + 3.5.6 grpc-google-cloud-build-v1 GRPC library for grpc-google-cloud-build-v1 com.google.cloud google-cloud-build-parent - 3.5.6-SNAPSHOT + 3.5.6 diff --git a/pom.xml b/pom.xml index 4aa37039..edd90470 100644 --- a/pom.xml +++ b/pom.xml @@ -4,7 +4,7 @@ com.google.cloud google-cloud-build-parent pom - 3.5.6-SNAPSHOT + 3.5.6 Google Cloud Build Parent https://github.com/googleapis/java-cloudbuild @@ -62,17 +62,17 @@ com.google.api.grpc proto-google-cloud-build-v1 - 3.5.6-SNAPSHOT + 3.5.6 com.google.cloud google-cloud-build - 3.5.6-SNAPSHOT + 3.5.6 com.google.api.grpc grpc-google-cloud-build-v1 - 3.5.6-SNAPSHOT + 3.5.6 diff --git a/proto-google-cloud-build-v1/pom.xml b/proto-google-cloud-build-v1/pom.xml index 1b6de4c2..a2a26746 100644 --- a/proto-google-cloud-build-v1/pom.xml +++ b/proto-google-cloud-build-v1/pom.xml @@ -4,13 +4,13 @@ 4.0.0 com.google.api.grpc proto-google-cloud-build-v1 - 3.5.6-SNAPSHOT + 3.5.6 proto-google-cloud-build-v1 PROTO library for proto-google-cloud-build-v1 com.google.cloud google-cloud-build-parent - 3.5.6-SNAPSHOT + 3.5.6 diff --git a/versions.txt b/versions.txt index ec4141a7..fe5d9122 100644 --- a/versions.txt +++ b/versions.txt @@ -1,6 +1,6 @@ # Format: # module:released-version:current-version -google-cloud-build:3.5.5:3.5.6-SNAPSHOT -grpc-google-cloud-build-v1:3.5.5:3.5.6-SNAPSHOT -proto-google-cloud-build-v1:3.5.5:3.5.6-SNAPSHOT +google-cloud-build:3.5.6:3.5.6 +grpc-google-cloud-build-v1:3.5.6:3.5.6 +proto-google-cloud-build-v1:3.5.6:3.5.6 From 031a59a66e35d928c67c23a4c12e35d56c210945 Mon Sep 17 00:00:00 2001 From: "release-please[bot]" <55107282+release-please[bot]@users.noreply.github.com> Date: Tue, 4 Oct 2022 21:18:13 +0000 Subject: [PATCH 32/38] chore(main): release 3.5.7-SNAPSHOT (#816) :robot: I have created a release *beep* *boop* --- ### Updating meta-information for bleeding-edge SNAPSHOT release. --- This PR was generated with [Release Please](https://togithub.com/googleapis/release-please). See [documentation](https://togithub.com/googleapis/release-please#release-please). --- google-cloud-build-bom/pom.xml | 8 ++++---- google-cloud-build/pom.xml | 4 ++-- grpc-google-cloud-build-v1/pom.xml | 4 ++-- pom.xml | 8 ++++---- proto-google-cloud-build-v1/pom.xml | 4 ++-- versions.txt | 6 +++--- 6 files changed, 17 insertions(+), 17 deletions(-) diff --git a/google-cloud-build-bom/pom.xml b/google-cloud-build-bom/pom.xml index 06dc5b66..5ca4aa7f 100644 --- a/google-cloud-build-bom/pom.xml +++ b/google-cloud-build-bom/pom.xml @@ -3,7 +3,7 @@ 4.0.0 com.google.cloud google-cloud-build-bom - 3.5.6 + 3.5.7-SNAPSHOT pom com.google.cloud @@ -52,17 +52,17 @@ com.google.cloud google-cloud-build - 3.5.6 + 3.5.7-SNAPSHOT com.google.api.grpc grpc-google-cloud-build-v1 - 3.5.6 + 3.5.7-SNAPSHOT com.google.api.grpc proto-google-cloud-build-v1 - 3.5.6 + 3.5.7-SNAPSHOT diff --git a/google-cloud-build/pom.xml b/google-cloud-build/pom.xml index 09eed651..6a1e0dac 100644 --- a/google-cloud-build/pom.xml +++ b/google-cloud-build/pom.xml @@ -3,7 +3,7 @@ 4.0.0 com.google.cloud google-cloud-build - 3.5.6 + 3.5.7-SNAPSHOT jar Google Cloud Build https://github.com/googleapis/java-cloudbuild @@ -13,7 +13,7 @@ com.google.cloud google-cloud-build-parent - 3.5.6 + 3.5.7-SNAPSHOT google-cloud-build diff --git a/grpc-google-cloud-build-v1/pom.xml b/grpc-google-cloud-build-v1/pom.xml index 71c764ed..f58e39ac 100644 --- a/grpc-google-cloud-build-v1/pom.xml +++ b/grpc-google-cloud-build-v1/pom.xml @@ -4,13 +4,13 @@ 4.0.0 com.google.api.grpc grpc-google-cloud-build-v1 - 3.5.6 + 3.5.7-SNAPSHOT grpc-google-cloud-build-v1 GRPC library for grpc-google-cloud-build-v1 com.google.cloud google-cloud-build-parent - 3.5.6 + 3.5.7-SNAPSHOT diff --git a/pom.xml b/pom.xml index edd90470..a3455ff7 100644 --- a/pom.xml +++ b/pom.xml @@ -4,7 +4,7 @@ com.google.cloud google-cloud-build-parent pom - 3.5.6 + 3.5.7-SNAPSHOT Google Cloud Build Parent https://github.com/googleapis/java-cloudbuild @@ -62,17 +62,17 @@ com.google.api.grpc proto-google-cloud-build-v1 - 3.5.6 + 3.5.7-SNAPSHOT com.google.cloud google-cloud-build - 3.5.6 + 3.5.7-SNAPSHOT com.google.api.grpc grpc-google-cloud-build-v1 - 3.5.6 + 3.5.7-SNAPSHOT diff --git a/proto-google-cloud-build-v1/pom.xml b/proto-google-cloud-build-v1/pom.xml index a2a26746..81ea12f8 100644 --- a/proto-google-cloud-build-v1/pom.xml +++ b/proto-google-cloud-build-v1/pom.xml @@ -4,13 +4,13 @@ 4.0.0 com.google.api.grpc proto-google-cloud-build-v1 - 3.5.6 + 3.5.7-SNAPSHOT proto-google-cloud-build-v1 PROTO library for proto-google-cloud-build-v1 com.google.cloud google-cloud-build-parent - 3.5.6 + 3.5.7-SNAPSHOT diff --git a/versions.txt b/versions.txt index fe5d9122..da84c6d1 100644 --- a/versions.txt +++ b/versions.txt @@ -1,6 +1,6 @@ # Format: # module:released-version:current-version -google-cloud-build:3.5.6:3.5.6 -grpc-google-cloud-build-v1:3.5.6:3.5.6 -proto-google-cloud-build-v1:3.5.6:3.5.6 +google-cloud-build:3.5.6:3.5.7-SNAPSHOT +grpc-google-cloud-build-v1:3.5.6:3.5.7-SNAPSHOT +proto-google-cloud-build-v1:3.5.6:3.5.7-SNAPSHOT From da53d4bf94df1dd35751b3c9a4783ead7fcd46a1 Mon Sep 17 00:00:00 2001 From: WhiteSource Renovate Date: Thu, 6 Oct 2022 03:20:24 +0200 Subject: [PATCH 33/38] chore(deps): update dependency com.google.cloud:google-cloud-build to v3.5.6 (#817) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit [![Mend Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com) This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [com.google.cloud:google-cloud-build](https://togithub.com/googleapis/java-cloudbuild) | `3.5.5` -> `3.5.6` | [![age](https://badges.renovateapi.com/packages/maven/com.google.cloud:google-cloud-build/3.5.6/age-slim)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://badges.renovateapi.com/packages/maven/com.google.cloud:google-cloud-build/3.5.6/adoption-slim)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://badges.renovateapi.com/packages/maven/com.google.cloud:google-cloud-build/3.5.6/compatibility-slim/3.5.5)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://badges.renovateapi.com/packages/maven/com.google.cloud:google-cloud-build/3.5.6/confidence-slim/3.5.5)](https://docs.renovatebot.com/merge-confidence/) | --- ### Configuration 📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Renovate will not automatically rebase this PR, because other commits have been found. 🔕 **Ignore**: Close this PR and you won't be reminded about these updates again. --- - [ ] If you want to rebase/retry this PR, click this checkbox. ⚠ **Warning**: custom changes will be lost. --- This PR has been generated by [Mend Renovate](https://www.mend.io/free-developer-tools/renovate/). View repository job log [here](https://app.renovatebot.com/dashboard#github/googleapis/java-cloudbuild). --- README.md | 6 +++--- samples/install-without-bom/pom.xml | 2 +- samples/snapshot/pom.xml | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/README.md b/README.md index 0486aea1..d1cb0186 100644 --- a/README.md +++ b/README.md @@ -19,20 +19,20 @@ If you are using Maven, add this to your pom.xml file: com.google.cloud google-cloud-build - 3.5.5 + 3.5.6 ``` If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-build:3.5.5' +implementation 'com.google.cloud:google-cloud-build:3.5.6' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-build" % "3.5.5" +libraryDependencies += "com.google.cloud" % "google-cloud-build" % "3.5.6" ``` ## Authentication diff --git a/samples/install-without-bom/pom.xml b/samples/install-without-bom/pom.xml index bf8e5f6e..a92099c8 100644 --- a/samples/install-without-bom/pom.xml +++ b/samples/install-without-bom/pom.xml @@ -29,7 +29,7 @@ com.google.cloud google-cloud-build - 3.5.5 + 3.5.6 diff --git a/samples/snapshot/pom.xml b/samples/snapshot/pom.xml index 9b0f7e82..4b558282 100644 --- a/samples/snapshot/pom.xml +++ b/samples/snapshot/pom.xml @@ -28,7 +28,7 @@ com.google.cloud google-cloud-build - 3.5.5 + 3.5.6 From 9f04f61c8d5751692bc7c5daa3c796fc7204b1ad Mon Sep 17 00:00:00 2001 From: WhiteSource Renovate Date: Fri, 7 Oct 2022 20:00:24 +0200 Subject: [PATCH 34/38] chore(deps): update dependency com.google.cloud:libraries-bom to v26.1.3 (#818) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit [![Mend Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com) This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [com.google.cloud:libraries-bom](https://cloud.google.com/java/docs/bom) ([source](https://togithub.com/googleapis/java-cloud-bom)) | `26.1.2` -> `26.1.3` | [![age](https://badges.renovateapi.com/packages/maven/com.google.cloud:libraries-bom/26.1.3/age-slim)](https://docs.renovatebot.com/merge-confidence/) | [![adoption](https://badges.renovateapi.com/packages/maven/com.google.cloud:libraries-bom/26.1.3/adoption-slim)](https://docs.renovatebot.com/merge-confidence/) | [![passing](https://badges.renovateapi.com/packages/maven/com.google.cloud:libraries-bom/26.1.3/compatibility-slim/26.1.2)](https://docs.renovatebot.com/merge-confidence/) | [![confidence](https://badges.renovateapi.com/packages/maven/com.google.cloud:libraries-bom/26.1.3/confidence-slim/26.1.2)](https://docs.renovatebot.com/merge-confidence/) | --- ### Configuration 📅 **Schedule**: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. 🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] If you want to rebase/retry this PR, click this checkbox. --- This PR has been generated by [Mend Renovate](https://www.mend.io/free-developer-tools/renovate/). View repository job log [here](https://app.renovatebot.com/dashboard#github/googleapis/java-cloudbuild). --- samples/snippets/pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/samples/snippets/pom.xml b/samples/snippets/pom.xml index d410d759..1085e997 100644 --- a/samples/snippets/pom.xml +++ b/samples/snippets/pom.xml @@ -30,7 +30,7 @@ com.google.cloud libraries-bom - 26.1.2 + 26.1.3 pom import From 39c9b15183ea81b791f225a6e60fdc08eb871b8e Mon Sep 17 00:00:00 2001 From: "gcf-owl-bot[bot]" <78513119+gcf-owl-bot[bot]@users.noreply.github.com> Date: Fri, 18 Nov 2022 13:36:44 -0500 Subject: [PATCH 35/38] chore(java): add a note in README for migrated split repos (#1687) (#834) * chore(java): add a note in README for migrated split repos Disable renovate bot and flaky bot for split repositories that have moved to the Java monorepo. The Java monorepo will pass the "monorepo=True" parameter to java.common_templates method in its owlbot.py files so that the migration note will not appear in the README in the monorepo. Co-authored-by: Jeff Ching Source-Link: https://github.com/googleapis/synthtool/commit/d4b291604f148cde065838c498bc8aa79b8dc10e Post-Processor: gcr.io/cloud-devrel-public-resources/owlbot-java:latest@sha256:edae91ccdd2dded2f572ec341a768ad180305a3e8fbfd93064b28e237d35920a Co-authored-by: Owl Bot Co-authored-by: Jeff Ching --- .github/.OwlBot.lock.yaml | 3 +- .github/ISSUE_TEMPLATE/bug_report.md | 5 +++ .github/ISSUE_TEMPLATE/feature_request.md | 5 +++ .kokoro/dependencies.sh | 51 ----------------------- .kokoro/nightly/integration.cfg | 2 +- .kokoro/nightly/java11-integration.cfg | 2 +- .kokoro/nightly/samples.cfg | 2 +- .kokoro/requirements.in | 2 + .kokoro/requirements.txt | 14 ++++--- README.md | 13 ++++-- renovate.json | 1 + 11 files changed, 36 insertions(+), 64 deletions(-) diff --git a/.github/.OwlBot.lock.yaml b/.github/.OwlBot.lock.yaml index 2c3ef720..77cf6087 100644 --- a/.github/.OwlBot.lock.yaml +++ b/.github/.OwlBot.lock.yaml @@ -13,5 +13,4 @@ # limitations under the License. docker: image: gcr.io/cloud-devrel-public-resources/owlbot-java:latest - digest: sha256:f14e3fefe8e361e85752bd9890c8e56f2fe25f1e89cbb9597e4e3c7a429203a3 - + digest: sha256:edae91ccdd2dded2f572ec341a768ad180305a3e8fbfd93064b28e237d35920a diff --git a/.github/ISSUE_TEMPLATE/bug_report.md b/.github/ISSUE_TEMPLATE/bug_report.md index fc6812bf..8d946ade 100644 --- a/.github/ISSUE_TEMPLATE/bug_report.md +++ b/.github/ISSUE_TEMPLATE/bug_report.md @@ -4,6 +4,11 @@ about: Create a report to help us improve --- +:bus: This library has moved to +[google-cloud-java/java-cloudbuild]( +https://github.com/googleapis/google-cloud-java/tree/main/java-cloudbuild). +This repository will be archived in the future. + Thanks for stopping by to let us know something could be better! **PLEASE READ**: If you have a support contract with Google, please create an issue in the [support console](https://cloud.google.com/support/) instead of filing on GitHub. This will ensure a timely response. diff --git a/.github/ISSUE_TEMPLATE/feature_request.md b/.github/ISSUE_TEMPLATE/feature_request.md index 754e30c6..dce72561 100644 --- a/.github/ISSUE_TEMPLATE/feature_request.md +++ b/.github/ISSUE_TEMPLATE/feature_request.md @@ -4,6 +4,11 @@ about: Suggest an idea for this library --- +:bus: This library has moved to +[google-cloud-java/java-cloudbuild]( +https://github.com/googleapis/google-cloud-java/tree/main/java-cloudbuild). +This repository will be archived in the future. + Thanks for stopping by to let us know something could be better! **PLEASE READ**: If you have a support contract with Google, please create an issue in the [support console](https://cloud.google.com/support/) instead of filing on GitHub. This will ensure a timely response. diff --git a/.kokoro/dependencies.sh b/.kokoro/dependencies.sh index d7476cfe..bd896024 100755 --- a/.kokoro/dependencies.sh +++ b/.kokoro/dependencies.sh @@ -57,54 +57,3 @@ retry_with_backoff 3 10 \ -Dclirr.skip=true mvn -B dependency:analyze -DfailOnWarning=true - -echo "****************** DEPENDENCY LIST COMPLETENESS CHECK *******************" -## Run dependency list completeness check -function completenessCheck() { - # Output dep list with compile scope generated using the original pom - # Running mvn dependency:list on Java versions that support modules will also include the module of the dependency. - # This is stripped from the output as it is not present in the flattened pom. - # Only dependencies with 'compile' or 'runtime' scope are included from original dependency list. - msg "Generating dependency list using original pom..." - mvn dependency:list -f pom.xml -DincludeScope=runtime -Dsort=true | grep '\[INFO] .*:.*:.*:.*:.*' | sed -e 's/ --.*//' >.org-list.txt - - # Output dep list generated using the flattened pom (only 'compile' and 'runtime' scopes) - msg "Generating dependency list using flattened pom..." - mvn dependency:list -f .flattened-pom.xml -DincludeScope=runtime -Dsort=true | grep '\[INFO] .*:.*:.*:.*:.*' >.new-list.txt - - # Compare two dependency lists - msg "Comparing dependency lists..." - diff .org-list.txt .new-list.txt >.diff.txt - if [[ $? == 0 ]] - then - msg "Success. No diff!" - else - msg "Diff found. See below: " - msg "You can also check .diff.txt file located in $1." - cat .diff.txt - return 1 - fi -} - -# Allow failures to continue running the script -set +e - -error_count=0 -for path in **/.flattened-pom.xml -do - # Check flattened pom in each dir that contains it for completeness - dir=$(dirname "$path") - pushd "$dir" - completenessCheck "$dir" - error_count=$(($error_count + $?)) - popd -done - -if [[ $error_count == 0 ]] -then - msg "All checks passed." - exit 0 -else - msg "Errors found. See log statements above." - exit 1 -fi diff --git a/.kokoro/nightly/integration.cfg b/.kokoro/nightly/integration.cfg index a2907a25..bd0297a3 100644 --- a/.kokoro/nightly/integration.cfg +++ b/.kokoro/nightly/integration.cfg @@ -23,7 +23,7 @@ env_vars: { env_vars: { key: "ENABLE_FLAKYBOT" - value: "true" + value: "false" } env_vars: { diff --git a/.kokoro/nightly/java11-integration.cfg b/.kokoro/nightly/java11-integration.cfg index 58049cc3..dc51b65e 100644 --- a/.kokoro/nightly/java11-integration.cfg +++ b/.kokoro/nightly/java11-integration.cfg @@ -23,7 +23,7 @@ env_vars: { env_vars: { key: "ENABLE_FLAKYBOT" - value: "true" + value: "false" } env_vars: { diff --git a/.kokoro/nightly/samples.cfg b/.kokoro/nightly/samples.cfg index 9761fd86..fee6a838 100644 --- a/.kokoro/nightly/samples.cfg +++ b/.kokoro/nightly/samples.cfg @@ -34,5 +34,5 @@ env_vars: { env_vars: { key: "ENABLE_FLAKYBOT" - value: "true" + value: "false" } diff --git a/.kokoro/requirements.in b/.kokoro/requirements.in index cfdc2e7e..6aa7cf2b 100644 --- a/.kokoro/requirements.in +++ b/.kokoro/requirements.in @@ -16,10 +16,12 @@ pycparser==2.21 pyperclip==1.8.2 python-dateutil==2.8.2 requests==2.27.1 +certifi==2022.9.24 importlib-metadata==4.8.3 zipp==3.6.0 google_api_core==2.8.2 google-cloud-storage==2.0.0 +google-resumable-media==2.3.3 google-cloud-core==2.3.1 typing-extensions==4.1.1 urllib3==1.26.12 diff --git a/.kokoro/requirements.txt b/.kokoro/requirements.txt index 170f1c63..02ae42bb 100644 --- a/.kokoro/requirements.txt +++ b/.kokoro/requirements.txt @@ -16,10 +16,12 @@ cachetools==4.2.4 \ # via # -r requirements.in # google-auth -certifi==2022.9.14 \ - --hash=sha256:36973885b9542e6bd01dea287b2b4b3b21236307c56324fcc3f1160f2d655ed5 \ - --hash=sha256:e232343de1ab72c2aa521b625c80f699e356830fd0e2c620b465b304b17b0516 - # via requests +certifi==2022.9.24 \ + --hash=sha256:0d9c601124e5a6ba9712dbc60d9c53c21e34f5f641fe83002317394311bdce14 \ + --hash=sha256:90c1a32f1d68f940488354e36370f6cca89f0f106db09518524c88d6ed83f382 + # via + # -r requirements.in + # requests cffi==1.15.1 \ --hash=sha256:00a9ed42e88df81ffae7a8ab6d9356b371399b91dbdf0c3cb1e84c03a13aceb5 \ --hash=sha256:03425bdae262c76aad70202debd780501fabeaca237cdfddc008987c0e0f59ef \ @@ -218,7 +220,9 @@ google-crc32c==1.3.0 \ google-resumable-media==2.3.3 \ --hash=sha256:27c52620bd364d1c8116eaac4ea2afcbfb81ae9139fb3199652fcac1724bfb6c \ --hash=sha256:5b52774ea7a829a8cdaa8bd2d4c3d4bc660c91b30857ab2668d0eb830f4ea8c5 - # via google-cloud-storage + # via + # -r requirements.in + # google-cloud-storage googleapis-common-protos==1.56.3 \ --hash=sha256:6f1369b58ed6cf3a4b7054a44ebe8d03b29c309257583a2bbdc064cd1e4a1442 \ --hash=sha256:87955d7b3a73e6e803f2572a33179de23989ebba725e05ea42f24838b792e461 diff --git a/README.md b/README.md index d1cb0186..8ceeed11 100644 --- a/README.md +++ b/README.md @@ -9,6 +9,13 @@ Java idiomatic client for [Cloud Build][product-docs]. - [Client Library Documentation][javadocs] +:bus: In October 2022, this library has moved to +[google-cloud-java/java-cloudbuild]( +https://github.com/googleapis/google-cloud-java/tree/main/java-cloudbuild). +This repository will be archived in the future. +Future releases will appear in the new repository (https://github.com/googleapis/google-cloud-java/releases). +The Maven artifact coordinates (`com.google.cloud:google-cloud-build`) remain the same. + ## Quickstart @@ -19,20 +26,20 @@ If you are using Maven, add this to your pom.xml file: com.google.cloud google-cloud-build - 3.5.6 + 3.7.0 ``` If you are using Gradle without BOM, add this to your dependencies: ```Groovy -implementation 'com.google.cloud:google-cloud-build:3.5.6' +implementation 'com.google.cloud:google-cloud-build:3.7.0' ``` If you are using SBT, add this to your dependencies: ```Scala -libraryDependencies += "com.google.cloud" % "google-cloud-build" % "3.5.6" +libraryDependencies += "com.google.cloud" % "google-cloud-build" % "3.7.0" ``` ## Authentication diff --git a/renovate.json b/renovate.json index 201d65e9..4870face 100644 --- a/renovate.json +++ b/renovate.json @@ -1,4 +1,5 @@ { + "enabled": false, "extends": [ ":separateMajorReleases", ":combinePatchMinorReleases", From 9a024f79506a54fcb1807ab49097c133a12d7047 Mon Sep 17 00:00:00 2001 From: Deepankar Dixit <90280028+ddixit14@users.noreply.github.com> Date: Fri, 24 Mar 2023 13:34:47 -0400 Subject: [PATCH 36/38] chore: Disabling owlbot (#853) --- .github/.OwlBot.lock.yaml | 16 ---------------- .github/.OwlBot.yaml | 29 ----------------------------- owlbot.py | 24 ------------------------ 3 files changed, 69 deletions(-) delete mode 100644 .github/.OwlBot.lock.yaml delete mode 100644 .github/.OwlBot.yaml delete mode 100644 owlbot.py diff --git a/.github/.OwlBot.lock.yaml b/.github/.OwlBot.lock.yaml deleted file mode 100644 index 77cf6087..00000000 --- a/.github/.OwlBot.lock.yaml +++ /dev/null @@ -1,16 +0,0 @@ -# Copyright 2022 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -docker: - image: gcr.io/cloud-devrel-public-resources/owlbot-java:latest - digest: sha256:edae91ccdd2dded2f572ec341a768ad180305a3e8fbfd93064b28e237d35920a diff --git a/.github/.OwlBot.yaml b/.github/.OwlBot.yaml deleted file mode 100644 index 27decc97..00000000 --- a/.github/.OwlBot.yaml +++ /dev/null @@ -1,29 +0,0 @@ -# Copyright 2021 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -docker: - image: "gcr.io/cloud-devrel-public-resources/owlbot-java:latest" - -deep-remove-regex: -- "/grpc-google-.*/src" -- "/proto-google-.*/src" -- "/google-.*/src" - -deep-copy-regex: -- source: "/google/devtools/cloudbuild/(v.*)/.*-java/proto-google-.*/src" - dest: "/owl-bot-staging/$1/proto-google-cloud-build-$1/src" -- source: "/google/devtools/cloudbuild/(v.*)/.*-java/grpc-google-.*/src" - dest: "/owl-bot-staging/$1/grpc-google-cloud-build-$1/src" -- source: "/google/devtools/cloudbuild/(v.*)/.*-java/gapic-google-.*/src" - dest: "/owl-bot-staging/$1/google-cloud-build/src" diff --git a/owlbot.py b/owlbot.py deleted file mode 100644 index dca9d867..00000000 --- a/owlbot.py +++ /dev/null @@ -1,24 +0,0 @@ -# Copyright 2021 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -import synthtool as s -from synthtool.languages import java - - -for library in s.get_staging_dirs(): - # put any special-case replacements here - s.move(library) - -s.remove_staging_dirs() -java.common_templates() From 1162227bdfb56bb6647bd9c99ba9e5630abe4260 Mon Sep 17 00:00:00 2001 From: Jeff Ching Date: Wed, 31 May 2023 12:21:06 -0700 Subject: [PATCH 37/38] build: enable multiScm for releases (#856) --- .github/release-trigger.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/release-trigger.yml b/.github/release-trigger.yml index d4ca9418..979c7925 100644 --- a/.github/release-trigger.yml +++ b/.github/release-trigger.yml @@ -1 +1,2 @@ enabled: true +multiScmName: java-cloudbuild From e68a25ad53074ba746111d7c61775eb5bec0bd71 Mon Sep 17 00:00:00 2001 From: Tomo Suzuki Date: Wed, 5 Jul 2023 14:39:05 -0400 Subject: [PATCH 38/38] chore: removing outdated files in favor of https://github.com/googleapis/google-cloud-java/tree/main/java-cloudbuild (#859) --- .github/CODEOWNERS | 15 - .github/ISSUE_TEMPLATE/bug_report.md | 56 - .github/ISSUE_TEMPLATE/feature_request.md | 26 - .github/ISSUE_TEMPLATE/support_request.md | 7 - .github/PULL_REQUEST_TEMPLATE.md | 10 - .github/auto-label.yaml | 15 - .github/blunderbuss.yml | 7 - .github/generated-files-bot.yml | 12 - .github/snippet-bot.yml | 0 .github/sync-repo-settings.yaml | 42 - .github/trusted-contribution.yml | 3 - .github/workflows/approve-readme.yaml | 69 - .github/workflows/auto-release.yaml | 103 - .github/workflows/ci.yaml | 89 - .github/workflows/samples.yaml | 30 - .gitignore | 34 - .kokoro/build.bat | 18 - .kokoro/build.sh | 134 - .kokoro/coerce_logs.sh | 37 - .kokoro/common.cfg | 13 - .kokoro/common.sh | 60 - .kokoro/continuous/common.cfg | 25 - .kokoro/continuous/java8.cfg | 12 - .kokoro/continuous/propose_release.sh | 29 - .kokoro/dependencies.sh | 59 - .kokoro/nightly/common.cfg | 25 - .kokoro/nightly/integration.cfg | 37 - .kokoro/nightly/java11-integration.cfg | 37 - .kokoro/nightly/java11.cfg | 7 - .kokoro/nightly/java7.cfg | 7 - .kokoro/nightly/java8-osx.cfg | 3 - .kokoro/nightly/java8-win.cfg | 3 - .kokoro/nightly/java8.cfg | 12 - .kokoro/nightly/samples.cfg | 38 - .kokoro/populate-secrets.sh | 43 - .kokoro/presubmit/clirr.cfg | 13 - .kokoro/presubmit/common.cfg | 34 - .kokoro/presubmit/dependencies.cfg | 12 - .kokoro/presubmit/graalvm-native-17.cfg | 33 - .kokoro/presubmit/graalvm-native.cfg | 33 - .kokoro/presubmit/integration.cfg | 33 - .kokoro/presubmit/java11.cfg | 7 - .kokoro/presubmit/java7.cfg | 7 - .kokoro/presubmit/java8-osx.cfg | 3 - .kokoro/presubmit/java8-win.cfg | 3 - .kokoro/presubmit/java8.cfg | 12 - .kokoro/presubmit/linkage-monitor.cfg | 12 - .kokoro/presubmit/lint.cfg | 13 - .kokoro/presubmit/samples.cfg | 33 - .kokoro/readme.sh | 45 - .kokoro/release/bump_snapshot.cfg | 53 - .kokoro/release/bump_snapshot.sh | 30 - .kokoro/release/common.cfg | 49 - .kokoro/release/common.sh | 50 - .kokoro/release/drop.cfg | 6 - .kokoro/release/drop.sh | 32 - .kokoro/release/promote.cfg | 6 - .kokoro/release/promote.sh | 34 - .kokoro/release/publish_javadoc.cfg | 23 - .kokoro/release/publish_javadoc.sh | 53 - .kokoro/release/publish_javadoc11.cfg | 30 - .kokoro/release/publish_javadoc11.sh | 63 - .kokoro/release/snapshot.cfg | 6 - .kokoro/release/snapshot.sh | 33 - .kokoro/release/stage.cfg | 19 - .kokoro/release/stage.sh | 47 - .kokoro/requirements.in | 33 - .kokoro/requirements.txt | 456 - .kokoro/trampoline.sh | 26 - .repo-metadata.json | 18 - CHANGELOG.md | 603 - codecov.yaml | 4 - google-cloud-build-bom/pom.xml | 81 - google-cloud-build/pom.xml | 126 - .../cloudbuild/v1/CloudBuildClient.java | 2810 ---- .../cloudbuild/v1/CloudBuildSettings.java | 515 - .../cloudbuild/v1/gapic_metadata.json | 72 - .../devtools/cloudbuild/v1/package-info.java | 48 - .../cloudbuild/v1/stub/CloudBuildStub.java | 202 - .../v1/stub/CloudBuildStubSettings.java | 1297 -- .../stub/GrpcCloudBuildCallableFactory.java | 113 - .../v1/stub/GrpcCloudBuildStub.java | 854 -- .../HttpJsonCloudBuildCallableFactory.java | 105 - .../v1/stub/HttpJsonCloudBuildStub.java | 1337 -- .../v1/CloudBuildClientHttpJsonTest.java | 1488 --- .../cloudbuild/v1/CloudBuildClientTest.java | 1372 -- .../cloudbuild/v1/MockCloudBuild.java | 59 - .../cloudbuild/v1/MockCloudBuildImpl.java | 463 - grpc-google-cloud-build-v1/pom.xml | 69 - .../google/cloudbuild/v1/CloudBuildGrpc.java | 2428 ---- java.header | 15 - license-checks.xml | 10 - pom.xml | 188 - .../clirr-ignored-differences.xml | 19 - proto-google-cloud-build-v1/pom.xml | 42 - .../google/cloudbuild/v1/ApprovalConfig.java | 533 - .../v1/ApprovalConfigOrBuilder.java | 40 - .../google/cloudbuild/v1/ApprovalResult.java | 1615 --- .../v1/ApprovalResultOrBuilder.java | 178 - .../cloudbuild/v1/ApproveBuildRequest.java | 889 -- .../v1/ApproveBuildRequestOrBuilder.java | 87 - .../google/cloudbuild/v1/ArtifactResult.java | 1117 -- .../v1/ArtifactResultOrBuilder.java | 105 - .../com/google/cloudbuild/v1/Artifacts.java | 2445 ---- .../cloudbuild/v1/ArtifactsOrBuilder.java | 152 - .../java/com/google/cloudbuild/v1/Build.java | 11130 ---------------- .../google/cloudbuild/v1/BuildApproval.java | 1379 -- .../cloudbuild/v1/BuildApprovalOrBuilder.java | 136 - .../com/google/cloudbuild/v1/BuildName.java | 313 - .../cloudbuild/v1/BuildOperationMetadata.java | 695 - .../v1/BuildOperationMetadataOrBuilder.java | 60 - .../google/cloudbuild/v1/BuildOptions.java | 5191 ------- .../cloudbuild/v1/BuildOptionsOrBuilder.java | 555 - .../google/cloudbuild/v1/BuildOrBuilder.java | 1269 -- .../com/google/cloudbuild/v1/BuildStep.java | 4365 ------ .../cloudbuild/v1/BuildStepOrBuilder.java | 683 - .../google/cloudbuild/v1/BuildTrigger.java | 5207 -------- .../cloudbuild/v1/BuildTriggerName.java | 313 - .../cloudbuild/v1/BuildTriggerOrBuilder.java | 789 -- .../com/google/cloudbuild/v1/BuiltImage.java | 1087 -- .../cloudbuild/v1/BuiltImageOrBuilder.java | 118 - .../cloudbuild/v1/CancelBuildRequest.java | 977 -- .../v1/CancelBuildRequestOrBuilder.java | 102 - .../com/google/cloudbuild/v1/Cloudbuild.java | 1550 --- .../cloudbuild/v1/CreateBuildRequest.java | 1079 -- .../v1/CreateBuildRequestOrBuilder.java | 115 - .../v1/CreateBuildTriggerRequest.java | 1089 -- .../CreateBuildTriggerRequestOrBuilder.java | 118 - .../v1/CreateWorkerPoolOperationMetadata.java | 1161 -- ...eWorkerPoolOperationMetadataOrBuilder.java | 124 - .../v1/CreateWorkerPoolRequest.java | 1235 -- .../v1/CreateWorkerPoolRequestOrBuilder.java | 146 - .../v1/DeleteBuildTriggerRequest.java | 978 -- .../DeleteBuildTriggerRequestOrBuilder.java | 102 - .../v1/DeleteWorkerPoolOperationMetadata.java | 1161 -- ...eWorkerPoolOperationMetadataOrBuilder.java | 124 - .../v1/DeleteWorkerPoolRequest.java | 1018 -- .../v1/DeleteWorkerPoolRequestOrBuilder.java | 113 - .../com/google/cloudbuild/v1/FileHashes.java | 920 -- .../cloudbuild/v1/FileHashesOrBuilder.java | 76 - .../google/cloudbuild/v1/GetBuildRequest.java | 976 -- .../v1/GetBuildRequestOrBuilder.java | 102 - .../cloudbuild/v1/GetBuildTriggerRequest.java | 978 -- .../v1/GetBuildTriggerRequestOrBuilder.java | 102 - .../cloudbuild/v1/GetWorkerPoolRequest.java | 635 - .../v1/GetWorkerPoolRequestOrBuilder.java | 56 - .../cloudbuild/v1/GitHubEventsConfig.java | 1589 --- .../v1/GitHubEventsConfigOrBuilder.java | 169 - .../java/com/google/cloudbuild/v1/Hash.java | 832 -- .../google/cloudbuild/v1/HashOrBuilder.java | 63 - .../google/cloudbuild/v1/InlineSecret.java | 998 -- .../cloudbuild/v1/InlineSecretOrBuilder.java | 131 - .../v1/ListBuildTriggersRequest.java | 1069 -- .../v1/ListBuildTriggersRequestOrBuilder.java | 115 - .../v1/ListBuildTriggersResponse.java | 1103 -- .../ListBuildTriggersResponseOrBuilder.java | 102 - .../cloudbuild/v1/ListBuildsRequest.java | 1281 -- .../v1/ListBuildsRequestOrBuilder.java | 150 - .../cloudbuild/v1/ListBuildsResponse.java | 1106 -- .../v1/ListBuildsResponseOrBuilder.java | 103 - .../cloudbuild/v1/ListWorkerPoolsRequest.java | 916 -- .../v1/ListWorkerPoolsRequestOrBuilder.java | 97 - .../v1/ListWorkerPoolsResponse.java | 1117 -- .../v1/ListWorkerPoolsResponseOrBuilder.java | 106 - .../google/cloudbuild/v1/LocationName.java | 192 - .../cloudbuild/v1/PrivatePoolV1Config.java | 2876 ---- .../v1/PrivatePoolV1ConfigOrBuilder.java | 98 - .../google/cloudbuild/v1/PubsubConfig.java | 1356 -- .../cloudbuild/v1/PubsubConfigOrBuilder.java | 135 - .../cloudbuild/v1/PullRequestFilter.java | 1190 -- .../v1/PullRequestFilterOrBuilder.java | 112 - .../com/google/cloudbuild/v1/PushFilter.java | 1110 -- .../cloudbuild/v1/PushFilterOrBuilder.java | 127 - .../v1/ReceiveTriggerWebhookRequest.java | 1416 -- ...ReceiveTriggerWebhookRequestOrBuilder.java | 162 - .../v1/ReceiveTriggerWebhookResponse.java | 439 - ...eceiveTriggerWebhookResponseOrBuilder.java | 24 - .../com/google/cloudbuild/v1/RepoSource.java | 2242 ---- .../cloudbuild/v1/RepoSourceOrBuilder.java | 309 - .../com/google/cloudbuild/v1/Results.java | 2003 --- .../cloudbuild/v1/ResultsOrBuilder.java | 254 - .../cloudbuild/v1/RetryBuildRequest.java | 977 -- .../v1/RetryBuildRequestOrBuilder.java | 102 - .../cloudbuild/v1/RunBuildTriggerRequest.java | 1239 -- .../v1/RunBuildTriggerRequestOrBuilder.java | 137 - .../java/com/google/cloudbuild/v1/Secret.java | 996 -- .../cloudbuild/v1/SecretManagerSecret.java | 813 -- .../v1/SecretManagerSecretOrBuilder.java | 81 - .../google/cloudbuild/v1/SecretOrBuilder.java | 129 - .../com/google/cloudbuild/v1/Secrets.java | 1436 -- .../cloudbuild/v1/SecretsOrBuilder.java | 133 - .../java/com/google/cloudbuild/v1/Source.java | 1450 -- .../google/cloudbuild/v1/SourceOrBuilder.java | 141 - .../cloudbuild/v1/SourceProvenance.java | 1766 --- .../v1/SourceProvenanceOrBuilder.java | 253 - .../google/cloudbuild/v1/StorageSource.java | 914 -- .../cloudbuild/v1/StorageSourceManifest.java | 912 -- .../v1/StorageSourceManifestOrBuilder.java | 95 - .../cloudbuild/v1/StorageSourceOrBuilder.java | 97 - .../com/google/cloudbuild/v1/TimeSpan.java | 950 -- .../cloudbuild/v1/TimeSpanOrBuilder.java | 95 - .../v1/UpdateBuildTriggerRequest.java | 1082 -- .../UpdateBuildTriggerRequestOrBuilder.java | 116 - .../v1/UpdateWorkerPoolOperationMetadata.java | 1161 -- ...eWorkerPoolOperationMetadataOrBuilder.java | 124 - .../v1/UpdateWorkerPoolRequest.java | 1109 -- .../v1/UpdateWorkerPoolRequestOrBuilder.java | 121 - .../java/com/google/cloudbuild/v1/Volume.java | 817 -- .../google/cloudbuild/v1/VolumeOrBuilder.java | 83 - .../google/cloudbuild/v1/WebhookConfig.java | 1079 -- .../cloudbuild/v1/WebhookConfigOrBuilder.java | 97 - .../com/google/cloudbuild/v1/WorkerPool.java | 3178 ----- .../google/cloudbuild/v1/WorkerPoolName.java | 223 - .../cloudbuild/v1/WorkerPoolOrBuilder.java | 392 - .../devtools/cloudbuild/v1/cloudbuild.proto | 2142 --- renovate.json | 76 - samples/install-without-bom/pom.xml | 84 - samples/pom.xml | 56 - samples/snapshot/pom.xml | 83 - samples/snippets/pom.xml | 60 - synth.metadata | 243 - versions.txt | 6 - 222 files changed, 122425 deletions(-) delete mode 100644 .github/CODEOWNERS delete mode 100644 .github/ISSUE_TEMPLATE/bug_report.md delete mode 100644 .github/ISSUE_TEMPLATE/feature_request.md delete mode 100644 .github/ISSUE_TEMPLATE/support_request.md delete mode 100644 .github/PULL_REQUEST_TEMPLATE.md delete mode 100644 .github/auto-label.yaml delete mode 100644 .github/blunderbuss.yml delete mode 100644 .github/generated-files-bot.yml delete mode 100644 .github/snippet-bot.yml delete mode 100644 .github/sync-repo-settings.yaml delete mode 100644 .github/trusted-contribution.yml delete mode 100644 .github/workflows/approve-readme.yaml delete mode 100644 .github/workflows/auto-release.yaml delete mode 100644 .github/workflows/ci.yaml delete mode 100644 .github/workflows/samples.yaml delete mode 100644 .gitignore delete mode 100644 .kokoro/build.bat delete mode 100755 .kokoro/build.sh delete mode 100755 .kokoro/coerce_logs.sh delete mode 100644 .kokoro/common.cfg delete mode 100644 .kokoro/common.sh delete mode 100644 .kokoro/continuous/common.cfg delete mode 100644 .kokoro/continuous/java8.cfg delete mode 100755 .kokoro/continuous/propose_release.sh delete mode 100755 .kokoro/dependencies.sh delete mode 100644 .kokoro/nightly/common.cfg delete mode 100644 .kokoro/nightly/integration.cfg delete mode 100644 .kokoro/nightly/java11-integration.cfg delete mode 100644 .kokoro/nightly/java11.cfg delete mode 100644 .kokoro/nightly/java7.cfg delete mode 100644 .kokoro/nightly/java8-osx.cfg delete mode 100644 .kokoro/nightly/java8-win.cfg delete mode 100644 .kokoro/nightly/java8.cfg delete mode 100644 .kokoro/nightly/samples.cfg delete mode 100755 .kokoro/populate-secrets.sh delete mode 100644 .kokoro/presubmit/clirr.cfg delete mode 100644 .kokoro/presubmit/common.cfg delete mode 100644 .kokoro/presubmit/dependencies.cfg delete mode 100644 .kokoro/presubmit/graalvm-native-17.cfg delete mode 100644 .kokoro/presubmit/graalvm-native.cfg delete mode 100644 .kokoro/presubmit/integration.cfg delete mode 100644 .kokoro/presubmit/java11.cfg delete mode 100644 .kokoro/presubmit/java7.cfg delete mode 100644 .kokoro/presubmit/java8-osx.cfg delete mode 100644 .kokoro/presubmit/java8-win.cfg delete mode 100644 .kokoro/presubmit/java8.cfg delete mode 100644 .kokoro/presubmit/linkage-monitor.cfg delete mode 100644 .kokoro/presubmit/lint.cfg delete mode 100644 .kokoro/presubmit/samples.cfg delete mode 100755 .kokoro/readme.sh delete mode 100644 .kokoro/release/bump_snapshot.cfg delete mode 100755 .kokoro/release/bump_snapshot.sh delete mode 100644 .kokoro/release/common.cfg delete mode 100755 .kokoro/release/common.sh delete mode 100644 .kokoro/release/drop.cfg delete mode 100755 .kokoro/release/drop.sh delete mode 100644 .kokoro/release/promote.cfg delete mode 100755 .kokoro/release/promote.sh delete mode 100644 .kokoro/release/publish_javadoc.cfg delete mode 100755 .kokoro/release/publish_javadoc.sh delete mode 100644 .kokoro/release/publish_javadoc11.cfg delete mode 100755 .kokoro/release/publish_javadoc11.sh delete mode 100644 .kokoro/release/snapshot.cfg delete mode 100755 .kokoro/release/snapshot.sh delete mode 100644 .kokoro/release/stage.cfg delete mode 100755 .kokoro/release/stage.sh delete mode 100644 .kokoro/requirements.in delete mode 100644 .kokoro/requirements.txt delete mode 100644 .kokoro/trampoline.sh delete mode 100644 .repo-metadata.json delete mode 100644 CHANGELOG.md delete mode 100644 codecov.yaml delete mode 100644 google-cloud-build-bom/pom.xml delete mode 100644 google-cloud-build/pom.xml delete mode 100644 google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/CloudBuildClient.java delete mode 100644 google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/CloudBuildSettings.java delete mode 100644 google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/gapic_metadata.json delete mode 100644 google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/package-info.java delete mode 100644 google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/stub/CloudBuildStub.java delete mode 100644 google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/stub/CloudBuildStubSettings.java delete mode 100644 google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/stub/GrpcCloudBuildCallableFactory.java delete mode 100644 google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/stub/GrpcCloudBuildStub.java delete mode 100644 google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/stub/HttpJsonCloudBuildCallableFactory.java delete mode 100644 google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/stub/HttpJsonCloudBuildStub.java delete mode 100644 google-cloud-build/src/test/java/com/google/cloud/devtools/cloudbuild/v1/CloudBuildClientHttpJsonTest.java delete mode 100644 google-cloud-build/src/test/java/com/google/cloud/devtools/cloudbuild/v1/CloudBuildClientTest.java delete mode 100644 google-cloud-build/src/test/java/com/google/cloud/devtools/cloudbuild/v1/MockCloudBuild.java delete mode 100644 google-cloud-build/src/test/java/com/google/cloud/devtools/cloudbuild/v1/MockCloudBuildImpl.java delete mode 100644 grpc-google-cloud-build-v1/pom.xml delete mode 100644 grpc-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CloudBuildGrpc.java delete mode 100644 java.header delete mode 100644 license-checks.xml delete mode 100644 pom.xml delete mode 100644 proto-google-cloud-build-v1/clirr-ignored-differences.xml delete mode 100644 proto-google-cloud-build-v1/pom.xml delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ApprovalConfig.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ApprovalConfigOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ApprovalResult.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ApprovalResultOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ApproveBuildRequest.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ApproveBuildRequestOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ArtifactResult.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ArtifactResultOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Artifacts.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ArtifactsOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Build.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildApproval.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildApprovalOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildName.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildOperationMetadata.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildOperationMetadataOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildOptions.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildOptionsOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildStep.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildStepOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildTrigger.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildTriggerName.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildTriggerOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuiltImage.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuiltImageOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CancelBuildRequest.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CancelBuildRequestOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Cloudbuild.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CreateBuildRequest.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CreateBuildRequestOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CreateBuildTriggerRequest.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CreateBuildTriggerRequestOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CreateWorkerPoolOperationMetadata.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CreateWorkerPoolOperationMetadataOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CreateWorkerPoolRequest.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CreateWorkerPoolRequestOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/DeleteBuildTriggerRequest.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/DeleteBuildTriggerRequestOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/DeleteWorkerPoolOperationMetadata.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/DeleteWorkerPoolOperationMetadataOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/DeleteWorkerPoolRequest.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/DeleteWorkerPoolRequestOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/FileHashes.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/FileHashesOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GetBuildRequest.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GetBuildRequestOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GetBuildTriggerRequest.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GetBuildTriggerRequestOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GetWorkerPoolRequest.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GetWorkerPoolRequestOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GitHubEventsConfig.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GitHubEventsConfigOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Hash.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/HashOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/InlineSecret.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/InlineSecretOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildTriggersRequest.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildTriggersRequestOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildTriggersResponse.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildTriggersResponseOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildsRequest.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildsRequestOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildsResponse.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildsResponseOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListWorkerPoolsRequest.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListWorkerPoolsRequestOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListWorkerPoolsResponse.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListWorkerPoolsResponseOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/LocationName.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/PrivatePoolV1Config.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/PrivatePoolV1ConfigOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/PubsubConfig.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/PubsubConfigOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/PullRequestFilter.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/PullRequestFilterOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/PushFilter.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/PushFilterOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ReceiveTriggerWebhookRequest.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ReceiveTriggerWebhookRequestOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ReceiveTriggerWebhookResponse.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ReceiveTriggerWebhookResponseOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/RepoSource.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/RepoSourceOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Results.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ResultsOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/RetryBuildRequest.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/RetryBuildRequestOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/RunBuildTriggerRequest.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/RunBuildTriggerRequestOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Secret.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/SecretManagerSecret.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/SecretManagerSecretOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/SecretOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Secrets.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/SecretsOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Source.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/SourceOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/SourceProvenance.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/SourceProvenanceOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/StorageSource.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/StorageSourceManifest.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/StorageSourceManifestOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/StorageSourceOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/TimeSpan.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/TimeSpanOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/UpdateBuildTriggerRequest.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/UpdateBuildTriggerRequestOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/UpdateWorkerPoolOperationMetadata.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/UpdateWorkerPoolOperationMetadataOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/UpdateWorkerPoolRequest.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/UpdateWorkerPoolRequestOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Volume.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/VolumeOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/WebhookConfig.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/WebhookConfigOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/WorkerPool.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/WorkerPoolName.java delete mode 100644 proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/WorkerPoolOrBuilder.java delete mode 100644 proto-google-cloud-build-v1/src/main/proto/google/devtools/cloudbuild/v1/cloudbuild.proto delete mode 100644 renovate.json delete mode 100644 samples/install-without-bom/pom.xml delete mode 100644 samples/pom.xml delete mode 100644 samples/snapshot/pom.xml delete mode 100644 samples/snippets/pom.xml delete mode 100644 synth.metadata delete mode 100644 versions.txt diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS deleted file mode 100644 index 5232f38f..00000000 --- a/.github/CODEOWNERS +++ /dev/null @@ -1,15 +0,0 @@ -# Code owners file. -# This file controls who is tagged for review for any given pull request. - -# For syntax help see: -# https://help.github.com/en/github/creating-cloning-and-archiving-repositories/about-code-owners#codeowners-syntax - -# The @googleapis/aap-dpes is the default owner for changes in this repo -* @googleapis/yoshi-java @googleapis/aap-dpes - - -# The java-samples-reviewers team is the default owner for samples changes -samples/**/*.java @googleapis/java-samples-reviewers - -# Generated snippets should not be owned by samples reviewers -samples/snippets/generated/ @googleapis/yoshi-java diff --git a/.github/ISSUE_TEMPLATE/bug_report.md b/.github/ISSUE_TEMPLATE/bug_report.md deleted file mode 100644 index 8d946ade..00000000 --- a/.github/ISSUE_TEMPLATE/bug_report.md +++ /dev/null @@ -1,56 +0,0 @@ ---- -name: Bug report -about: Create a report to help us improve - ---- - -:bus: This library has moved to -[google-cloud-java/java-cloudbuild]( -https://github.com/googleapis/google-cloud-java/tree/main/java-cloudbuild). -This repository will be archived in the future. - -Thanks for stopping by to let us know something could be better! - -**PLEASE READ**: If you have a support contract with Google, please create an issue in the [support console](https://cloud.google.com/support/) instead of filing on GitHub. This will ensure a timely response. - -Please run down the following list and make sure you've tried the usual "quick fixes": - - - Search the issues already opened: https://github.com/googleapis/java-cloudbuild/issues - - Check for answers on StackOverflow: http://stackoverflow.com/questions/tagged/google-cloud-platform - -If you are still having issues, please include as much information as possible: - -#### Environment details - -1. Specify the API at the beginning of the title. For example, "BigQuery: ..."). - General, Core, and Other are also allowed as types -2. OS type and version: -3. Java version: -4. version(s): - -#### Steps to reproduce - - 1. ? - 2. ? - -#### Code example - -```java -// example -``` - -#### Stack trace -``` -Any relevant stacktrace here. -``` - -#### External references such as API reference guides - -- ? - -#### Any additional information below - - -Following these steps guarantees the quickest resolution possible. - -Thanks! diff --git a/.github/ISSUE_TEMPLATE/feature_request.md b/.github/ISSUE_TEMPLATE/feature_request.md deleted file mode 100644 index dce72561..00000000 --- a/.github/ISSUE_TEMPLATE/feature_request.md +++ /dev/null @@ -1,26 +0,0 @@ ---- -name: Feature request -about: Suggest an idea for this library - ---- - -:bus: This library has moved to -[google-cloud-java/java-cloudbuild]( -https://github.com/googleapis/google-cloud-java/tree/main/java-cloudbuild). -This repository will be archived in the future. - -Thanks for stopping by to let us know something could be better! - -**PLEASE READ**: If you have a support contract with Google, please create an issue in the [support console](https://cloud.google.com/support/) instead of filing on GitHub. This will ensure a timely response. - -**Is your feature request related to a problem? Please describe.** -What the problem is. Example: I'm always frustrated when [...] - -**Describe the solution you'd like** -What you want to happen. - -**Describe alternatives you've considered** -Any alternative solutions or features you've considered. - -**Additional context** -Any other context or screenshots about the feature request. diff --git a/.github/ISSUE_TEMPLATE/support_request.md b/.github/ISSUE_TEMPLATE/support_request.md deleted file mode 100644 index 99586903..00000000 --- a/.github/ISSUE_TEMPLATE/support_request.md +++ /dev/null @@ -1,7 +0,0 @@ ---- -name: Support request -about: If you have a support contract with Google, please create an issue in the Google Cloud Support console. - ---- - -**PLEASE READ**: If you have a support contract with Google, please create an issue in the [support console](https://cloud.google.com/support/) instead of filing on GitHub. This will ensure a timely response. diff --git a/.github/PULL_REQUEST_TEMPLATE.md b/.github/PULL_REQUEST_TEMPLATE.md deleted file mode 100644 index 33d089bc..00000000 --- a/.github/PULL_REQUEST_TEMPLATE.md +++ /dev/null @@ -1,10 +0,0 @@ -Thank you for opening a Pull Request! Before submitting your PR, there are a few things you can do to make sure it goes smoothly: -- [ ] Make sure to open an issue as a [bug/issue](https://github.com/googleapis/java-cloudbuild/issues/new/choose) before writing your code! That way we can discuss the change, evaluate designs, and agree on the general idea -- [ ] Ensure the tests and linter pass -- [ ] Code coverage does not decrease (if any source code was changed) -- [ ] Appropriate docs were updated (if necessary) - -Fixes # ☕️ - -If you write sample code, please follow the [samples format]( -https://github.com/GoogleCloudPlatform/java-docs-samples/blob/main/SAMPLE_FORMAT.md). diff --git a/.github/auto-label.yaml b/.github/auto-label.yaml deleted file mode 100644 index 4caef688..00000000 --- a/.github/auto-label.yaml +++ /dev/null @@ -1,15 +0,0 @@ -# Copyright 2021 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -requestsize: - enabled: true diff --git a/.github/blunderbuss.yml b/.github/blunderbuss.yml deleted file mode 100644 index 2176b054..00000000 --- a/.github/blunderbuss.yml +++ /dev/null @@ -1,7 +0,0 @@ -# Configuration for the Blunderbuss GitHub app. For more info see -# https://github.com/googleapis/repo-automation-bots/tree/main/packages/blunderbuss -assign_prs_by: -- labels: - - samples - to: - - googleapis/java-samples-reviewers \ No newline at end of file diff --git a/.github/generated-files-bot.yml b/.github/generated-files-bot.yml deleted file mode 100644 index c644a24e..00000000 --- a/.github/generated-files-bot.yml +++ /dev/null @@ -1,12 +0,0 @@ -externalManifests: -- type: json - file: 'synth.metadata' - jsonpath: '$.generatedFiles[*]' -- type: json - file: '.github/readme/synth.metadata/synth.metadata' - jsonpath: '$.generatedFiles[*]' -ignoreAuthors: -- 'renovate-bot' -- 'yoshi-automation' -- 'release-please[bot]' -- 'gcf-owl-bot[bot]' diff --git a/.github/snippet-bot.yml b/.github/snippet-bot.yml deleted file mode 100644 index e69de29b..00000000 diff --git a/.github/sync-repo-settings.yaml b/.github/sync-repo-settings.yaml deleted file mode 100644 index 0501f63f..00000000 --- a/.github/sync-repo-settings.yaml +++ /dev/null @@ -1,42 +0,0 @@ -rebaseMergeAllowed: false -squashMergeAllowed: true -mergeCommitAllowed: false -branchProtectionRules: - - pattern: main - isAdminEnforced: true - requiredApprovingReviewCount: 1 - requiresCodeOwnerReviews: true - requiresStrictStatusChecks: false - requiredStatusCheckContexts: - - dependencies (8) - - dependencies (11) - - lint - - units (8) - - units (11) - - 'Kokoro - Test: Integration' - - cla/google - - OwlBot Post Processor - - 'Kokoro - Test: Java GraalVM Native Image' - - 'Kokoro - Test: Java 17 GraalVM Native Image' - - pattern: java7 - isAdminEnforced: true - requiredApprovingReviewCount: 1 - requiresCodeOwnerReviews: true - requiresStrictStatusChecks: false - requiredStatusCheckContexts: - - dependencies (8) - - dependencies (11) - - lint - - units (7) - - units (8) - - units (11) - - 'Kokoro - Test: Integration' - - cla/google - - OwlBot Post Processor -permissionRules: - - team: yoshi-admins - permission: admin - - team: yoshi-java-admins - permission: admin - - team: yoshi-java - permission: push diff --git a/.github/trusted-contribution.yml b/.github/trusted-contribution.yml deleted file mode 100644 index a0ba1f7d..00000000 --- a/.github/trusted-contribution.yml +++ /dev/null @@ -1,3 +0,0 @@ -trustedContributors: -- renovate-bot -- gcf-owl-bot[bot] diff --git a/.github/workflows/approve-readme.yaml b/.github/workflows/approve-readme.yaml deleted file mode 100644 index f5fc7d51..00000000 --- a/.github/workflows/approve-readme.yaml +++ /dev/null @@ -1,69 +0,0 @@ -# Copyright 2022 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# Github action job to test core java library features on -# downstream client libraries before they are released. -on: - pull_request: -name: auto-merge-readme -jobs: - approve: - runs-on: ubuntu-latest - if: github.repository_owner == 'googleapis' && github.head_ref == 'autosynth-readme' - steps: - - uses: actions/github-script@v6 - with: - github-token: ${{secrets.YOSHI_APPROVER_TOKEN}} - script: | - // only approve PRs from yoshi-automation - if (context.payload.pull_request.user.login !== "yoshi-automation") { - return; - } - - // only approve PRs like "chore: release " - if (!context.payload.pull_request.title === "chore: regenerate README") { - return; - } - - // only approve PRs with README.md and synth.metadata changes - const files = new Set( - ( - await github.paginate( - github.pulls.listFiles.endpoint({ - owner: context.repo.owner, - repo: context.repo.repo, - pull_number: context.payload.pull_request.number, - }) - ) - ).map(file => file.filename) - ); - if (files.size != 2 || !files.has("README.md") || !files.has(".github/readme/synth.metadata/synth.metadata")) { - return; - } - - // approve README regeneration PR - await github.pulls.createReview({ - owner: context.repo.owner, - repo: context.repo.repo, - body: 'Rubber stamped PR!', - pull_number: context.payload.pull_request.number, - event: 'APPROVE' - }); - - // attach automerge label - await github.issues.addLabels({ - owner: context.repo.owner, - repo: context.repo.repo, - issue_number: context.payload.pull_request.number, - labels: ['automerge'] - }); diff --git a/.github/workflows/auto-release.yaml b/.github/workflows/auto-release.yaml deleted file mode 100644 index 7a106d00..00000000 --- a/.github/workflows/auto-release.yaml +++ /dev/null @@ -1,103 +0,0 @@ -# Copyright 2022 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# Github action job to test core java library features on -# downstream client libraries before they are released. -on: - pull_request: -name: auto-release -jobs: - approve: - runs-on: ubuntu-latest - if: contains(github.head_ref, 'release-please') - steps: - - uses: actions/github-script@v6 - with: - github-token: ${{secrets.YOSHI_APPROVER_TOKEN}} - debug: true - script: | - // only approve PRs from release-please[bot] - if (context.payload.pull_request.user.login !== "release-please[bot]") { - return; - } - - // only approve PRs like "chore(main): release " - if ( !context.payload.pull_request.title.startsWith("chore(main): release") ) { - return; - } - - // only approve PRs with pom.xml and versions.txt changes - const filesPromise = github.rest.pulls.listFiles.endpoint({ - owner: context.repo.owner, - repo: context.repo.repo, - pull_number: context.payload.pull_request.number, - }); - const changed_files = await github.paginate(filesPromise) - - if ( changed_files.length < 1 ) { - console.log( "Not proceeding since PR is empty!" ) - return; - } - - if ( !changed_files.some(v => v.filename.includes("pom")) || !changed_files.some(v => v.filename.includes("versions.txt")) ) { - console.log( "PR file changes do not have pom.xml or versions.txt -- something is wrong. PTAL!" ) - return; - } - - // trigger auto-release when - // 1) it is a SNAPSHOT release (auto-generated post regular release) - // 2) there are dependency updates only - // 3) there are no open dependency update PRs in this repo (to avoid multiple releases) - if ( - context.payload.pull_request.body.includes("Fix") || - context.payload.pull_request.body.includes("Build") || - context.payload.pull_request.body.includes("Documentation") || - context.payload.pull_request.body.includes("BREAKING CHANGES") || - context.payload.pull_request.body.includes("Features") - ) { - console.log( "Not auto-releasing since it is not a dependency-update-only release." ); - return; - } - - const promise = github.rest.pulls.list.endpoint({ - owner: context.repo.owner, - repo: context.repo.repo, - state: 'open' - }); - const open_pulls = await github.paginate(promise) - - if ( open_pulls.length > 1 && !context.payload.pull_request.title.includes("SNAPSHOT") ) { - for ( const pull of open_pulls ) { - if ( pull.title.startsWith("deps: update dependency") ) { - console.log( "Not auto-releasing yet since there are dependency update PRs open in this repo." ); - return; - } - } - } - - // approve release PR - await github.rest.pulls.createReview({ - owner: context.repo.owner, - repo: context.repo.repo, - body: 'Rubber stamped release!', - pull_number: context.payload.pull_request.number, - event: 'APPROVE' - }); - - // attach kokoro:force-run and automerge labels - await github.rest.issues.addLabels({ - owner: context.repo.owner, - repo: context.repo.repo, - issue_number: context.payload.pull_request.number, - labels: ['kokoro:force-run', 'automerge'] - }); diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml deleted file mode 100644 index e3bb26e3..00000000 --- a/.github/workflows/ci.yaml +++ /dev/null @@ -1,89 +0,0 @@ -# Copyright 2022 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# Github action job to test core java library features on -# downstream client libraries before they are released. -on: - push: - branches: - - main - pull_request: -name: ci -jobs: - units: - runs-on: ubuntu-latest - strategy: - fail-fast: false - matrix: - java: [8, 11, 17] - steps: - - uses: actions/checkout@v3 - - uses: actions/setup-java@v3 - with: - distribution: zulu - java-version: ${{matrix.java}} - - run: java -version - - run: .kokoro/build.sh - env: - JOB_TYPE: test - windows: - runs-on: windows-latest - steps: - - name: Support longpaths - run: git config --system core.longpaths true - - uses: actions/checkout@v3 - - uses: actions/setup-java@v3 - with: - distribution: zulu - java-version: 8 - - run: java -version - - run: .kokoro/build.bat - env: - JOB_TYPE: test - dependencies: - runs-on: ubuntu-latest - strategy: - matrix: - java: [8, 11, 17] - steps: - - uses: actions/checkout@v3 - - uses: actions/setup-java@v3 - with: - distribution: zulu - java-version: ${{matrix.java}} - - run: java -version - - run: .kokoro/dependencies.sh - lint: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v3 - - uses: actions/setup-java@v3 - with: - distribution: zulu - java-version: 11 - - run: java -version - - run: .kokoro/build.sh - env: - JOB_TYPE: lint - clirr: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v3 - - uses: actions/setup-java@v3 - with: - distribution: zulu - java-version: 8 - - run: java -version - - run: .kokoro/build.sh - env: - JOB_TYPE: clirr diff --git a/.github/workflows/samples.yaml b/.github/workflows/samples.yaml deleted file mode 100644 index 912ed8b2..00000000 --- a/.github/workflows/samples.yaml +++ /dev/null @@ -1,30 +0,0 @@ -# Copyright 2022 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# Github action job to test core java library features on -# downstream client libraries before they are released. -on: - pull_request: -name: samples -jobs: - checkstyle: - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v3 - - uses: actions/setup-java@v3 - with: - distribution: zulu - java-version: 8 - - name: Run checkstyle - run: mvn -P lint --quiet --batch-mode checkstyle:check - working-directory: samples/snippets diff --git a/.gitignore b/.gitignore deleted file mode 100644 index 88e95bf2..00000000 --- a/.gitignore +++ /dev/null @@ -1,34 +0,0 @@ -.gitignore - -# Packages -dist -bin -var -sdist -target - -# Unit test / coverage reports -.coverage -.tox -nosetests.xml - -# Translations -*.mo - -# Mr Developer -.mr.developer.cfg -.project -.pydevproject -*.iml -.idea -.settings -.DS_Store -.classpath - -# Built documentation -docs/ - -# Python utilities -*.pyc - -.flattened-pom.xml diff --git a/.kokoro/build.bat b/.kokoro/build.bat deleted file mode 100644 index 067cf4a4..00000000 --- a/.kokoro/build.bat +++ /dev/null @@ -1,18 +0,0 @@ -:: Copyright 2022 Google LLC -:: -:: Licensed under the Apache License, Version 2.0 (the "License"); -:: you may not use this file except in compliance with the License. -:: You may obtain a copy of the License at -:: -:: http://www.apache.org/licenses/LICENSE-2.0 -:: -:: Unless required by applicable law or agreed to in writing, software -:: distributed under the License is distributed on an "AS IS" BASIS, -:: WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -:: See the License for the specific language governing permissions and -:: limitations under the License. -:: Github action job to test core java library features on -:: downstream client libraries before they are released. -:: See documentation in type-shell-output.bat - -"C:\Program Files\Git\bin\bash.exe" %~dp0build.sh diff --git a/.kokoro/build.sh b/.kokoro/build.sh deleted file mode 100755 index cd70b508..00000000 --- a/.kokoro/build.sh +++ /dev/null @@ -1,134 +0,0 @@ -#!/bin/bash -# Copyright 2019 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -set -eo pipefail - -## Get the directory of the build script -scriptDir=$(realpath $(dirname "${BASH_SOURCE[0]}")) -## cd to the parent directory, i.e. the root of the git repo -cd ${scriptDir}/.. - -# include common functions -source ${scriptDir}/common.sh - -# Print out Maven & Java version -mvn -version -echo ${JOB_TYPE} - -# attempt to install 3 times with exponential backoff (starting with 10 seconds) -retry_with_backoff 3 10 \ - mvn install -B -V -ntp \ - -DskipTests=true \ - -Dclirr.skip=true \ - -Denforcer.skip=true \ - -Dmaven.javadoc.skip=true \ - -Dgcloud.download.skip=true \ - -T 1C - -# if GOOGLE_APPLICATION_CREDENTIALS is specified as a relative path, prepend Kokoro root directory onto it -if [[ ! -z "${GOOGLE_APPLICATION_CREDENTIALS}" && "${GOOGLE_APPLICATION_CREDENTIALS}" != /* ]]; then - export GOOGLE_APPLICATION_CREDENTIALS=$(realpath ${KOKORO_GFILE_DIR}/${GOOGLE_APPLICATION_CREDENTIALS}) -fi - -RETURN_CODE=0 -set +e - -case ${JOB_TYPE} in -test) - mvn test -B -ntp -Dclirr.skip=true -Denforcer.skip=true - RETURN_CODE=$? - ;; -lint) - mvn com.coveo:fmt-maven-plugin:check -B -ntp - RETURN_CODE=$? - ;; -javadoc) - mvn javadoc:javadoc javadoc:test-javadoc -B -ntp - RETURN_CODE=$? - ;; -integration) - mvn -B ${INTEGRATION_TEST_ARGS} \ - -ntp \ - -Penable-integration-tests \ - -DtrimStackTrace=false \ - -Dclirr.skip=true \ - -Denforcer.skip=true \ - -fae \ - verify - RETURN_CODE=$? - ;; -graalvm) - # Run Unit and Integration Tests with Native Image - mvn -B ${INTEGRATION_TEST_ARGS} -ntp -Pnative -Penable-integration-tests test - RETURN_CODE=$? - ;; -graalvm17) - # Run Unit and Integration Tests with Native Image - mvn -B ${INTEGRATION_TEST_ARGS} -ntp -Pnative -Penable-integration-tests test - RETURN_CODE=$? - ;; -samples) - SAMPLES_DIR=samples - # only run ITs in snapshot/ on presubmit PRs. run ITs in all 3 samples/ subdirectories otherwise. - if [[ ! -z ${KOKORO_GITHUB_PULL_REQUEST_NUMBER} ]] - then - SAMPLES_DIR=samples/snapshot - fi - - if [[ -f ${SAMPLES_DIR}/pom.xml ]] - then - for FILE in ${KOKORO_GFILE_DIR}/secret_manager/*-samples-secrets; do - [[ -f "$FILE" ]] || continue - source "$FILE" - done - - pushd ${SAMPLES_DIR} - mvn -B \ - -ntp \ - -DtrimStackTrace=false \ - -Dclirr.skip=true \ - -Denforcer.skip=true \ - -fae \ - verify - RETURN_CODE=$? - popd - else - echo "no sample pom.xml found - skipping sample tests" - fi - ;; -clirr) - mvn -B -ntp -Denforcer.skip=true clirr:check - RETURN_CODE=$? - ;; -*) - ;; -esac - -if [ "${REPORT_COVERAGE}" == "true" ] -then - bash ${KOKORO_GFILE_DIR}/codecov.sh -fi - -# fix output location of logs -bash .kokoro/coerce_logs.sh - -if [[ "${ENABLE_FLAKYBOT}" == "true" ]] -then - chmod +x ${KOKORO_GFILE_DIR}/linux_amd64/flakybot - ${KOKORO_GFILE_DIR}/linux_amd64/flakybot -repo=googleapis/java-cloudbuild -fi - -echo "exiting with ${RETURN_CODE}" -exit ${RETURN_CODE} diff --git a/.kokoro/coerce_logs.sh b/.kokoro/coerce_logs.sh deleted file mode 100755 index 46edbf7f..00000000 --- a/.kokoro/coerce_logs.sh +++ /dev/null @@ -1,37 +0,0 @@ -#!/bin/bash -# Copyright 2019 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -# This script finds and moves sponge logs so that they can be found by placer -# and are not flagged as flaky by sponge. - -set -eo pipefail - -## Get the directory of the build script -scriptDir=$(realpath $(dirname "${BASH_SOURCE[0]}")) -## cd to the parent directory, i.e. the root of the git repo -cd ${scriptDir}/.. - -job=$(basename ${KOKORO_JOB_NAME}) - -echo "coercing sponge logs..." -for xml in `find . -name *-sponge_log.xml` -do - class=$(basename ${xml} | cut -d- -f2) - dir=$(dirname ${xml})/${job}/${class} - text=$(dirname ${xml})/${class}-sponge_log.txt - mkdir -p ${dir} - mv ${xml} ${dir}/sponge_log.xml - mv ${text} ${dir}/sponge_log.txt -done diff --git a/.kokoro/common.cfg b/.kokoro/common.cfg deleted file mode 100644 index ab7cf2c0..00000000 --- a/.kokoro/common.cfg +++ /dev/null @@ -1,13 +0,0 @@ -# Format: //devtools/kokoro/config/proto/build.proto - -# Download trampoline resources. These will be in ${KOKORO_GFILE_DIR} -gfile_resources: "/bigstore/cloud-devrel-kokoro-resources/trampoline" - -# All builds use the trampoline script to run in docker. -build_file: "java-cloudbuild/.kokoro/trampoline.sh" - -# Tell the trampoline which build file to use. -env_vars: { - key: "TRAMPOLINE_BUILD_FILE" - value: "github/java-cloudbuild/.kokoro/build.sh" -} diff --git a/.kokoro/common.sh b/.kokoro/common.sh deleted file mode 100644 index f8f957af..00000000 --- a/.kokoro/common.sh +++ /dev/null @@ -1,60 +0,0 @@ -#!/bin/bash -# Copyright 2020 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -function retry_with_backoff { - attempts_left=$1 - sleep_seconds=$2 - shift 2 - command=$@ - - - # store current flag state - flags=$- - - # allow a failures to continue - set +e - ${command} - exit_code=$? - - # restore "e" flag - if [[ ${flags} =~ e ]] - then set -e - else set +e - fi - - if [[ $exit_code == 0 ]] - then - return 0 - fi - - # failure - if [[ ${attempts_left} > 0 ]] - then - echo "failure (${exit_code}), sleeping ${sleep_seconds}..." - sleep ${sleep_seconds} - new_attempts=$((${attempts_left} - 1)) - new_sleep=$((${sleep_seconds} * 2)) - retry_with_backoff ${new_attempts} ${new_sleep} ${command} - fi - - return $exit_code -} - -## Helper functionss -function now() { date +"%Y-%m-%d %H:%M:%S" | tr -d '\n'; } -function msg() { println "$*" >&2; } -function println() { printf '%s\n' "$(now) $*"; } - -## Helper comment to trigger updated repo dependency release \ No newline at end of file diff --git a/.kokoro/continuous/common.cfg b/.kokoro/continuous/common.cfg deleted file mode 100644 index e4ee0a47..00000000 --- a/.kokoro/continuous/common.cfg +++ /dev/null @@ -1,25 +0,0 @@ -# Format: //devtools/kokoro/config/proto/build.proto - -# Build logs will be here -action { - define_artifacts { - regex: "**/*sponge_log.xml" - regex: "**/*sponge_log.txt" - } -} - -# Download trampoline resources. -gfile_resources: "/bigstore/cloud-devrel-kokoro-resources/trampoline" - -# Use the trampoline script to run in docker. -build_file: "java-cloudbuild/.kokoro/trampoline.sh" - -env_vars: { - key: "TRAMPOLINE_BUILD_FILE" - value: "github/java-cloudbuild/.kokoro/build.sh" -} - -env_vars: { - key: "JOB_TYPE" - value: "test" -} diff --git a/.kokoro/continuous/java8.cfg b/.kokoro/continuous/java8.cfg deleted file mode 100644 index 495cc7ba..00000000 --- a/.kokoro/continuous/java8.cfg +++ /dev/null @@ -1,12 +0,0 @@ -# Format: //devtools/kokoro/config/proto/build.proto - -# Configure the docker image for kokoro-trampoline. -env_vars: { - key: "TRAMPOLINE_IMAGE" - value: "gcr.io/cloud-devrel-kokoro-resources/java8" -} - -env_vars: { - key: "REPORT_COVERAGE" - value: "true" -} diff --git a/.kokoro/continuous/propose_release.sh b/.kokoro/continuous/propose_release.sh deleted file mode 100755 index c448c7db..00000000 --- a/.kokoro/continuous/propose_release.sh +++ /dev/null @@ -1,29 +0,0 @@ -#!/bin/bash - -# Copyright 2019 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -set -eo pipefail - -export NPM_CONFIG_PREFIX=/home/node/.npm-global - -if [ -f ${KOKORO_KEYSTORE_DIR}/73713_github-magic-proxy-url-release-please ]; then - # Groom the release PR as new commits are merged. - npx release-please release-pr --token=${KOKORO_KEYSTORE_DIR}/73713_github-magic-proxy-token-release-please \ - --repo-url=googleapis/java-cloudbuild \ - --package-name="build" \ - --api-url=${KOKORO_KEYSTORE_DIR}/73713_github-magic-proxy-url-release-please \ - --proxy-key=${KOKORO_KEYSTORE_DIR}/73713_github-magic-proxy-key-release-please \ - --release-type=java-yoshi -fi diff --git a/.kokoro/dependencies.sh b/.kokoro/dependencies.sh deleted file mode 100755 index bd896024..00000000 --- a/.kokoro/dependencies.sh +++ /dev/null @@ -1,59 +0,0 @@ -#!/bin/bash -# Copyright 2019 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -set -eo pipefail -shopt -s nullglob - -## Get the directory of the build script -scriptDir=$(realpath $(dirname "${BASH_SOURCE[0]}")) -## cd to the parent directory, i.e. the root of the git repo -cd ${scriptDir}/.. - -# include common functions -source ${scriptDir}/common.sh - -# Print out Java -java -version -echo $JOB_TYPE - -function determineMavenOpts() { - local javaVersion=$( - # filter down to the version line, then pull out the version between quotes, - # then trim the version number down to its minimal number (removing any - # update or suffix number). - java -version 2>&1 | grep "version" \ - | sed -E 's/^.*"(.*?)".*$/\1/g' \ - | sed -E 's/^(1\.[0-9]\.0).*$/\1/g' - ) - - if [[ $javaVersion == 17* ]] - then - # MaxPermSize is no longer supported as of jdk 17 - echo -n "-Xmx1024m" - else - echo -n "-Xmx1024m -XX:MaxPermSize=128m" - fi -} - -export MAVEN_OPTS=$(determineMavenOpts) - -# this should run maven enforcer -retry_with_backoff 3 10 \ - mvn install -B -V -ntp \ - -DskipTests=true \ - -Dmaven.javadoc.skip=true \ - -Dclirr.skip=true - -mvn -B dependency:analyze -DfailOnWarning=true diff --git a/.kokoro/nightly/common.cfg b/.kokoro/nightly/common.cfg deleted file mode 100644 index e4ee0a47..00000000 --- a/.kokoro/nightly/common.cfg +++ /dev/null @@ -1,25 +0,0 @@ -# Format: //devtools/kokoro/config/proto/build.proto - -# Build logs will be here -action { - define_artifacts { - regex: "**/*sponge_log.xml" - regex: "**/*sponge_log.txt" - } -} - -# Download trampoline resources. -gfile_resources: "/bigstore/cloud-devrel-kokoro-resources/trampoline" - -# Use the trampoline script to run in docker. -build_file: "java-cloudbuild/.kokoro/trampoline.sh" - -env_vars: { - key: "TRAMPOLINE_BUILD_FILE" - value: "github/java-cloudbuild/.kokoro/build.sh" -} - -env_vars: { - key: "JOB_TYPE" - value: "test" -} diff --git a/.kokoro/nightly/integration.cfg b/.kokoro/nightly/integration.cfg deleted file mode 100644 index bd0297a3..00000000 --- a/.kokoro/nightly/integration.cfg +++ /dev/null @@ -1,37 +0,0 @@ -# Format: //devtools/kokoro/config/proto/build.proto - -# Configure the docker image for kokoro-trampoline. -env_vars: { - key: "TRAMPOLINE_IMAGE" - value: "gcr.io/cloud-devrel-kokoro-resources/java8" -} - -env_vars: { - key: "JOB_TYPE" - value: "integration" -} -# TODO: remove this after we've migrated all tests and scripts -env_vars: { - key: "GCLOUD_PROJECT" - value: "java-docs-samples-testing" -} - -env_vars: { - key: "GOOGLE_CLOUD_PROJECT" - value: "java-docs-samples-testing" -} - -env_vars: { - key: "ENABLE_FLAKYBOT" - value: "false" -} - -env_vars: { - key: "GOOGLE_APPLICATION_CREDENTIALS" - value: "secret_manager/java-it-service-account" -} - -env_vars: { - key: "SECRET_MANAGER_KEYS" - value: "java-it-service-account" -} diff --git a/.kokoro/nightly/java11-integration.cfg b/.kokoro/nightly/java11-integration.cfg deleted file mode 100644 index dc51b65e..00000000 --- a/.kokoro/nightly/java11-integration.cfg +++ /dev/null @@ -1,37 +0,0 @@ -# Format: //devtools/kokoro/config/proto/build.proto - -# Configure the docker image for kokoro-trampoline. -env_vars: { - key: "TRAMPOLINE_IMAGE" - value: "gcr.io/cloud-devrel-public-resources/java11014" -} - -env_vars: { - key: "JOB_TYPE" - value: "integration" -} -# TODO: remove this after we've migrated all tests and scripts -env_vars: { - key: "GCLOUD_PROJECT" - value: "gcloud-devel" -} - -env_vars: { - key: "GOOGLE_CLOUD_PROJECT" - value: "gcloud-devel" -} - -env_vars: { - key: "ENABLE_FLAKYBOT" - value: "false" -} - -env_vars: { - key: "GOOGLE_APPLICATION_CREDENTIALS" - value: "secret_manager/java-it-service-account" -} - -env_vars: { - key: "SECRET_MANAGER_KEYS" - value: "java-it-service-account" -} diff --git a/.kokoro/nightly/java11.cfg b/.kokoro/nightly/java11.cfg deleted file mode 100644 index 709f2b4c..00000000 --- a/.kokoro/nightly/java11.cfg +++ /dev/null @@ -1,7 +0,0 @@ -# Format: //devtools/kokoro/config/proto/build.proto - -# Configure the docker image for kokoro-trampoline. -env_vars: { - key: "TRAMPOLINE_IMAGE" - value: "gcr.io/cloud-devrel-kokoro-resources/java11" -} diff --git a/.kokoro/nightly/java7.cfg b/.kokoro/nightly/java7.cfg deleted file mode 100644 index cb24f44e..00000000 --- a/.kokoro/nightly/java7.cfg +++ /dev/null @@ -1,7 +0,0 @@ -# Format: //devtools/kokoro/config/proto/build.proto - -# Configure the docker image for kokoro-trampoline. -env_vars: { - key: "TRAMPOLINE_IMAGE" - value: "gcr.io/cloud-devrel-kokoro-resources/java7" -} diff --git a/.kokoro/nightly/java8-osx.cfg b/.kokoro/nightly/java8-osx.cfg deleted file mode 100644 index 2064140d..00000000 --- a/.kokoro/nightly/java8-osx.cfg +++ /dev/null @@ -1,3 +0,0 @@ -# Format: //devtools/kokoro/config/proto/build.proto - -build_file: "java-cloudbuild/.kokoro/build.sh" diff --git a/.kokoro/nightly/java8-win.cfg b/.kokoro/nightly/java8-win.cfg deleted file mode 100644 index 6dcfaa91..00000000 --- a/.kokoro/nightly/java8-win.cfg +++ /dev/null @@ -1,3 +0,0 @@ -# Format: //devtools/kokoro/config/proto/build.proto - -build_file: "java-cloudbuild/.kokoro/build.bat" diff --git a/.kokoro/nightly/java8.cfg b/.kokoro/nightly/java8.cfg deleted file mode 100644 index 495cc7ba..00000000 --- a/.kokoro/nightly/java8.cfg +++ /dev/null @@ -1,12 +0,0 @@ -# Format: //devtools/kokoro/config/proto/build.proto - -# Configure the docker image for kokoro-trampoline. -env_vars: { - key: "TRAMPOLINE_IMAGE" - value: "gcr.io/cloud-devrel-kokoro-resources/java8" -} - -env_vars: { - key: "REPORT_COVERAGE" - value: "true" -} diff --git a/.kokoro/nightly/samples.cfg b/.kokoro/nightly/samples.cfg deleted file mode 100644 index fee6a838..00000000 --- a/.kokoro/nightly/samples.cfg +++ /dev/null @@ -1,38 +0,0 @@ -# Format: //devtools/kokoro/config/proto/build.proto - -# Configure the docker image for kokoro-trampoline. -env_vars: { - key: "TRAMPOLINE_IMAGE" - value: "gcr.io/cloud-devrel-kokoro-resources/java8" -} - -env_vars: { - key: "JOB_TYPE" - value: "samples" -} - -# TODO: remove this after we've migrated all tests and scripts -env_vars: { - key: "GCLOUD_PROJECT" - value: "java-docs-samples-testing" -} - -env_vars: { - key: "GOOGLE_CLOUD_PROJECT" - value: "java-docs-samples-testing" -} - -env_vars: { - key: "GOOGLE_APPLICATION_CREDENTIALS" - value: "secret_manager/java-docs-samples-service-account" -} - -env_vars: { - key: "SECRET_MANAGER_KEYS" - value: "java-docs-samples-service-account" -} - -env_vars: { - key: "ENABLE_FLAKYBOT" - value: "false" -} diff --git a/.kokoro/populate-secrets.sh b/.kokoro/populate-secrets.sh deleted file mode 100755 index f5251425..00000000 --- a/.kokoro/populate-secrets.sh +++ /dev/null @@ -1,43 +0,0 @@ -#!/bin/bash -# Copyright 2020 Google LLC. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -set -eo pipefail - -function now { date +"%Y-%m-%d %H:%M:%S" | tr -d '\n' ;} -function msg { println "$*" >&2 ;} -function println { printf '%s\n' "$(now) $*" ;} - - -# Populates requested secrets set in SECRET_MANAGER_KEYS from service account: -# kokoro-trampoline@cloud-devrel-kokoro-resources.iam.gserviceaccount.com -SECRET_LOCATION="${KOKORO_GFILE_DIR}/secret_manager" -msg "Creating folder on disk for secrets: ${SECRET_LOCATION}" -mkdir -p ${SECRET_LOCATION} -for key in $(echo ${SECRET_MANAGER_KEYS} | sed "s/,/ /g") -do - msg "Retrieving secret ${key}" - docker run --entrypoint=gcloud \ - --volume=${KOKORO_GFILE_DIR}:${KOKORO_GFILE_DIR} \ - gcr.io/google.com/cloudsdktool/cloud-sdk \ - secrets versions access latest \ - --project cloud-devrel-kokoro-resources \ - --secret ${key} > \ - "${SECRET_LOCATION}/${key}" - if [[ $? == 0 ]]; then - msg "Secret written to ${SECRET_LOCATION}/${key}" - else - msg "Error retrieving secret ${key}" - fi -done diff --git a/.kokoro/presubmit/clirr.cfg b/.kokoro/presubmit/clirr.cfg deleted file mode 100644 index ec572442..00000000 --- a/.kokoro/presubmit/clirr.cfg +++ /dev/null @@ -1,13 +0,0 @@ -# Format: //devtools/kokoro/config/proto/build.proto - -# Configure the docker image for kokoro-trampoline. - -env_vars: { - key: "TRAMPOLINE_IMAGE" - value: "gcr.io/cloud-devrel-kokoro-resources/java8" -} - -env_vars: { - key: "JOB_TYPE" - value: "clirr" -} \ No newline at end of file diff --git a/.kokoro/presubmit/common.cfg b/.kokoro/presubmit/common.cfg deleted file mode 100644 index 4205e644..00000000 --- a/.kokoro/presubmit/common.cfg +++ /dev/null @@ -1,34 +0,0 @@ -# Format: //devtools/kokoro/config/proto/build.proto - -# Build logs will be here -action { - define_artifacts { - regex: "**/*sponge_log.xml" - regex: "**/*sponge_log.txt" - } -} - -# Download trampoline resources. -gfile_resources: "/bigstore/cloud-devrel-kokoro-resources/trampoline" - -# Use the trampoline script to run in docker. -build_file: "java-cloudbuild/.kokoro/trampoline.sh" - -env_vars: { - key: "TRAMPOLINE_BUILD_FILE" - value: "github/java-cloudbuild/.kokoro/build.sh" -} - -env_vars: { - key: "JOB_TYPE" - value: "test" -} - -before_action { - fetch_keystore { - keystore_resource { - keystore_config_id: 73713 - keyname: "dpebot_codecov_token" - } - } -} diff --git a/.kokoro/presubmit/dependencies.cfg b/.kokoro/presubmit/dependencies.cfg deleted file mode 100644 index 1b805461..00000000 --- a/.kokoro/presubmit/dependencies.cfg +++ /dev/null @@ -1,12 +0,0 @@ -# Format: //devtools/kokoro/config/proto/build.proto - -# Configure the docker image for kokoro-trampoline. -env_vars: { - key: "TRAMPOLINE_IMAGE" - value: "gcr.io/cloud-devrel-kokoro-resources/java8" -} - -env_vars: { - key: "TRAMPOLINE_BUILD_FILE" - value: "github/java-cloudbuild/.kokoro/dependencies.sh" -} diff --git a/.kokoro/presubmit/graalvm-native-17.cfg b/.kokoro/presubmit/graalvm-native-17.cfg deleted file mode 100644 index a3f7fb9d..00000000 --- a/.kokoro/presubmit/graalvm-native-17.cfg +++ /dev/null @@ -1,33 +0,0 @@ -# Format: //devtools/kokoro/config/proto/build.proto - -# Configure the docker image for kokoro-trampoline. -env_vars: { - key: "TRAMPOLINE_IMAGE" - value: "gcr.io/cloud-devrel-kokoro-resources/graalvm17" -} - -env_vars: { - key: "JOB_TYPE" - value: "graalvm17" -} - -# TODO: remove this after we've migrated all tests and scripts -env_vars: { - key: "GCLOUD_PROJECT" - value: "gcloud-devel" -} - -env_vars: { - key: "GOOGLE_CLOUD_PROJECT" - value: "gcloud-devel" -} - -env_vars: { - key: "GOOGLE_APPLICATION_CREDENTIALS" - value: "secret_manager/java-it-service-account" -} - -env_vars: { - key: "SECRET_MANAGER_KEYS" - value: "java-it-service-account" -} \ No newline at end of file diff --git a/.kokoro/presubmit/graalvm-native.cfg b/.kokoro/presubmit/graalvm-native.cfg deleted file mode 100644 index 4c7225ec..00000000 --- a/.kokoro/presubmit/graalvm-native.cfg +++ /dev/null @@ -1,33 +0,0 @@ -# Format: //devtools/kokoro/config/proto/build.proto - -# Configure the docker image for kokoro-trampoline. -env_vars: { - key: "TRAMPOLINE_IMAGE" - value: "gcr.io/cloud-devrel-kokoro-resources/graalvm" -} - -env_vars: { - key: "JOB_TYPE" - value: "graalvm" -} - -# TODO: remove this after we've migrated all tests and scripts -env_vars: { - key: "GCLOUD_PROJECT" - value: "gcloud-devel" -} - -env_vars: { - key: "GOOGLE_CLOUD_PROJECT" - value: "gcloud-devel" -} - -env_vars: { - key: "GOOGLE_APPLICATION_CREDENTIALS" - value: "secret_manager/java-it-service-account" -} - -env_vars: { - key: "SECRET_MANAGER_KEYS" - value: "java-it-service-account" -} diff --git a/.kokoro/presubmit/integration.cfg b/.kokoro/presubmit/integration.cfg deleted file mode 100644 index dded67a9..00000000 --- a/.kokoro/presubmit/integration.cfg +++ /dev/null @@ -1,33 +0,0 @@ -# Format: //devtools/kokoro/config/proto/build.proto - -# Configure the docker image for kokoro-trampoline. -env_vars: { - key: "TRAMPOLINE_IMAGE" - value: "gcr.io/cloud-devrel-kokoro-resources/java8" -} - -env_vars: { - key: "JOB_TYPE" - value: "integration" -} - -# TODO: remove this after we've migrated all tests and scripts -env_vars: { - key: "GCLOUD_PROJECT" - value: "gcloud-devel" -} - -env_vars: { - key: "GOOGLE_CLOUD_PROJECT" - value: "gcloud-devel" -} - -env_vars: { - key: "GOOGLE_APPLICATION_CREDENTIALS" - value: "secret_manager/java-it-service-account" -} - -env_vars: { - key: "SECRET_MANAGER_KEYS" - value: "java-it-service-account" -} diff --git a/.kokoro/presubmit/java11.cfg b/.kokoro/presubmit/java11.cfg deleted file mode 100644 index 709f2b4c..00000000 --- a/.kokoro/presubmit/java11.cfg +++ /dev/null @@ -1,7 +0,0 @@ -# Format: //devtools/kokoro/config/proto/build.proto - -# Configure the docker image for kokoro-trampoline. -env_vars: { - key: "TRAMPOLINE_IMAGE" - value: "gcr.io/cloud-devrel-kokoro-resources/java11" -} diff --git a/.kokoro/presubmit/java7.cfg b/.kokoro/presubmit/java7.cfg deleted file mode 100644 index cb24f44e..00000000 --- a/.kokoro/presubmit/java7.cfg +++ /dev/null @@ -1,7 +0,0 @@ -# Format: //devtools/kokoro/config/proto/build.proto - -# Configure the docker image for kokoro-trampoline. -env_vars: { - key: "TRAMPOLINE_IMAGE" - value: "gcr.io/cloud-devrel-kokoro-resources/java7" -} diff --git a/.kokoro/presubmit/java8-osx.cfg b/.kokoro/presubmit/java8-osx.cfg deleted file mode 100644 index 2064140d..00000000 --- a/.kokoro/presubmit/java8-osx.cfg +++ /dev/null @@ -1,3 +0,0 @@ -# Format: //devtools/kokoro/config/proto/build.proto - -build_file: "java-cloudbuild/.kokoro/build.sh" diff --git a/.kokoro/presubmit/java8-win.cfg b/.kokoro/presubmit/java8-win.cfg deleted file mode 100644 index 6dcfaa91..00000000 --- a/.kokoro/presubmit/java8-win.cfg +++ /dev/null @@ -1,3 +0,0 @@ -# Format: //devtools/kokoro/config/proto/build.proto - -build_file: "java-cloudbuild/.kokoro/build.bat" diff --git a/.kokoro/presubmit/java8.cfg b/.kokoro/presubmit/java8.cfg deleted file mode 100644 index 495cc7ba..00000000 --- a/.kokoro/presubmit/java8.cfg +++ /dev/null @@ -1,12 +0,0 @@ -# Format: //devtools/kokoro/config/proto/build.proto - -# Configure the docker image for kokoro-trampoline. -env_vars: { - key: "TRAMPOLINE_IMAGE" - value: "gcr.io/cloud-devrel-kokoro-resources/java8" -} - -env_vars: { - key: "REPORT_COVERAGE" - value: "true" -} diff --git a/.kokoro/presubmit/linkage-monitor.cfg b/.kokoro/presubmit/linkage-monitor.cfg deleted file mode 100644 index 091bb22a..00000000 --- a/.kokoro/presubmit/linkage-monitor.cfg +++ /dev/null @@ -1,12 +0,0 @@ -# Format: //devtools/kokoro/config/proto/build.proto - -# Configure the docker image for kokoro-trampoline. -env_vars: { - key: "TRAMPOLINE_IMAGE" - value: "gcr.io/cloud-devrel-kokoro-resources/java8" -} - -env_vars: { - key: "TRAMPOLINE_BUILD_FILE" - value: "github/java-cloudbuild/.kokoro/linkage-monitor.sh" -} \ No newline at end of file diff --git a/.kokoro/presubmit/lint.cfg b/.kokoro/presubmit/lint.cfg deleted file mode 100644 index 6d323c8a..00000000 --- a/.kokoro/presubmit/lint.cfg +++ /dev/null @@ -1,13 +0,0 @@ -# Format: //devtools/kokoro/config/proto/build.proto - -# Configure the docker image for kokoro-trampoline. - -env_vars: { - key: "TRAMPOLINE_IMAGE" - value: "gcr.io/cloud-devrel-kokoro-resources/java8" -} - -env_vars: { - key: "JOB_TYPE" - value: "lint" -} \ No newline at end of file diff --git a/.kokoro/presubmit/samples.cfg b/.kokoro/presubmit/samples.cfg deleted file mode 100644 index 01e09600..00000000 --- a/.kokoro/presubmit/samples.cfg +++ /dev/null @@ -1,33 +0,0 @@ -# Format: //devtools/kokoro/config/proto/build.proto - -# Configure the docker image for kokoro-trampoline. -env_vars: { - key: "TRAMPOLINE_IMAGE" - value: "gcr.io/cloud-devrel-kokoro-resources/java8" -} - -env_vars: { - key: "JOB_TYPE" - value: "samples" -} - -# TODO: remove this after we've migrated all tests and scripts -env_vars: { - key: "GCLOUD_PROJECT" - value: "java-docs-samples-testing" -} - -env_vars: { - key: "GOOGLE_CLOUD_PROJECT" - value: "java-docs-samples-testing" -} - -env_vars: { - key: "GOOGLE_APPLICATION_CREDENTIALS" - value: "secret_manager/java-docs-samples-service-account" -} - -env_vars: { - key: "SECRET_MANAGER_KEYS" - value: "java-docs-samples-service-account" -} \ No newline at end of file diff --git a/.kokoro/readme.sh b/.kokoro/readme.sh deleted file mode 100755 index b574d297..00000000 --- a/.kokoro/readme.sh +++ /dev/null @@ -1,45 +0,0 @@ -#!/bin/bash -# Copyright 2020 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -set -eo pipefail - -cd ${KOKORO_ARTIFACTS_DIR}/github/java-cloudbuild - -# Disable buffering, so that the logs stream through. -export PYTHONUNBUFFERED=1 - -# Kokoro exposes this as a file, but the scripts expect just a plain variable. -export GITHUB_TOKEN=$(cat ${KOKORO_KEYSTORE_DIR}/73713_yoshi-automation-github-key) - -# Setup git credentials -echo "https://${GITHUB_TOKEN}:@github.com" >> ~/.git-credentials -git config --global credential.helper 'store --file ~/.git-credentials' - -python3.6 -m pip install git+https://github.com/googleapis/synthtool.git#egg=gcp-synthtool - -set +e -python3.6 -m autosynth.synth \ - --repository=googleapis/java-cloudbuild \ - --synth-file-name=.github/readme/synth.py \ - --metadata-path=.github/readme/synth.metadata \ - --pr-title="chore: regenerate README" \ - --branch-suffix="readme" - -# autosynth returns 28 to signal there are no changes -RETURN_CODE=$? -if [[ ${RETURN_CODE} -ne 0 && ${RETURN_CODE} -ne 28 ]] -then - exit ${RETURN_CODE} -fi diff --git a/.kokoro/release/bump_snapshot.cfg b/.kokoro/release/bump_snapshot.cfg deleted file mode 100644 index 3ec51c7b..00000000 --- a/.kokoro/release/bump_snapshot.cfg +++ /dev/null @@ -1,53 +0,0 @@ -# Format: //devtools/kokoro/config/proto/build.proto - -# Build logs will be here -action { - define_artifacts { - regex: "**/*sponge_log.xml" - } -} - -# Download trampoline resources. -gfile_resources: "/bigstore/cloud-devrel-kokoro-resources/trampoline" - -# Use the trampoline script to run in docker. -build_file: "java-cloudbuild/.kokoro/trampoline.sh" - -# Configure the docker image for kokoro-trampoline. -env_vars: { - key: "TRAMPOLINE_IMAGE" - value: "gcr.io/cloud-devrel-kokoro-resources/node:10-user" -} - -env_vars: { - key: "TRAMPOLINE_BUILD_FILE" - value: "github/java-cloudbuild/.kokoro/release/bump_snapshot.sh" -} - -# tokens used by release-please to keep an up-to-date release PR. -before_action { - fetch_keystore { - keystore_resource { - keystore_config_id: 73713 - keyname: "github-magic-proxy-key-release-please" - } - } -} - -before_action { - fetch_keystore { - keystore_resource { - keystore_config_id: 73713 - keyname: "github-magic-proxy-token-release-please" - } - } -} - -before_action { - fetch_keystore { - keystore_resource { - keystore_config_id: 73713 - keyname: "github-magic-proxy-url-release-please" - } - } -} diff --git a/.kokoro/release/bump_snapshot.sh b/.kokoro/release/bump_snapshot.sh deleted file mode 100755 index 8a17dc15..00000000 --- a/.kokoro/release/bump_snapshot.sh +++ /dev/null @@ -1,30 +0,0 @@ -#!/bin/bash - -# Copyright 2019 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -set -eo pipefail - -export NPM_CONFIG_PREFIX=/home/node/.npm-global - -if [ -f ${KOKORO_KEYSTORE_DIR}/73713_github-magic-proxy-url-release-please ]; then - # Groom the snapshot release PR immediately after publishing a release - npx release-please release-pr --token=${KOKORO_KEYSTORE_DIR}/73713_github-magic-proxy-token-release-please \ - --repo-url=googleapis/java-cloudbuild \ - --package-name="build" \ - --api-url=${KOKORO_KEYSTORE_DIR}/73713_github-magic-proxy-url-release-please \ - --proxy-key=${KOKORO_KEYSTORE_DIR}/73713_github-magic-proxy-key-release-please \ - --snapshot \ - --release-type=java-auth-yoshi -fi diff --git a/.kokoro/release/common.cfg b/.kokoro/release/common.cfg deleted file mode 100644 index 0c72b694..00000000 --- a/.kokoro/release/common.cfg +++ /dev/null @@ -1,49 +0,0 @@ -# Format: //devtools/kokoro/config/proto/build.proto - -# Download trampoline resources. -gfile_resources: "/bigstore/cloud-devrel-kokoro-resources/trampoline" - -# Use the trampoline script to run in docker. -build_file: "java-cloudbuild/.kokoro/trampoline.sh" - -# Configure the docker image for kokoro-trampoline. -env_vars: { - key: "TRAMPOLINE_IMAGE" - value: "gcr.io/cloud-devrel-kokoro-resources/java8" -} - -before_action { - fetch_keystore { - keystore_resource { - keystore_config_id: 70247 - keyname: "maven-gpg-keyring" - } - } -} - -before_action { - fetch_keystore { - keystore_resource { - keystore_config_id: 70247 - keyname: "maven-gpg-passphrase" - } - } -} - -before_action { - fetch_keystore { - keystore_resource { - keystore_config_id: 70247 - keyname: "maven-gpg-pubkeyring" - } - } -} - -before_action { - fetch_keystore { - keystore_resource { - keystore_config_id: 70247 - keyname: "sonatype-credentials" - } - } -} diff --git a/.kokoro/release/common.sh b/.kokoro/release/common.sh deleted file mode 100755 index 7f78ee41..00000000 --- a/.kokoro/release/common.sh +++ /dev/null @@ -1,50 +0,0 @@ -#!/bin/bash -# Copyright 2018 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -set -eo pipefail - -# Get secrets from keystore and set and environment variables -setup_environment_secrets() { - export GPG_PASSPHRASE=$(cat ${KOKORO_KEYSTORE_DIR}/70247_maven-gpg-passphrase) - export GPG_TTY=$(tty) - export GPG_HOMEDIR=/gpg - mkdir $GPG_HOMEDIR - mv ${KOKORO_KEYSTORE_DIR}/70247_maven-gpg-pubkeyring $GPG_HOMEDIR/pubring.gpg - mv ${KOKORO_KEYSTORE_DIR}/70247_maven-gpg-keyring $GPG_HOMEDIR/secring.gpg - export SONATYPE_USERNAME=$(cat ${KOKORO_KEYSTORE_DIR}/70247_sonatype-credentials | cut -f1 -d'|') - export SONATYPE_PASSWORD=$(cat ${KOKORO_KEYSTORE_DIR}/70247_sonatype-credentials | cut -f2 -d'|') -} - -create_settings_xml_file() { - echo " - - - ossrh - ${SONATYPE_USERNAME} - ${SONATYPE_PASSWORD} - - - sonatype-nexus-staging - ${SONATYPE_USERNAME} - ${SONATYPE_PASSWORD} - - - sonatype-nexus-snapshots - ${SONATYPE_USERNAME} - ${SONATYPE_PASSWORD} - - -" > $1 -} \ No newline at end of file diff --git a/.kokoro/release/drop.cfg b/.kokoro/release/drop.cfg deleted file mode 100644 index 6f4eddbf..00000000 --- a/.kokoro/release/drop.cfg +++ /dev/null @@ -1,6 +0,0 @@ -# Format: //devtools/kokoro/config/proto/build.proto - -env_vars: { - key: "TRAMPOLINE_BUILD_FILE" - value: "github/java-cloudbuild/.kokoro/release/drop.sh" -} diff --git a/.kokoro/release/drop.sh b/.kokoro/release/drop.sh deleted file mode 100755 index 742ec1a8..00000000 --- a/.kokoro/release/drop.sh +++ /dev/null @@ -1,32 +0,0 @@ -#!/bin/bash -# Copyright 2018 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -set -eo pipefail - -# STAGING_REPOSITORY_ID must be set -if [ -z "${STAGING_REPOSITORY_ID}" ]; then - echo "Missing STAGING_REPOSITORY_ID environment variable" - exit 1 -fi - -source $(dirname "$0")/common.sh -pushd $(dirname "$0")/../../ - -setup_environment_secrets -create_settings_xml_file "settings.xml" - -mvn nexus-staging:drop -B \ - --settings=settings.xml \ - -DstagingRepositoryId=${STAGING_REPOSITORY_ID} diff --git a/.kokoro/release/promote.cfg b/.kokoro/release/promote.cfg deleted file mode 100644 index 4c11cc92..00000000 --- a/.kokoro/release/promote.cfg +++ /dev/null @@ -1,6 +0,0 @@ -# Format: //devtools/kokoro/config/proto/build.proto - -env_vars: { - key: "TRAMPOLINE_BUILD_FILE" - value: "github/java-cloudbuild/.kokoro/release/promote.sh" -} diff --git a/.kokoro/release/promote.sh b/.kokoro/release/promote.sh deleted file mode 100755 index 3cac3d8a..00000000 --- a/.kokoro/release/promote.sh +++ /dev/null @@ -1,34 +0,0 @@ -#!/bin/bash -# Copyright 2018 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -set -eo pipefail - -# STAGING_REPOSITORY_ID must be set -if [ -z "${STAGING_REPOSITORY_ID}" ]; then - echo "Missing STAGING_REPOSITORY_ID environment variable" - exit 1 -fi - -source $(dirname "$0")/common.sh - -pushd $(dirname "$0")/../../ - -setup_environment_secrets -create_settings_xml_file "settings.xml" - -mvn nexus-staging:release -B \ - -DperformRelease=true \ - --settings=settings.xml \ - -DstagingRepositoryId=${STAGING_REPOSITORY_ID} diff --git a/.kokoro/release/publish_javadoc.cfg b/.kokoro/release/publish_javadoc.cfg deleted file mode 100644 index efd00e2a..00000000 --- a/.kokoro/release/publish_javadoc.cfg +++ /dev/null @@ -1,23 +0,0 @@ -# Format: //devtools/kokoro/config/proto/build.proto - -gfile_resources: "/bigstore/cloud-devrel-kokoro-resources/doc-templates/" - -env_vars: { - key: "STAGING_BUCKET" - value: "docs-staging" -} - -env_vars: { - key: "TRAMPOLINE_BUILD_FILE" - value: "github/java-cloudbuild/.kokoro/release/publish_javadoc.sh" -} - - -before_action { - fetch_keystore { - keystore_resource { - keystore_config_id: 73713 - keyname: "docuploader_service_account" - } - } -} diff --git a/.kokoro/release/publish_javadoc.sh b/.kokoro/release/publish_javadoc.sh deleted file mode 100755 index 6e294d8d..00000000 --- a/.kokoro/release/publish_javadoc.sh +++ /dev/null @@ -1,53 +0,0 @@ -#!/bin/bash -# Copyright 2019 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -set -eo pipefail - -if [[ -z "${CREDENTIALS}" ]]; then - CREDENTIALS=${KOKORO_KEYSTORE_DIR}/73713_docuploader_service_account -fi - -if [[ -z "${STAGING_BUCKET}" ]]; then - echo "Need to set STAGING_BUCKET environment variable" - exit 1 -fi - -# work from the git root directory -pushd $(dirname "$0")/../../ - -# install docuploader package -python3 -m pip install --require-hashes -r .kokoro/requirements.txt - -# compile all packages -mvn clean install -B -q -DskipTests=true - -export NAME=google-cloud-build -export VERSION=$(grep ${NAME}: versions.txt | cut -d: -f3) - -# build the docs -mvn site -B -q - -pushd target/site/apidocs - -# create metadata -python3 -m docuploader create-metadata \ - --name ${NAME} \ - --version ${VERSION} \ - --language java - -# upload docs -python3 -m docuploader upload . \ - --credentials ${CREDENTIALS} \ - --staging-bucket ${STAGING_BUCKET} diff --git a/.kokoro/release/publish_javadoc11.cfg b/.kokoro/release/publish_javadoc11.cfg deleted file mode 100644 index a4403662..00000000 --- a/.kokoro/release/publish_javadoc11.cfg +++ /dev/null @@ -1,30 +0,0 @@ -# Format: //devtools/kokoro/config/proto/build.proto - -# cloud-rad production -env_vars: { - key: "STAGING_BUCKET_V2" - value: "docs-staging-v2" -} - -# Configure the docker image for kokoro-trampoline -env_vars: { - key: "TRAMPOLINE_IMAGE" - value: "gcr.io/cloud-devrel-kokoro-resources/java11" -} - -env_vars: { - key: "TRAMPOLINE_BUILD_FILE" - value: "github/java-cloudbuild/.kokoro/release/publish_javadoc11.sh" -} - -before_action { - fetch_keystore { - keystore_resource { - keystore_config_id: 73713 - keyname: "docuploader_service_account" - } - } -} - -# Downloads docfx doclet resource. This will be in ${KOKORO_GFILE_DIR}/ -gfile_resources: "/bigstore/cloud-devrel-kokoro-resources/docfx" diff --git a/.kokoro/release/publish_javadoc11.sh b/.kokoro/release/publish_javadoc11.sh deleted file mode 100755 index 61b66670..00000000 --- a/.kokoro/release/publish_javadoc11.sh +++ /dev/null @@ -1,63 +0,0 @@ -#!/bin/bash -# Copyright 2021 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -set -eo pipefail - -if [[ -z "${CREDENTIALS}" ]]; then - CREDENTIALS=${KOKORO_KEYSTORE_DIR}/73713_docuploader_service_account -fi - -if [[ -z "${STAGING_BUCKET_V2}" ]]; then - echo "Need to set STAGING_BUCKET_V2 environment variable" - exit 1 -fi - -# work from the git root directory -pushd $(dirname "$0")/../../ - -# install docuploader package -python3 -m pip install --require-hashes -r .kokoro/requirements.txt - -# compile all packages -mvn clean install -B -q -DskipTests=true - -export NAME=google-cloud-build -export VERSION=$(grep ${NAME}: versions.txt | cut -d: -f3) - -# cloud RAD generation -mvn clean javadoc:aggregate -B -q -P docFX -# include CHANGELOG -cp CHANGELOG.md target/docfx-yml/history.md - -pushd target/docfx-yml - -# create metadata -python3 -m docuploader create-metadata \ - --name ${NAME} \ - --version ${VERSION} \ - --xrefs devsite://java/gax \ - --xrefs devsite://java/google-cloud-core \ - --xrefs devsite://java/api-common \ - --xrefs devsite://java/proto-google-common-protos \ - --xrefs devsite://java/google-api-client \ - --xrefs devsite://java/google-http-client \ - --xrefs devsite://java/protobuf \ - --language java - -# upload yml to production bucket -python3 -m docuploader upload . \ - --credentials ${CREDENTIALS} \ - --staging-bucket ${STAGING_BUCKET_V2} \ - --destination-prefix docfx diff --git a/.kokoro/release/snapshot.cfg b/.kokoro/release/snapshot.cfg deleted file mode 100644 index 4c1ee9c0..00000000 --- a/.kokoro/release/snapshot.cfg +++ /dev/null @@ -1,6 +0,0 @@ -# Format: //devtools/kokoro/config/proto/build.proto - -env_vars: { - key: "TRAMPOLINE_BUILD_FILE" - value: "github/java-cloudbuild/.kokoro/release/snapshot.sh" -} \ No newline at end of file diff --git a/.kokoro/release/snapshot.sh b/.kokoro/release/snapshot.sh deleted file mode 100755 index 1f55b770..00000000 --- a/.kokoro/release/snapshot.sh +++ /dev/null @@ -1,33 +0,0 @@ -#!/bin/bash -# Copyright 2019 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -set -eo pipefail - -source $(dirname "$0")/common.sh -MAVEN_SETTINGS_FILE=$(realpath $(dirname "$0")/../../)/settings.xml -pushd $(dirname "$0")/../../ - -# ensure we're trying to push a snapshot (no-result returns non-zero exit code) -grep SNAPSHOT versions.txt - -setup_environment_secrets -create_settings_xml_file "settings.xml" - -mvn clean deploy -B \ - --settings ${MAVEN_SETTINGS_FILE} \ - -DperformRelease=true \ - -Dgpg.executable=gpg \ - -Dgpg.passphrase=${GPG_PASSPHRASE} \ - -Dgpg.homedir=${GPG_HOMEDIR} diff --git a/.kokoro/release/stage.cfg b/.kokoro/release/stage.cfg deleted file mode 100644 index 16defdf4..00000000 --- a/.kokoro/release/stage.cfg +++ /dev/null @@ -1,19 +0,0 @@ -# Format: //devtools/kokoro/config/proto/build.proto - -env_vars: { - key: "TRAMPOLINE_BUILD_FILE" - value: "github/java-cloudbuild/.kokoro/release/stage.sh" -} - -# Need to save the properties file -action { - define_artifacts { - regex: "github/java-cloudbuild/target/nexus-staging/staging/*.properties" - strip_prefix: "github/java-cloudbuild" - } -} - -env_vars: { - key: "SECRET_MANAGER_KEYS" - value: "releasetool-publish-reporter-app,releasetool-publish-reporter-googleapis-installation,releasetool-publish-reporter-pem" -} diff --git a/.kokoro/release/stage.sh b/.kokoro/release/stage.sh deleted file mode 100755 index 61e714d6..00000000 --- a/.kokoro/release/stage.sh +++ /dev/null @@ -1,47 +0,0 @@ -#!/bin/bash -# Copyright 2018 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. - -set -eo pipefail - -# Start the releasetool reporter -requirementsFile=$(realpath $(dirname "${BASH_SOURCE[0]}")/../requirements.txt) -python3 -m pip install --require-hashes -r $requirementsFile -python3 -m releasetool publish-reporter-script > /tmp/publisher-script; source /tmp/publisher-script - -source $(dirname "$0")/common.sh -source $(dirname "$0")/../common.sh -MAVEN_SETTINGS_FILE=$(realpath $(dirname "$0")/../../)/settings.xml -pushd $(dirname "$0")/../../ - -setup_environment_secrets -create_settings_xml_file "settings.xml" - -# attempt to stage 3 times with exponential backoff (starting with 10 seconds) -retry_with_backoff 3 10 \ - mvn clean deploy -B \ - --settings ${MAVEN_SETTINGS_FILE} \ - -DskipTests=true \ - -Dclirr.skip=true \ - -DperformRelease=true \ - -Dgpg.executable=gpg \ - -Dgpg.passphrase=${GPG_PASSPHRASE} \ - -Dgpg.homedir=${GPG_HOMEDIR} - -if [[ -n "${AUTORELEASE_PR}" ]] -then - mvn nexus-staging:release -B \ - -DperformRelease=true \ - --settings=settings.xml -fi diff --git a/.kokoro/requirements.in b/.kokoro/requirements.in deleted file mode 100644 index 6aa7cf2b..00000000 --- a/.kokoro/requirements.in +++ /dev/null @@ -1,33 +0,0 @@ -gcp-docuploader==0.6.3 -google-crc32c==1.3.0 -googleapis-common-protos==1.56.3 -gcp-releasetool==1.8.7 -cachetools==4.2.4 -cffi==1.15.1 -jeepney==0.7.1 -jinja2==3.0.3 -markupsafe==2.0.1 -keyring==23.4.1 -packaging==21.3 -protobuf==3.19.5 -pyjwt==2.4.0 -pyparsing==3.0.9 -pycparser==2.21 -pyperclip==1.8.2 -python-dateutil==2.8.2 -requests==2.27.1 -certifi==2022.9.24 -importlib-metadata==4.8.3 -zipp==3.6.0 -google_api_core==2.8.2 -google-cloud-storage==2.0.0 -google-resumable-media==2.3.3 -google-cloud-core==2.3.1 -typing-extensions==4.1.1 -urllib3==1.26.12 -zipp==3.6.0 -rsa==4.9 -six==1.16.0 -attrs==22.1.0 -google-auth==2.11.0 -idna==3.4 \ No newline at end of file diff --git a/.kokoro/requirements.txt b/.kokoro/requirements.txt deleted file mode 100644 index 02ae42bb..00000000 --- a/.kokoro/requirements.txt +++ /dev/null @@ -1,456 +0,0 @@ -# -# This file is autogenerated by pip-compile with python 3.10 -# To update, run: -# -# pip-compile --allow-unsafe --generate-hashes requirements.in -# -attrs==22.1.0 \ - --hash=sha256:29adc2665447e5191d0e7c568fde78b21f9672d344281d0c6e1ab085429b22b6 \ - --hash=sha256:86efa402f67bf2df34f51a335487cf46b1ec130d02b8d39fd248abfd30da551c - # via - # -r requirements.in - # gcp-releasetool -cachetools==4.2.4 \ - --hash=sha256:89ea6f1b638d5a73a4f9226be57ac5e4f399d22770b92355f92dcb0f7f001693 \ - --hash=sha256:92971d3cb7d2a97efff7c7bb1657f21a8f5fb309a37530537c71b1774189f2d1 - # via - # -r requirements.in - # google-auth -certifi==2022.9.24 \ - --hash=sha256:0d9c601124e5a6ba9712dbc60d9c53c21e34f5f641fe83002317394311bdce14 \ - --hash=sha256:90c1a32f1d68f940488354e36370f6cca89f0f106db09518524c88d6ed83f382 - # via - # -r requirements.in - # requests -cffi==1.15.1 \ - --hash=sha256:00a9ed42e88df81ffae7a8ab6d9356b371399b91dbdf0c3cb1e84c03a13aceb5 \ - --hash=sha256:03425bdae262c76aad70202debd780501fabeaca237cdfddc008987c0e0f59ef \ - --hash=sha256:04ed324bda3cda42b9b695d51bb7d54b680b9719cfab04227cdd1e04e5de3104 \ - --hash=sha256:0e2642fe3142e4cc4af0799748233ad6da94c62a8bec3a6648bf8ee68b1c7426 \ - --hash=sha256:173379135477dc8cac4bc58f45db08ab45d228b3363adb7af79436135d028405 \ - --hash=sha256:198caafb44239b60e252492445da556afafc7d1e3ab7a1fb3f0584ef6d742375 \ - --hash=sha256:1e74c6b51a9ed6589199c787bf5f9875612ca4a8a0785fb2d4a84429badaf22a \ - --hash=sha256:2012c72d854c2d03e45d06ae57f40d78e5770d252f195b93f581acf3ba44496e \ - --hash=sha256:21157295583fe8943475029ed5abdcf71eb3911894724e360acff1d61c1d54bc \ - --hash=sha256:2470043b93ff09bf8fb1d46d1cb756ce6132c54826661a32d4e4d132e1977adf \ - --hash=sha256:285d29981935eb726a4399badae8f0ffdff4f5050eaa6d0cfc3f64b857b77185 \ - --hash=sha256:30d78fbc8ebf9c92c9b7823ee18eb92f2e6ef79b45ac84db507f52fbe3ec4497 \ - --hash=sha256:320dab6e7cb2eacdf0e658569d2575c4dad258c0fcc794f46215e1e39f90f2c3 \ - --hash=sha256:33ab79603146aace82c2427da5ca6e58f2b3f2fb5da893ceac0c42218a40be35 \ - --hash=sha256:3548db281cd7d2561c9ad9984681c95f7b0e38881201e157833a2342c30d5e8c \ - --hash=sha256:3799aecf2e17cf585d977b780ce79ff0dc9b78d799fc694221ce814c2c19db83 \ - --hash=sha256:39d39875251ca8f612b6f33e6b1195af86d1b3e60086068be9cc053aa4376e21 \ - --hash=sha256:3b926aa83d1edb5aa5b427b4053dc420ec295a08e40911296b9eb1b6170f6cca \ - --hash=sha256:3bcde07039e586f91b45c88f8583ea7cf7a0770df3a1649627bf598332cb6984 \ - --hash=sha256:3d08afd128ddaa624a48cf2b859afef385b720bb4b43df214f85616922e6a5ac \ - --hash=sha256:3eb6971dcff08619f8d91607cfc726518b6fa2a9eba42856be181c6d0d9515fd \ - --hash=sha256:40f4774f5a9d4f5e344f31a32b5096977b5d48560c5592e2f3d2c4374bd543ee \ - --hash=sha256:4289fc34b2f5316fbb762d75362931e351941fa95fa18789191b33fc4cf9504a \ - --hash=sha256:470c103ae716238bbe698d67ad020e1db9d9dba34fa5a899b5e21577e6d52ed2 \ - --hash=sha256:4f2c9f67e9821cad2e5f480bc8d83b8742896f1242dba247911072d4fa94c192 \ - --hash=sha256:50a74364d85fd319352182ef59c5c790484a336f6db772c1a9231f1c3ed0cbd7 \ - --hash=sha256:54a2db7b78338edd780e7ef7f9f6c442500fb0d41a5a4ea24fff1c929d5af585 \ - --hash=sha256:5635bd9cb9731e6d4a1132a498dd34f764034a8ce60cef4f5319c0541159392f \ - --hash=sha256:59c0b02d0a6c384d453fece7566d1c7e6b7bae4fc5874ef2ef46d56776d61c9e \ - --hash=sha256:5d598b938678ebf3c67377cdd45e09d431369c3b1a5b331058c338e201f12b27 \ - --hash=sha256:5df2768244d19ab7f60546d0c7c63ce1581f7af8b5de3eb3004b9b6fc8a9f84b \ - --hash=sha256:5ef34d190326c3b1f822a5b7a45f6c4535e2f47ed06fec77d3d799c450b2651e \ - --hash=sha256:6975a3fac6bc83c4a65c9f9fcab9e47019a11d3d2cf7f3c0d03431bf145a941e \ - --hash=sha256:6c9a799e985904922a4d207a94eae35c78ebae90e128f0c4e521ce339396be9d \ - --hash=sha256:70df4e3b545a17496c9b3f41f5115e69a4f2e77e94e1d2a8e1070bc0c38c8a3c \ - --hash=sha256:7473e861101c9e72452f9bf8acb984947aa1661a7704553a9f6e4baa5ba64415 \ - --hash=sha256:8102eaf27e1e448db915d08afa8b41d6c7ca7a04b7d73af6514df10a3e74bd82 \ - --hash=sha256:87c450779d0914f2861b8526e035c5e6da0a3199d8f1add1a665e1cbc6fc6d02 \ - --hash=sha256:8b7ee99e510d7b66cdb6c593f21c043c248537a32e0bedf02e01e9553a172314 \ - --hash=sha256:91fc98adde3d7881af9b59ed0294046f3806221863722ba7d8d120c575314325 \ - --hash=sha256:94411f22c3985acaec6f83c6df553f2dbe17b698cc7f8ae751ff2237d96b9e3c \ - --hash=sha256:98d85c6a2bef81588d9227dde12db8a7f47f639f4a17c9ae08e773aa9c697bf3 \ - --hash=sha256:9ad5db27f9cabae298d151c85cf2bad1d359a1b9c686a275df03385758e2f914 \ - --hash=sha256:a0b71b1b8fbf2b96e41c4d990244165e2c9be83d54962a9a1d118fd8657d2045 \ - --hash=sha256:a0f100c8912c114ff53e1202d0078b425bee3649ae34d7b070e9697f93c5d52d \ - --hash=sha256:a591fe9e525846e4d154205572a029f653ada1a78b93697f3b5a8f1f2bc055b9 \ - --hash=sha256:a5c84c68147988265e60416b57fc83425a78058853509c1b0629c180094904a5 \ - --hash=sha256:a66d3508133af6e8548451b25058d5812812ec3798c886bf38ed24a98216fab2 \ - --hash=sha256:a8c4917bd7ad33e8eb21e9a5bbba979b49d9a97acb3a803092cbc1133e20343c \ - --hash=sha256:b3bbeb01c2b273cca1e1e0c5df57f12dce9a4dd331b4fa1635b8bec26350bde3 \ - --hash=sha256:cba9d6b9a7d64d4bd46167096fc9d2f835e25d7e4c121fb2ddfc6528fb0413b2 \ - --hash=sha256:cc4d65aeeaa04136a12677d3dd0b1c0c94dc43abac5860ab33cceb42b801c1e8 \ - --hash=sha256:ce4bcc037df4fc5e3d184794f27bdaab018943698f4ca31630bc7f84a7b69c6d \ - --hash=sha256:cec7d9412a9102bdc577382c3929b337320c4c4c4849f2c5cdd14d7368c5562d \ - --hash=sha256:d400bfb9a37b1351253cb402671cea7e89bdecc294e8016a707f6d1d8ac934f9 \ - --hash=sha256:d61f4695e6c866a23a21acab0509af1cdfd2c013cf256bbf5b6b5e2695827162 \ - --hash=sha256:db0fbb9c62743ce59a9ff687eb5f4afbe77e5e8403d6697f7446e5f609976f76 \ - --hash=sha256:dd86c085fae2efd48ac91dd7ccffcfc0571387fe1193d33b6394db7ef31fe2a4 \ - --hash=sha256:e00b098126fd45523dd056d2efba6c5a63b71ffe9f2bbe1a4fe1716e1d0c331e \ - --hash=sha256:e229a521186c75c8ad9490854fd8bbdd9a0c9aa3a524326b55be83b54d4e0ad9 \ - --hash=sha256:e263d77ee3dd201c3a142934a086a4450861778baaeeb45db4591ef65550b0a6 \ - --hash=sha256:ed9cb427ba5504c1dc15ede7d516b84757c3e3d7868ccc85121d9310d27eed0b \ - --hash=sha256:fa6693661a4c91757f4412306191b6dc88c1703f780c8234035eac011922bc01 \ - --hash=sha256:fcd131dd944808b5bdb38e6f5b53013c5aa4f334c5cad0c72742f6eba4b73db0 - # via - # -r requirements.in - # cryptography -charset-normalizer==2.0.12 \ - --hash=sha256:2857e29ff0d34db842cd7ca3230549d1a697f96ee6d3fb071cfa6c7393832597 \ - --hash=sha256:6881edbebdb17b39b4eaaa821b438bf6eddffb4468cf344f09f89def34a8b1df - # via requests -click==8.0.4 \ - --hash=sha256:6a7a62563bbfabfda3a38f3023a1db4a35978c0abd76f6c9605ecd6554d6d9b1 \ - --hash=sha256:8458d7b1287c5fb128c90e23381cf99dcde74beaf6c7ff6384ce84d6fe090adb - # via - # gcp-docuploader - # gcp-releasetool -colorlog==6.7.0 \ - --hash=sha256:0d33ca236784a1ba3ff9c532d4964126d8a2c44f1f0cb1d2b0728196f512f662 \ - --hash=sha256:bd94bd21c1e13fac7bd3153f4bc3a7dc0eb0974b8bc2fdf1a989e474f6e582e5 - # via gcp-docuploader -cryptography==38.0.1 \ - --hash=sha256:0297ffc478bdd237f5ca3a7dc96fc0d315670bfa099c04dc3a4a2172008a405a \ - --hash=sha256:10d1f29d6292fc95acb597bacefd5b9e812099d75a6469004fd38ba5471a977f \ - --hash=sha256:16fa61e7481f4b77ef53991075de29fc5bacb582a1244046d2e8b4bb72ef66d0 \ - --hash=sha256:194044c6b89a2f9f169df475cc167f6157eb9151cc69af8a2a163481d45cc407 \ - --hash=sha256:1db3d807a14931fa317f96435695d9ec386be7b84b618cc61cfa5d08b0ae33d7 \ - --hash=sha256:3261725c0ef84e7592597606f6583385fed2a5ec3909f43bc475ade9729a41d6 \ - --hash=sha256:3b72c360427889b40f36dc214630e688c2fe03e16c162ef0aa41da7ab1455153 \ - --hash=sha256:3e3a2599e640927089f932295a9a247fc40a5bdf69b0484532f530471a382750 \ - --hash=sha256:3fc26e22840b77326a764ceb5f02ca2d342305fba08f002a8c1f139540cdfaad \ - --hash=sha256:5067ee7f2bce36b11d0e334abcd1ccf8c541fc0bbdaf57cdd511fdee53e879b6 \ - --hash=sha256:52e7bee800ec869b4031093875279f1ff2ed12c1e2f74923e8f49c916afd1d3b \ - --hash=sha256:64760ba5331e3f1794d0bcaabc0d0c39e8c60bf67d09c93dc0e54189dfd7cfe5 \ - --hash=sha256:765fa194a0f3372d83005ab83ab35d7c5526c4e22951e46059b8ac678b44fa5a \ - --hash=sha256:79473cf8a5cbc471979bd9378c9f425384980fcf2ab6534b18ed7d0d9843987d \ - --hash=sha256:896dd3a66959d3a5ddcfc140a53391f69ff1e8f25d93f0e2e7830c6de90ceb9d \ - --hash=sha256:89ed49784ba88c221756ff4d4755dbc03b3c8d2c5103f6d6b4f83a0fb1e85294 \ - --hash=sha256:ac7e48f7e7261207d750fa7e55eac2d45f720027d5703cd9007e9b37bbb59ac0 \ - --hash=sha256:ad7353f6ddf285aeadfaf79e5a6829110106ff8189391704c1d8801aa0bae45a \ - --hash=sha256:b0163a849b6f315bf52815e238bc2b2346604413fa7c1601eea84bcddb5fb9ac \ - --hash=sha256:b6c9b706316d7b5a137c35e14f4103e2115b088c412140fdbd5f87c73284df61 \ - --hash=sha256:c2e5856248a416767322c8668ef1845ad46ee62629266f84a8f007a317141013 \ - --hash=sha256:ca9f6784ea96b55ff41708b92c3f6aeaebde4c560308e5fbbd3173fbc466e94e \ - --hash=sha256:d1a5bd52d684e49a36582193e0b89ff267704cd4025abefb9e26803adeb3e5fb \ - --hash=sha256:d3971e2749a723e9084dd507584e2a2761f78ad2c638aa31e80bc7a15c9db4f9 \ - --hash=sha256:d4ef6cc305394ed669d4d9eebf10d3a101059bdcf2669c366ec1d14e4fb227bd \ - --hash=sha256:d9e69ae01f99abe6ad646947bba8941e896cb3aa805be2597a0400e0764b5818 - # via - # gcp-releasetool - # secretstorage -gcp-docuploader==0.6.3 \ - --hash=sha256:ba8c9d76b3bbac54b0311c503a373b00edc2dc02d6d54ea9507045adb8e870f7 \ - --hash=sha256:c0f5aaa82ce1854a386197e4e359b120ad6d4e57ae2c812fce42219a3288026b - # via -r requirements.in -gcp-releasetool==1.8.7 \ - --hash=sha256:3d2a67c9db39322194afb3b427e9cb0476ce8f2a04033695f0aeb63979fc2b37 \ - --hash=sha256:5e4d28f66e90780d77f3ecf1e9155852b0c3b13cbccb08ab07e66b2357c8da8d - # via -r requirements.in -google-api-core==2.8.2 \ - --hash=sha256:06f7244c640322b508b125903bb5701bebabce8832f85aba9335ec00b3d02edc \ - --hash=sha256:93c6a91ccac79079ac6bbf8b74ee75db970cc899278b97d53bc012f35908cf50 - # via - # -r requirements.in - # google-cloud-core - # google-cloud-storage -google-auth==2.11.0 \ - --hash=sha256:be62acaae38d0049c21ca90f27a23847245c9f161ff54ede13af2cb6afecbac9 \ - --hash=sha256:ed65ecf9f681832298e29328e1ef0a3676e3732b2e56f41532d45f70a22de0fb - # via - # -r requirements.in - # gcp-releasetool - # google-api-core - # google-cloud-core - # google-cloud-storage -google-cloud-core==2.3.1 \ - --hash=sha256:113ba4f492467d5bd442c8d724c1a25ad7384045c3178369038840ecdd19346c \ - --hash=sha256:34334359cb04187bdc80ddcf613e462dfd7a3aabbc3fe4d118517ab4b9303d53 - # via - # -r requirements.in - # google-cloud-storage -google-cloud-storage==2.0.0 \ - --hash=sha256:a57a15aead0f9dfbd4381f1bfdbe8bf89818a4bd75bab846cafcefb2db846c47 \ - --hash=sha256:ec4be60bb223a3a960f0d01697d849b86d91cad815a84915a32ed3635e93a5e7 - # via - # -r requirements.in - # gcp-docuploader -google-crc32c==1.3.0 \ - --hash=sha256:04e7c220798a72fd0f08242bc8d7a05986b2a08a0573396187fd32c1dcdd58b3 \ - --hash=sha256:05340b60bf05b574159e9bd940152a47d38af3fb43803ffe71f11d704b7696a6 \ - --hash=sha256:12674a4c3b56b706153a358eaa1018c4137a5a04635b92b4652440d3d7386206 \ - --hash=sha256:127f9cc3ac41b6a859bd9dc4321097b1a4f6aa7fdf71b4f9227b9e3ebffb4422 \ - --hash=sha256:13af315c3a0eec8bb8b8d80b8b128cb3fcd17d7e4edafc39647846345a3f003a \ - --hash=sha256:1926fd8de0acb9d15ee757175ce7242e235482a783cd4ec711cc999fc103c24e \ - --hash=sha256:226f2f9b8e128a6ca6a9af9b9e8384f7b53a801907425c9a292553a3a7218ce0 \ - --hash=sha256:276de6273eb074a35bc598f8efbc00c7869c5cf2e29c90748fccc8c898c244df \ - --hash=sha256:318f73f5484b5671f0c7f5f63741ab020a599504ed81d209b5c7129ee4667407 \ - --hash=sha256:3bbce1be3687bbfebe29abdb7631b83e6b25da3f4e1856a1611eb21854b689ea \ - --hash=sha256:42ae4781333e331a1743445931b08ebdad73e188fd554259e772556fc4937c48 \ - --hash=sha256:58be56ae0529c664cc04a9c76e68bb92b091e0194d6e3c50bea7e0f266f73713 \ - --hash=sha256:5da2c81575cc3ccf05d9830f9e8d3c70954819ca9a63828210498c0774fda1a3 \ - --hash=sha256:6311853aa2bba4064d0c28ca54e7b50c4d48e3de04f6770f6c60ebda1e975267 \ - --hash=sha256:650e2917660e696041ab3dcd7abac160b4121cd9a484c08406f24c5964099829 \ - --hash=sha256:6a4db36f9721fdf391646685ecffa404eb986cbe007a3289499020daf72e88a2 \ - --hash=sha256:779cbf1ce375b96111db98fca913c1f5ec11b1d870e529b1dc7354b2681a8c3a \ - --hash=sha256:7f6fe42536d9dcd3e2ffb9d3053f5d05221ae3bbcefbe472bdf2c71c793e3183 \ - --hash=sha256:891f712ce54e0d631370e1f4997b3f182f3368179198efc30d477c75d1f44942 \ - --hash=sha256:95c68a4b9b7828ba0428f8f7e3109c5d476ca44996ed9a5f8aac6269296e2d59 \ - --hash=sha256:96a8918a78d5d64e07c8ea4ed2bc44354e3f93f46a4866a40e8db934e4c0d74b \ - --hash=sha256:9c3cf890c3c0ecfe1510a452a165431b5831e24160c5fcf2071f0f85ca5a47cd \ - --hash=sha256:9f58099ad7affc0754ae42e6d87443299f15d739b0ce03c76f515153a5cda06c \ - --hash=sha256:a0b9e622c3b2b8d0ce32f77eba617ab0d6768b82836391e4f8f9e2074582bf02 \ - --hash=sha256:a7f9cbea4245ee36190f85fe1814e2d7b1e5f2186381b082f5d59f99b7f11328 \ - --hash=sha256:bab4aebd525218bab4ee615786c4581952eadc16b1ff031813a2fd51f0cc7b08 \ - --hash=sha256:c124b8c8779bf2d35d9b721e52d4adb41c9bfbde45e6a3f25f0820caa9aba73f \ - --hash=sha256:c9da0a39b53d2fab3e5467329ed50e951eb91386e9d0d5b12daf593973c3b168 \ - --hash=sha256:ca60076c388728d3b6ac3846842474f4250c91efbfe5afa872d3ffd69dd4b318 \ - --hash=sha256:cb6994fff247987c66a8a4e550ef374671c2b82e3c0d2115e689d21e511a652d \ - --hash=sha256:d1c1d6236feab51200272d79b3d3e0f12cf2cbb12b208c835b175a21efdb0a73 \ - --hash=sha256:dd7760a88a8d3d705ff562aa93f8445ead54f58fd482e4f9e2bafb7e177375d4 \ - --hash=sha256:dda4d8a3bb0b50f540f6ff4b6033f3a74e8bf0bd5320b70fab2c03e512a62812 \ - --hash=sha256:e0f1ff55dde0ebcfbef027edc21f71c205845585fffe30d4ec4979416613e9b3 \ - --hash=sha256:e7a539b9be7b9c00f11ef16b55486141bc2cdb0c54762f84e3c6fc091917436d \ - --hash=sha256:eb0b14523758e37802f27b7f8cd973f5f3d33be7613952c0df904b68c4842f0e \ - --hash=sha256:ed447680ff21c14aaceb6a9f99a5f639f583ccfe4ce1a5e1d48eb41c3d6b3217 \ - --hash=sha256:f52a4ad2568314ee713715b1e2d79ab55fab11e8b304fd1462ff5cccf4264b3e \ - --hash=sha256:fbd60c6aaa07c31d7754edbc2334aef50601b7f1ada67a96eb1eb57c7c72378f \ - --hash=sha256:fc28e0db232c62ca0c3600884933178f0825c99be4474cdd645e378a10588125 \ - --hash=sha256:fe31de3002e7b08eb20823b3735b97c86c5926dd0581c7710a680b418a8709d4 \ - --hash=sha256:fec221a051150eeddfdfcff162e6db92c65ecf46cb0f7bb1bf812a1520ec026b \ - --hash=sha256:ff71073ebf0e42258a42a0b34f2c09ec384977e7f6808999102eedd5b49920e3 - # via - # -r requirements.in - # google-resumable-media -google-resumable-media==2.3.3 \ - --hash=sha256:27c52620bd364d1c8116eaac4ea2afcbfb81ae9139fb3199652fcac1724bfb6c \ - --hash=sha256:5b52774ea7a829a8cdaa8bd2d4c3d4bc660c91b30857ab2668d0eb830f4ea8c5 - # via - # -r requirements.in - # google-cloud-storage -googleapis-common-protos==1.56.3 \ - --hash=sha256:6f1369b58ed6cf3a4b7054a44ebe8d03b29c309257583a2bbdc064cd1e4a1442 \ - --hash=sha256:87955d7b3a73e6e803f2572a33179de23989ebba725e05ea42f24838b792e461 - # via - # -r requirements.in - # google-api-core -idna==3.4 \ - --hash=sha256:814f528e8dead7d329833b91c5faa87d60bf71824cd12a7530b5526063d02cb4 \ - --hash=sha256:90b77e79eaa3eba6de819a0c442c0b4ceefc341a7a2ab77d7562bf49f425c5c2 - # via - # -r requirements.in - # requests -importlib-metadata==4.8.3 \ - --hash=sha256:65a9576a5b2d58ca44d133c42a241905cc45e34d2c06fd5ba2bafa221e5d7b5e \ - --hash=sha256:766abffff765960fcc18003801f7044eb6755ffae4521c8e8ce8e83b9c9b0668 - # via - # -r requirements.in - # keyring -jeepney==0.7.1 \ - --hash=sha256:1b5a0ea5c0e7b166b2f5895b91a08c14de8915afda4407fb5022a195224958ac \ - --hash=sha256:fa9e232dfa0c498bd0b8a3a73b8d8a31978304dcef0515adc859d4e096f96f4f - # via - # -r requirements.in - # keyring - # secretstorage -jinja2==3.0.3 \ - --hash=sha256:077ce6014f7b40d03b47d1f1ca4b0fc8328a692bd284016f806ed0eaca390ad8 \ - --hash=sha256:611bb273cd68f3b993fabdc4064fc858c5b47a973cb5aa7999ec1ba405c87cd7 - # via - # -r requirements.in - # gcp-releasetool -keyring==23.4.1 \ - --hash=sha256:17e49fb0d6883c2b4445359434dba95aad84aabb29bbff044ad0ed7100232eca \ - --hash=sha256:89cbd74d4683ed164c8082fb38619341097741323b3786905c6dac04d6915a55 - # via - # -r requirements.in - # gcp-releasetool -markupsafe==2.0.1 \ - --hash=sha256:01a9b8ea66f1658938f65b93a85ebe8bc016e6769611be228d797c9d998dd298 \ - --hash=sha256:023cb26ec21ece8dc3907c0e8320058b2e0cb3c55cf9564da612bc325bed5e64 \ - --hash=sha256:0446679737af14f45767963a1a9ef7620189912317d095f2d9ffa183a4d25d2b \ - --hash=sha256:04635854b943835a6ea959e948d19dcd311762c5c0c6e1f0e16ee57022669194 \ - --hash=sha256:0717a7390a68be14b8c793ba258e075c6f4ca819f15edfc2a3a027c823718567 \ - --hash=sha256:0955295dd5eec6cb6cc2fe1698f4c6d84af2e92de33fbcac4111913cd100a6ff \ - --hash=sha256:0d4b31cc67ab36e3392bbf3862cfbadac3db12bdd8b02a2731f509ed5b829724 \ - --hash=sha256:10f82115e21dc0dfec9ab5c0223652f7197feb168c940f3ef61563fc2d6beb74 \ - --hash=sha256:168cd0a3642de83558a5153c8bd34f175a9a6e7f6dc6384b9655d2697312a646 \ - --hash=sha256:1d609f577dc6e1aa17d746f8bd3c31aa4d258f4070d61b2aa5c4166c1539de35 \ - --hash=sha256:1f2ade76b9903f39aa442b4aadd2177decb66525062db244b35d71d0ee8599b6 \ - --hash=sha256:20dca64a3ef2d6e4d5d615a3fd418ad3bde77a47ec8a23d984a12b5b4c74491a \ - --hash=sha256:2a7d351cbd8cfeb19ca00de495e224dea7e7d919659c2841bbb7f420ad03e2d6 \ - --hash=sha256:2d7d807855b419fc2ed3e631034685db6079889a1f01d5d9dac950f764da3dad \ - --hash=sha256:2ef54abee730b502252bcdf31b10dacb0a416229b72c18b19e24a4509f273d26 \ - --hash=sha256:36bc903cbb393720fad60fc28c10de6acf10dc6cc883f3e24ee4012371399a38 \ - --hash=sha256:37205cac2a79194e3750b0af2a5720d95f786a55ce7df90c3af697bfa100eaac \ - --hash=sha256:3c112550557578c26af18a1ccc9e090bfe03832ae994343cfdacd287db6a6ae7 \ - --hash=sha256:3dd007d54ee88b46be476e293f48c85048603f5f516008bee124ddd891398ed6 \ - --hash=sha256:4296f2b1ce8c86a6aea78613c34bb1a672ea0e3de9c6ba08a960efe0b0a09047 \ - --hash=sha256:47ab1e7b91c098ab893b828deafa1203de86d0bc6ab587b160f78fe6c4011f75 \ - --hash=sha256:49e3ceeabbfb9d66c3aef5af3a60cc43b85c33df25ce03d0031a608b0a8b2e3f \ - --hash=sha256:4dc8f9fb58f7364b63fd9f85013b780ef83c11857ae79f2feda41e270468dd9b \ - --hash=sha256:4efca8f86c54b22348a5467704e3fec767b2db12fc39c6d963168ab1d3fc9135 \ - --hash=sha256:53edb4da6925ad13c07b6d26c2a852bd81e364f95301c66e930ab2aef5b5ddd8 \ - --hash=sha256:5855f8438a7d1d458206a2466bf82b0f104a3724bf96a1c781ab731e4201731a \ - --hash=sha256:594c67807fb16238b30c44bdf74f36c02cdf22d1c8cda91ef8a0ed8dabf5620a \ - --hash=sha256:5b6d930f030f8ed98e3e6c98ffa0652bdb82601e7a016ec2ab5d7ff23baa78d1 \ - --hash=sha256:5bb28c636d87e840583ee3adeb78172efc47c8b26127267f54a9c0ec251d41a9 \ - --hash=sha256:60bf42e36abfaf9aff1f50f52644b336d4f0a3fd6d8a60ca0d054ac9f713a864 \ - --hash=sha256:611d1ad9a4288cf3e3c16014564df047fe08410e628f89805e475368bd304914 \ - --hash=sha256:6300b8454aa6930a24b9618fbb54b5a68135092bc666f7b06901f897fa5c2fee \ - --hash=sha256:63f3268ba69ace99cab4e3e3b5840b03340efed0948ab8f78d2fd87ee5442a4f \ - --hash=sha256:6557b31b5e2c9ddf0de32a691f2312a32f77cd7681d8af66c2692efdbef84c18 \ - --hash=sha256:693ce3f9e70a6cf7d2fb9e6c9d8b204b6b39897a2c4a1aa65728d5ac97dcc1d8 \ - --hash=sha256:6a7fae0dd14cf60ad5ff42baa2e95727c3d81ded453457771d02b7d2b3f9c0c2 \ - --hash=sha256:6c4ca60fa24e85fe25b912b01e62cb969d69a23a5d5867682dd3e80b5b02581d \ - --hash=sha256:6fcf051089389abe060c9cd7caa212c707e58153afa2c649f00346ce6d260f1b \ - --hash=sha256:7d91275b0245b1da4d4cfa07e0faedd5b0812efc15b702576d103293e252af1b \ - --hash=sha256:89c687013cb1cd489a0f0ac24febe8c7a666e6e221b783e53ac50ebf68e45d86 \ - --hash=sha256:8d206346619592c6200148b01a2142798c989edcb9c896f9ac9722a99d4e77e6 \ - --hash=sha256:905fec760bd2fa1388bb5b489ee8ee5f7291d692638ea5f67982d968366bef9f \ - --hash=sha256:97383d78eb34da7e1fa37dd273c20ad4320929af65d156e35a5e2d89566d9dfb \ - --hash=sha256:984d76483eb32f1bcb536dc27e4ad56bba4baa70be32fa87152832cdd9db0833 \ - --hash=sha256:99df47edb6bda1249d3e80fdabb1dab8c08ef3975f69aed437cb69d0a5de1e28 \ - --hash=sha256:9f02365d4e99430a12647f09b6cc8bab61a6564363f313126f775eb4f6ef798e \ - --hash=sha256:a30e67a65b53ea0a5e62fe23682cfe22712e01f453b95233b25502f7c61cb415 \ - --hash=sha256:ab3ef638ace319fa26553db0624c4699e31a28bb2a835c5faca8f8acf6a5a902 \ - --hash=sha256:aca6377c0cb8a8253e493c6b451565ac77e98c2951c45f913e0b52facdcff83f \ - --hash=sha256:add36cb2dbb8b736611303cd3bfcee00afd96471b09cda130da3581cbdc56a6d \ - --hash=sha256:b2f4bf27480f5e5e8ce285a8c8fd176c0b03e93dcc6646477d4630e83440c6a9 \ - --hash=sha256:b7f2d075102dc8c794cbde1947378051c4e5180d52d276987b8d28a3bd58c17d \ - --hash=sha256:baa1a4e8f868845af802979fcdbf0bb11f94f1cb7ced4c4b8a351bb60d108145 \ - --hash=sha256:be98f628055368795d818ebf93da628541e10b75b41c559fdf36d104c5787066 \ - --hash=sha256:bf5d821ffabf0ef3533c39c518f3357b171a1651c1ff6827325e4489b0e46c3c \ - --hash=sha256:c47adbc92fc1bb2b3274c4b3a43ae0e4573d9fbff4f54cd484555edbf030baf1 \ - --hash=sha256:cdfba22ea2f0029c9261a4bd07e830a8da012291fbe44dc794e488b6c9bb353a \ - --hash=sha256:d6c7ebd4e944c85e2c3421e612a7057a2f48d478d79e61800d81468a8d842207 \ - --hash=sha256:d7f9850398e85aba693bb640262d3611788b1f29a79f0c93c565694658f4071f \ - --hash=sha256:d8446c54dc28c01e5a2dbac5a25f071f6653e6e40f3a8818e8b45d790fe6ef53 \ - --hash=sha256:deb993cacb280823246a026e3b2d81c493c53de6acfd5e6bfe31ab3402bb37dd \ - --hash=sha256:e0f138900af21926a02425cf736db95be9f4af72ba1bb21453432a07f6082134 \ - --hash=sha256:e9936f0b261d4df76ad22f8fee3ae83b60d7c3e871292cd42f40b81b70afae85 \ - --hash=sha256:f0567c4dc99f264f49fe27da5f735f414c4e7e7dd850cfd8e69f0862d7c74ea9 \ - --hash=sha256:f5653a225f31e113b152e56f154ccbe59eeb1c7487b39b9d9f9cdb58e6c79dc5 \ - --hash=sha256:f826e31d18b516f653fe296d967d700fddad5901ae07c622bb3705955e1faa94 \ - --hash=sha256:f8ba0e8349a38d3001fae7eadded3f6606f0da5d748ee53cc1dab1d6527b9509 \ - --hash=sha256:f9081981fe268bd86831e5c75f7de206ef275defcb82bc70740ae6dc507aee51 \ - --hash=sha256:fa130dd50c57d53368c9d59395cb5526eda596d3ffe36666cd81a44d56e48872 - # via - # -r requirements.in - # jinja2 -packaging==21.3 \ - --hash=sha256:dd47c42927d89ab911e606518907cc2d3a1f38bbd026385970643f9c5b8ecfeb \ - --hash=sha256:ef103e05f519cdc783ae24ea4e2e0f508a9c99b2d4969652eed6a2e1ea5bd522 - # via - # -r requirements.in - # gcp-releasetool -protobuf==3.19.5 \ - --hash=sha256:1867f93b06a183f87696871bb8d1e99ee71dbb69d468ce1f0cc8bf3d30f982f3 \ - --hash=sha256:3c4160b601220627f7e91154e572baf5e161a9c3f445a8242d536ee3d0b7b17c \ - --hash=sha256:4ee2af7051d3b10c8a4fe6fd1a2c69f201fea36aeee7086cf202a692e1b99ee1 \ - --hash=sha256:5266c36cc0af3bb3dbf44f199d225b33da66a9a5c3bdc2b14865ad10eddf0e37 \ - --hash=sha256:5470f892961af464ae6eaf0f3099e2c1190ae8c7f36f174b89491281341f79ca \ - --hash=sha256:66d14b5b90090353efe75c9fb1bf65ef7267383034688d255b500822e37d5c2f \ - --hash=sha256:67efb5d20618020aa9596e17bfc37ca068c28ec0c1507d9507f73c93d46c9855 \ - --hash=sha256:696e6cfab94cc15a14946f2bf72719dced087d437adbd994fff34f38986628bc \ - --hash=sha256:6a02172b9650f819d01fb8e224fc69b0706458fc1ab4f1c669281243c71c1a5e \ - --hash=sha256:6eca9ae238ba615d702387a2ddea635d535d769994a9968c09a4ca920c487ab9 \ - --hash=sha256:950abd6c00e7b51f87ae8b18a0ce4d69fea217f62f171426e77de5061f6d9850 \ - --hash=sha256:9e1d74032f56ff25f417cfe84c8147047732e5059137ca42efad20cbbd25f5e0 \ - --hash=sha256:9e42b1cf2ecd8a1bd161239e693f22035ba99905ae6d7efeac8a0546c7ec1a27 \ - --hash=sha256:9f957ef53e872d58a0afd3bf6d80d48535d28c99b40e75e6634cbc33ea42fd54 \ - --hash=sha256:a89aa0c042e61e11ade320b802d6db4ee5391d8d973e46d3a48172c1597789f8 \ - --hash=sha256:c0f80876a8ff0ae7064084ed094eb86497bd5a3812e6fc96a05318b92301674e \ - --hash=sha256:c44e3282cff74ad18c7e8a0375f407f69ee50c2116364b44492a196293e08b21 \ - --hash=sha256:d249519ba5ecf5dd6b18150c9b6bcde510b273714b696f3923ff8308fc11ae49 \ - --hash=sha256:d3973a2d58aefc7d1230725c2447ce7f86a71cbc094b86a77c6ee1505ac7cdb1 \ - --hash=sha256:dca2284378a5f2a86ffed35c6ac147d14c48b525eefcd1083e5a9ce28dfa8657 \ - --hash=sha256:e63b0b3c42e51c94add62b010366cd4979cb6d5f06158bcae8faac4c294f91e1 \ - --hash=sha256:f2b599a21c9a32e171ec29a2ac54e03297736c578698e11b099d031f79da114b \ - --hash=sha256:f2bde37667b18c2b5280df83bc799204394a5d2d774e4deaf9de0eb741df6833 \ - --hash=sha256:f4f909f4dde413dec435a44b0894956d55bb928ded7d6e3c726556ca4c796e84 \ - --hash=sha256:f976234e20ab2785f54224bcdafa027674e23663b132fa3ca0caa291a6cfbde7 \ - --hash=sha256:f9cebda093c2f6bfed88f1c17cdade09d4d96096421b344026feee236532d4de - # via - # -r requirements.in - # gcp-docuploader - # gcp-releasetool - # google-api-core - # google-cloud-storage - # googleapis-common-protos -pyasn1==0.4.8 \ - --hash=sha256:39c7e2ec30515947ff4e87fb6f456dfc6e84857d34be479c9d4a4ba4bf46aa5d \ - --hash=sha256:aef77c9fb94a3ac588e87841208bdec464471d9871bd5050a287cc9a475cd0ba - # via - # pyasn1-modules - # rsa -pyasn1-modules==0.2.8 \ - --hash=sha256:905f84c712230b2c592c19470d3ca8d552de726050d1d1716282a1f6146be65e \ - --hash=sha256:a50b808ffeb97cb3601dd25981f6b016cbb3d31fbf57a8b8a87428e6158d0c74 - # via google-auth -pycparser==2.21 \ - --hash=sha256:8ee45429555515e1f6b185e78100aea234072576aa43ab53aefcae078162fca9 \ - --hash=sha256:e644fdec12f7872f86c58ff790da456218b10f863970249516d60a5eaca77206 - # via - # -r requirements.in - # cffi -pyjwt==2.4.0 \ - --hash=sha256:72d1d253f32dbd4f5c88eaf1fdc62f3a19f676ccbadb9dbc5d07e951b2b26daf \ - --hash=sha256:d42908208c699b3b973cbeb01a969ba6a96c821eefb1c5bfe4c390c01d67abba - # via - # -r requirements.in - # gcp-releasetool -pyparsing==3.0.9 \ - --hash=sha256:2b020ecf7d21b687f219b71ecad3631f644a47f01403fa1d1036b0c6416d70fb \ - --hash=sha256:5026bae9a10eeaefb61dab2f09052b9f4307d44aee4eda64b309723d8d206bbc - # via - # -r requirements.in - # packaging -pyperclip==1.8.2 \ - --hash=sha256:105254a8b04934f0bc84e9c24eb360a591aaf6535c9def5f29d92af107a9bf57 - # via - # -r requirements.in - # gcp-releasetool -python-dateutil==2.8.2 \ - --hash=sha256:0123cacc1627ae19ddf3c27a5de5bd67ee4586fbdd6440d9748f8abb483d3e86 \ - --hash=sha256:961d03dc3453ebbc59dbdea9e4e11c5651520a876d0f4db161e8674aae935da9 - # via - # -r requirements.in - # gcp-releasetool -requests==2.27.1 \ - --hash=sha256:68d7c56fd5a8999887728ef304a6d12edc7be74f1cfa47714fc8b414525c9a61 \ - --hash=sha256:f22fa1e554c9ddfd16e6e41ac79759e17be9e492b3587efa038054674760e72d - # via - # -r requirements.in - # gcp-releasetool - # google-api-core - # google-cloud-storage -rsa==4.9 \ - --hash=sha256:90260d9058e514786967344d0ef75fa8727eed8a7d2e43ce9f4bcf1b536174f7 \ - --hash=sha256:e38464a49c6c85d7f1351b0126661487a7e0a14a50f1675ec50eb34d4f20ef21 - # via - # -r requirements.in - # google-auth -secretstorage==3.3.3 \ - --hash=sha256:2403533ef369eca6d2ba81718576c5e0f564d5cca1b58f73a8b23e7d4eeebd77 \ - --hash=sha256:f356e6628222568e3af06f2eba8df495efa13b3b63081dafd4f7d9a7b7bc9f99 - # via keyring -six==1.16.0 \ - --hash=sha256:1e61c37477a1626458e36f7b1d82aa5c9b094fa4802892072e49de9c60c4c926 \ - --hash=sha256:8abb2f1d86890a2dfb989f9a77cfcfd3e47c2a354b01111771326f8aa26e0254 - # via - # -r requirements.in - # gcp-docuploader - # google-auth - # python-dateutil -typing-extensions==4.1.1 \ - --hash=sha256:1a9462dcc3347a79b1f1c0271fbe79e844580bb598bafa1ed208b94da3cdcd42 \ - --hash=sha256:21c85e0fe4b9a155d0799430b0ad741cdce7e359660ccbd8b530613e8df88ce2 - # via -r requirements.in -urllib3==1.26.12 \ - --hash=sha256:3fa96cf423e6987997fc326ae8df396db2a8b7c667747d47ddd8ecba91f4a74e \ - --hash=sha256:b930dd878d5a8afb066a637fbb35144fe7901e3b209d1cd4f524bd0e9deee997 - # via - # -r requirements.in - # requests -zipp==3.6.0 \ - --hash=sha256:71c644c5369f4a6e07636f0aa966270449561fcea2e3d6747b8d23efaa9d7832 \ - --hash=sha256:9fe5ea21568a0a70e50f273397638d39b03353731e6cbbb3fd8502a33fec40bc - # via - # -r requirements.in - # importlib-metadata diff --git a/.kokoro/trampoline.sh b/.kokoro/trampoline.sh deleted file mode 100644 index 8b69b793..00000000 --- a/.kokoro/trampoline.sh +++ /dev/null @@ -1,26 +0,0 @@ -#!/bin/bash -# Copyright 2018 Google LLC -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# http://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -set -eo pipefail -# Always run the cleanup script, regardless of the success of bouncing into -# the container. -function cleanup() { - chmod +x ${KOKORO_GFILE_DIR}/trampoline_cleanup.sh - ${KOKORO_GFILE_DIR}/trampoline_cleanup.sh - echo "cleanup"; -} -trap cleanup EXIT - -$(dirname $0)/populate-secrets.sh # Secret Manager secrets. -python3 "${KOKORO_GFILE_DIR}/trampoline_v1.py" diff --git a/.repo-metadata.json b/.repo-metadata.json deleted file mode 100644 index a3f9ff84..00000000 --- a/.repo-metadata.json +++ /dev/null @@ -1,18 +0,0 @@ -{ - "api_shortname": "cloudbuild", - "name_pretty": "Cloud Build", - "product_documentation": "https://cloud.google.com/cloud-build/", - "client_documentation": "https://cloud.google.com/java/docs/reference/google-cloud-build/latest/history", - "api_description": "lets you build software quickly across all languages. Get complete control over defining custom workflows for building, testing, and deploying across multiple environments such as VMs, serverless, Kubernetes, or Firebase.", - "issue_tracker": "https://issuetracker.google.com/savedsearches/5226584", - "release_level": "stable", - "language": "java", - "transport": "grpc", - "repo": "googleapis/java-cloudbuild", - "repo_short": "java-cloudbuild", - "distribution_name": "com.google.cloud:google-cloud-build", - "codeowner_team": "@googleapis/aap-dpes", - "api_id": "cloudbuild.googleapis.com", - "requires_billing": true, - "library_type": "GAPIC_AUTO" -} diff --git a/CHANGELOG.md b/CHANGELOG.md deleted file mode 100644 index 34e40d01..00000000 --- a/CHANGELOG.md +++ /dev/null @@ -1,603 +0,0 @@ -# Changelog - -## [3.5.6](https://github.com/googleapis/java-cloudbuild/compare/v3.5.5...v3.5.6) (2022-10-04) - - -### Dependencies - -* Update dependency com.google.cloud:google-cloud-shared-dependencies to v3.0.4 ([#814](https://github.com/googleapis/java-cloudbuild/issues/814)) ([5cbf28b](https://github.com/googleapis/java-cloudbuild/commit/5cbf28b9c9321111d6dc811d36d59cd4635e7c9b)) - -## [3.5.5](https://github.com/googleapis/java-cloudbuild/compare/v3.5.4...v3.5.5) (2022-09-27) - - -### Dependencies - -* Update dependency cachetools to v5 ([#809](https://github.com/googleapis/java-cloudbuild/issues/809)) ([ca6c52a](https://github.com/googleapis/java-cloudbuild/commit/ca6c52af55b9894ea45e218c64710517b906656e)) -* Update dependency certifi to v2022.9.24 ([#799](https://github.com/googleapis/java-cloudbuild/issues/799)) ([22c4ae8](https://github.com/googleapis/java-cloudbuild/commit/22c4ae84de213398bc7ba81953d0c4fa8d5f7654)) -* Update dependency google-auth to v2.11.1 ([#800](https://github.com/googleapis/java-cloudbuild/issues/800)) ([4a8e780](https://github.com/googleapis/java-cloudbuild/commit/4a8e7808320ed561667cbc76e9ca3323781594bc)) -* Update dependency jinja2 to v3.1.2 ([#801](https://github.com/googleapis/java-cloudbuild/issues/801)) ([0ccbc5a](https://github.com/googleapis/java-cloudbuild/commit/0ccbc5ab0f2d18474f18fd0c84d85ddead5676d3)) -* Update dependency keyring to v23.9.3 ([#802](https://github.com/googleapis/java-cloudbuild/issues/802)) ([5a0da57](https://github.com/googleapis/java-cloudbuild/commit/5a0da57d3211f49a3d6b61a0310dca850f2d739e)) -* Update dependency markupsafe to v2.1.1 ([#803](https://github.com/googleapis/java-cloudbuild/issues/803)) ([3246c6c](https://github.com/googleapis/java-cloudbuild/commit/3246c6cfc1101da3bb1706bfb0ec5a5882729924)) -* Update dependency protobuf to v3.20.2 ([#804](https://github.com/googleapis/java-cloudbuild/issues/804)) ([571aabe](https://github.com/googleapis/java-cloudbuild/commit/571aabed6eceb3d86d73d03e7fb2d98a751875de)) -* Update dependency pyjwt to v2.5.0 ([#805](https://github.com/googleapis/java-cloudbuild/issues/805)) ([9de32d3](https://github.com/googleapis/java-cloudbuild/commit/9de32d3bfea0b614333ea8601269539c38256863)) -* Update dependency requests to v2.28.1 ([#806](https://github.com/googleapis/java-cloudbuild/issues/806)) ([affd465](https://github.com/googleapis/java-cloudbuild/commit/affd4651305327b69b6577b3ed3cffb8153447cd)) -* Update dependency typing-extensions to v4.3.0 ([#807](https://github.com/googleapis/java-cloudbuild/issues/807)) ([f7b3b2c](https://github.com/googleapis/java-cloudbuild/commit/f7b3b2cfcfc4c6e9bdb5cf70cb6fa0faa4503375)) -* Update dependency zipp to v3.8.1 ([#808](https://github.com/googleapis/java-cloudbuild/issues/808)) ([8549944](https://github.com/googleapis/java-cloudbuild/commit/8549944a8c2769929a564222409a186c70daf404)) - -## [3.5.4](https://github.com/googleapis/java-cloudbuild/compare/v3.5.3...v3.5.4) (2022-09-15) - - -### Dependencies - -* Update dependency com.google.cloud:google-cloud-shared-dependencies to v3.0.3 ([#792](https://github.com/googleapis/java-cloudbuild/issues/792)) ([31995f4](https://github.com/googleapis/java-cloudbuild/commit/31995f42ac9d4904a16f9660facf1ff82c7df2f6)) - -## [3.5.3](https://github.com/googleapis/java-cloudbuild/compare/v3.5.2...v3.5.3) (2022-09-09) - - -### Dependencies - -* Update dependency com.google.cloud:google-cloud-shared-dependencies to v3.0.2 ([#787](https://github.com/googleapis/java-cloudbuild/issues/787)) ([ae125a8](https://github.com/googleapis/java-cloudbuild/commit/ae125a8dd95463afe5186935017be25a40602461)) - -## [3.5.2](https://github.com/googleapis/java-cloudbuild/compare/v3.5.1...v3.5.2) (2022-08-02) - - -### Dependencies - -* update dependency com.google.cloud:google-cloud-shared-dependencies to v3 ([#777](https://github.com/googleapis/java-cloudbuild/issues/777)) ([0490350](https://github.com/googleapis/java-cloudbuild/commit/04903503db99ac5c77da120e48c33ae7c63bf560)) - -## [3.5.1](https://github.com/googleapis/java-cloudbuild/compare/v3.5.0...v3.5.1) (2022-07-13) - - -### Bug Fixes - -* enable longpaths support for windows test ([#1485](https://github.com/googleapis/java-cloudbuild/issues/1485)) ([#768](https://github.com/googleapis/java-cloudbuild/issues/768)) ([59f3a4f](https://github.com/googleapis/java-cloudbuild/commit/59f3a4fe1f14888a553ae51e8336ace169c59b47)) - -## [3.5.0](https://github.com/googleapis/java-cloudbuild/compare/v3.4.1...v3.5.0) (2022-07-01) - - -### Features - -* Enable REST transport for most of Java and Go clients ([9a7011f](https://github.com/googleapis/java-cloudbuild/commit/9a7011f1cce8dd26fd1782c0953cd2c09d3626b1)) - - -### Bug Fixes - -* update gapic-generator-java with mock service generation fixes ([#755](https://github.com/googleapis/java-cloudbuild/issues/755)) ([9a7011f](https://github.com/googleapis/java-cloudbuild/commit/9a7011f1cce8dd26fd1782c0953cd2c09d3626b1)) - -## [3.4.1](https://github.com/googleapis/java-cloudbuild/compare/v3.4.0...v3.4.1) (2022-06-23) - - -### Dependencies - -* update dependency com.google.cloud:google-cloud-shared-dependencies to v2.13.0 ([#754](https://github.com/googleapis/java-cloudbuild/issues/754)) ([94e727c](https://github.com/googleapis/java-cloudbuild/commit/94e727c4ec9ef24862c89487198893e9caf95ae2)) - -## [3.4.0](https://github.com/googleapis/java-cloudbuild/compare/v3.3.13...v3.4.0) (2022-05-24) - - -### Features - -* add build scripts for native image testing in Java 17 ([#1440](https://github.com/googleapis/java-cloudbuild/issues/1440)) ([#746](https://github.com/googleapis/java-cloudbuild/issues/746)) ([22e4c1e](https://github.com/googleapis/java-cloudbuild/commit/22e4c1e63c0164af795cf74937902d314dbd01bb)) - - -### Dependencies - -* update dependency com.google.cloud:google-cloud-shared-dependencies to v2.11.0 ([#745](https://github.com/googleapis/java-cloudbuild/issues/745)) ([9f65635](https://github.com/googleapis/java-cloudbuild/commit/9f6563518bea1a8308a07863019d1c696b26a524)) -* update dependency com.google.cloud:google-cloud-shared-dependencies to v2.12.0 ([#747](https://github.com/googleapis/java-cloudbuild/issues/747)) ([cfb57fa](https://github.com/googleapis/java-cloudbuild/commit/cfb57fa9de18fc60b15a3938370ee13e1894ebb6)) - -### [3.3.13](https://github.com/googleapis/java-cloudbuild/compare/v3.3.12...v3.3.13) (2022-04-15) - - -### Dependencies - -* update dependency com.google.cloud:google-cloud-shared-dependencies to v2.10.0 ([#733](https://github.com/googleapis/java-cloudbuild/issues/733)) ([cc12cb7](https://github.com/googleapis/java-cloudbuild/commit/cc12cb7d098ae4d9b06ff53d7ee82050107f5907)) - -### [3.3.12](https://github.com/googleapis/java-cloudbuild/compare/v3.3.11...v3.3.12) (2022-03-29) - - -### Dependencies - -* update dependency com.google.cloud:google-cloud-shared-dependencies to v2.9.0 ([#726](https://github.com/googleapis/java-cloudbuild/issues/726)) ([e1ccc79](https://github.com/googleapis/java-cloudbuild/commit/e1ccc79636b3ea735a583036a73a79eef312d861)) - -### [3.3.11](https://github.com/googleapis/java-cloudbuild/compare/v3.3.10...v3.3.11) (2022-03-02) - - -### Dependencies - -* update dependency com.google.cloud:google-cloud-shared-dependencies to v2.8.0 ([#716](https://github.com/googleapis/java-cloudbuild/issues/716)) ([4a8173e](https://github.com/googleapis/java-cloudbuild/commit/4a8173edcc16e08da60ac402ac8343194b92306d)) - -### [3.3.10](https://github.com/googleapis/java-cloudbuild/compare/v3.3.9...v3.3.10) (2022-02-28) - - -### Dependencies - -* update actions/setup-java action to v3 ([#710](https://github.com/googleapis/java-cloudbuild/issues/710)) ([3f008c9](https://github.com/googleapis/java-cloudbuild/commit/3f008c9c39c71b2a3cf5e362fafb9b3e2c887b41)) - -### [3.3.9](https://github.com/googleapis/java-cloudbuild/compare/v3.3.8...v3.3.9) (2022-02-11) - - -### Dependencies - -* update actions/github-script action to v6 ([#701](https://github.com/googleapis/java-cloudbuild/issues/701)) ([8a64138](https://github.com/googleapis/java-cloudbuild/commit/8a641381ad92ca6e40e06fff667c9f2fb5951c57)) - -### [3.3.8](https://github.com/googleapis/java-cloudbuild/compare/v3.3.7...v3.3.8) (2022-02-03) - - -### Dependencies - -* **java:** update actions/github-script action to v5 ([#1339](https://github.com/googleapis/java-cloudbuild/issues/1339)) ([#689](https://github.com/googleapis/java-cloudbuild/issues/689)) ([87d3496](https://github.com/googleapis/java-cloudbuild/commit/87d349672b035547a5c7236d17d8f4a0857db3b1)) -* update actions/github-script action to v5 ([#688](https://github.com/googleapis/java-cloudbuild/issues/688)) ([0e9b3d5](https://github.com/googleapis/java-cloudbuild/commit/0e9b3d5f6a396fd9f64156a81ad1f3e8c0dbb6c6)) -* update dependency com.google.cloud:google-cloud-shared-dependencies to v2.7.0 ([#691](https://github.com/googleapis/java-cloudbuild/issues/691)) ([b22d4e9](https://github.com/googleapis/java-cloudbuild/commit/b22d4e9bc869c21cfb243a465fb4cce1b679e8d3)) - -### [3.3.7](https://www.github.com/googleapis/java-cloudbuild/compare/v3.3.6...v3.3.7) (2022-01-07) - - -### Bug Fixes - -* **java:** add -ntp flag to native image testing command ([#1299](https://www.github.com/googleapis/java-cloudbuild/issues/1299)) ([#662](https://www.github.com/googleapis/java-cloudbuild/issues/662)) ([0152600](https://www.github.com/googleapis/java-cloudbuild/commit/01526006b29fb5d8d7b506c06123d3596ddf708b)) - - -### Dependencies - -* update dependency com.google.cloud:google-cloud-shared-dependencies to v2.6.0 ([#671](https://www.github.com/googleapis/java-cloudbuild/issues/671)) ([f7d1929](https://www.github.com/googleapis/java-cloudbuild/commit/f7d1929057f6902cbf7220b90c58965af83fe794)) - -### [3.3.6](https://www.github.com/googleapis/java-cloudbuild/compare/v3.3.5...v3.3.6) (2021-12-03) - - -### Dependencies - -* update dependency com.google.cloud:google-cloud-shared-dependencies to v2.5.1 ([#658](https://www.github.com/googleapis/java-cloudbuild/issues/658)) ([d9a6d8c](https://www.github.com/googleapis/java-cloudbuild/commit/d9a6d8c011bfcb5260f4d24fde041b50523ca532)) - -### [3.3.5](https://www.github.com/googleapis/java-cloudbuild/compare/v3.3.4...v3.3.5) (2021-11-15) - - -### Dependencies - -* update dependency com.google.cloud:google-cloud-shared-dependencies to v2.5.0 ([#647](https://www.github.com/googleapis/java-cloudbuild/issues/647)) ([82227f0](https://www.github.com/googleapis/java-cloudbuild/commit/82227f09607a33ca09bc6b6d62d3c9cbc6d1df55)) - -### [3.3.4](https://www.github.com/googleapis/java-cloudbuild/compare/v3.3.3...v3.3.4) (2021-10-27) - - -### Bug Fixes - -* **java:** java 17 dependency arguments ([#1266](https://www.github.com/googleapis/java-cloudbuild/issues/1266)) ([#635](https://www.github.com/googleapis/java-cloudbuild/issues/635)) ([9587b4f](https://www.github.com/googleapis/java-cloudbuild/commit/9587b4fad467acf050bd085c42a0babb3bf05a92)) - -### [3.3.3](https://www.github.com/googleapis/java-cloudbuild/compare/v3.3.2...v3.3.3) (2021-10-19) - - -### Dependencies - -* update dependency com.google.cloud:google-cloud-shared-dependencies to v2.4.0 ([#630](https://www.github.com/googleapis/java-cloudbuild/issues/630)) ([442880d](https://www.github.com/googleapis/java-cloudbuild/commit/442880d9a9a7e8494253678d67092f83f78c7c16)) - -### [3.3.2](https://www.github.com/googleapis/java-cloudbuild/compare/v3.3.1...v3.3.2) (2021-09-22) - - -### Dependencies - -* update dependency com.google.cloud:google-cloud-shared-dependencies to v2.3.0 ([#617](https://www.github.com/googleapis/java-cloudbuild/issues/617)) ([88efb17](https://www.github.com/googleapis/java-cloudbuild/commit/88efb172685b764d429961619f7cc31113f446ec)) - -### [3.3.1](https://www.github.com/googleapis/java-cloudbuild/compare/v3.3.0...v3.3.1) (2021-09-14) - - -### Dependencies - -* update dependency com.google.cloud:google-cloud-shared-dependencies to v2.2.1 ([#610](https://www.github.com/googleapis/java-cloudbuild/issues/610)) ([e1e5258](https://www.github.com/googleapis/java-cloudbuild/commit/e1e5258b9a5e89b4aaeb7dcc8760ac674bf67c95)) - -## [3.3.0](https://www.github.com/googleapis/java-cloudbuild/compare/v3.2.0...v3.3.0) (2021-09-03) - - -### Features - -* Add script field to BuildStep message ([#584](https://www.github.com/googleapis/java-cloudbuild/issues/584)) ([1d7ba55](https://www.github.com/googleapis/java-cloudbuild/commit/1d7ba55644d47d3ce8f355dbf18322577777ba09)) -* Update cloudbuild proto with the service_account for BYOSA Triggers. ([#599](https://www.github.com/googleapis/java-cloudbuild/issues/599)) ([f4e035a](https://www.github.com/googleapis/java-cloudbuild/commit/f4e035a77408da6f0cc4d058b6dd346ba8d457bb)) - - -### Dependencies - -* update dependency com.google.cloud:google-cloud-shared-dependencies to v2.2.0 ([#596](https://www.github.com/googleapis/java-cloudbuild/issues/596)) ([4b2d414](https://www.github.com/googleapis/java-cloudbuild/commit/4b2d414f84d63e4fcd04b00c6a04d4bf02b71cc6)) - -## [3.2.0](https://www.github.com/googleapis/java-cloudbuild/compare/v3.1.0...v3.2.0) (2021-08-27) - - -### Features - -* Remove use of deprecated gradle command in java README ([#1196](https://www.github.com/googleapis/java-cloudbuild/issues/1196)) ([#589](https://www.github.com/googleapis/java-cloudbuild/issues/589)) ([8791708](https://www.github.com/googleapis/java-cloudbuild/commit/8791708b6b01e26108822b1c78be824e9a73af1e)) -* Update cloudbuild proto with the service_account for BYOSA Triggers. ([#586](https://www.github.com/googleapis/java-cloudbuild/issues/586)) ([84ce78e](https://www.github.com/googleapis/java-cloudbuild/commit/84ce78eec59d3889fdce3fd74234d5397aabb3d1)) - -## [3.1.0](https://www.github.com/googleapis/java-cloudbuild/compare/v3.0.1...v3.1.0) (2021-08-24) - - -### Features - -* Add ability to configure BuildTriggers to create Builds that require approval before executing and ApproveBuild API to approve or reject pending Builds ([#574](https://www.github.com/googleapis/java-cloudbuild/issues/574)) ([1e19e5a](https://www.github.com/googleapis/java-cloudbuild/commit/1e19e5adbe845c47b4b3d00e91f349a7b780142b)) - - -### Dependencies - -* update dependency com.google.cloud:google-cloud-shared-dependencies to v2.1.0 ([#579](https://www.github.com/googleapis/java-cloudbuild/issues/579)) ([79e20e1](https://www.github.com/googleapis/java-cloudbuild/commit/79e20e13fd6f4e55faced2a41e56004bf47958d7)) - -### [3.0.1](https://www.github.com/googleapis/java-cloudbuild/compare/v3.0.0...v3.0.1) (2021-08-12) - - -### Dependencies - -* update dependency com.google.cloud:google-cloud-shared-dependencies to v2.0.1 ([#568](https://www.github.com/googleapis/java-cloudbuild/issues/568)) ([e5a7e32](https://www.github.com/googleapis/java-cloudbuild/commit/e5a7e3289b3a070bb5d122063faea0220f150221)) - -## [3.0.0](https://www.github.com/googleapis/java-cloudbuild/compare/v2.6.4...v3.0.0) (2021-08-09) - - -### ⚠ BREAKING CHANGES - -* Proto had a prior definitions of WorkerPool resources which were never supported. This change replaces those resources with definitions that are currently supported. - -### Features - -* add a WorkerPools API ([fedb5cf](https://www.github.com/googleapis/java-cloudbuild/commit/fedb5cfbcc71383999a739cb41ca7a2ad86170a1)) -* Implementation of Build Failure Info: - Added message FailureInfo field ([fedb5cf](https://www.github.com/googleapis/java-cloudbuild/commit/fedb5cfbcc71383999a739cb41ca7a2ad86170a1)) -* release gapic-generator-java v2.0.0 ([#554](https://www.github.com/googleapis/java-cloudbuild/issues/554)) ([fedb5cf](https://www.github.com/googleapis/java-cloudbuild/commit/fedb5cfbcc71383999a739cb41ca7a2ad86170a1)) - - -### Documentation - -* Add a new build phase SETUPBUILD for timing information ([fedb5cf](https://www.github.com/googleapis/java-cloudbuild/commit/fedb5cfbcc71383999a739cb41ca7a2ad86170a1)) - -### [2.6.4](https://www.github.com/googleapis/java-cloudbuild/compare/v2.6.3...v2.6.4) (2021-08-06) - - -### Dependencies - -* update dependency com.google.cloud:google-cloud-shared-dependencies to v2 ([#555](https://www.github.com/googleapis/java-cloudbuild/issues/555)) ([99df8ab](https://www.github.com/googleapis/java-cloudbuild/commit/99df8abbdfc128409137abcfb8670d9dbb282c6d)) - -### [2.6.3](https://www.github.com/googleapis/java-cloudbuild/compare/v2.6.2...v2.6.3) (2021-07-15) - - -### Bug Fixes - -* owlbot post-processor should generate README ([#1154](https://www.github.com/googleapis/java-cloudbuild/issues/1154)) ([#531](https://www.github.com/googleapis/java-cloudbuild/issues/531)) ([9e6f397](https://www.github.com/googleapis/java-cloudbuild/commit/9e6f39711032048aacd58edeae9590563260ce4c)), closes [#1146](https://www.github.com/googleapis/java-cloudbuild/issues/1146) [#1147](https://www.github.com/googleapis/java-cloudbuild/issues/1147) - -### [2.6.2](https://www.github.com/googleapis/java-cloudbuild/compare/v2.6.1...v2.6.2) (2021-07-01) - - -### Bug Fixes - -* Add `shopt -s nullglob` to dependencies script ([#1130](https://www.github.com/googleapis/java-cloudbuild/issues/1130)) ([#516](https://www.github.com/googleapis/java-cloudbuild/issues/516)) ([68759da](https://www.github.com/googleapis/java-cloudbuild/commit/68759da8cced165e6f0a883eeeb918f6752dce25)) - - -### Dependencies - -* update dependency com.google.cloud:google-cloud-shared-dependencies to v1.4.0 ([#522](https://www.github.com/googleapis/java-cloudbuild/issues/522)) ([73d6288](https://www.github.com/googleapis/java-cloudbuild/commit/73d6288de0b148eb3cf8db88fb889e14928502a9)) - -### [2.6.1](https://www.github.com/googleapis/java-cloudbuild/compare/v2.6.0...v2.6.1) (2021-06-04) - - -### Dependencies - -* update dependency com.google.cloud:google-cloud-shared-dependencies to v1.3.0 ([#501](https://www.github.com/googleapis/java-cloudbuild/issues/501)) ([77c0a4f](https://www.github.com/googleapis/java-cloudbuild/commit/77c0a4f19667e5d7fc5f05be8bc1f1be66901826)) - -## [2.6.0](https://www.github.com/googleapis/java-cloudbuild/compare/v2.5.0...v2.6.0) (2021-05-19) - - -### Features - -* add `gcf-owl-bot[bot]` to `ignoreAuthors` ([#488](https://www.github.com/googleapis/java-cloudbuild/issues/488)) ([112973b](https://www.github.com/googleapis/java-cloudbuild/commit/112973b03fbfea0859a7350d6b4e55eb4d83dfb0)) - - -### Dependencies - -* update dependency com.google.cloud:google-cloud-shared-dependencies to v1.2.0 ([#487](https://www.github.com/googleapis/java-cloudbuild/issues/487)) ([760bf88](https://www.github.com/googleapis/java-cloudbuild/commit/760bf88d5ed98a970740c0f7e3a7c9692623c98a)) - -## [2.5.0](https://www.github.com/googleapis/java-cloudbuild/compare/v2.4.0...v2.5.0) (2021-05-13) - - -### Features - -* Implementation of Source Manifests: - Added message StorageSourceManifest as an option for the Source message - Added StorageSourceManifest field to the SourceProvenance message ([#473](https://www.github.com/googleapis/java-cloudbuild/issues/473)) ([46755bf](https://www.github.com/googleapis/java-cloudbuild/commit/46755bf2d6233c560ddc35ee1ecdd81bacb3358d)) - - -### Dependencies - -* update dependency com.google.cloud:google-cloud-shared-dependencies to v1.1.0 ([#477](https://www.github.com/googleapis/java-cloudbuild/issues/477)) ([0a1f601](https://www.github.com/googleapis/java-cloudbuild/commit/0a1f60101aaf7ecb44a425952259807ba10216c4)) - -## [2.4.0](https://www.github.com/googleapis/java-cloudbuild/compare/v2.3.1...v2.4.0) (2021-04-23) - - -### Features - -* Add fields for Pub/Sub triggers ([#457](https://www.github.com/googleapis/java-cloudbuild/issues/457)) ([55b10de](https://www.github.com/googleapis/java-cloudbuild/commit/55b10de722d09d8a861fc1325eeda14a208add15)) - - -### Bug Fixes - -* release scripts from issuing overlapping phases ([#456](https://www.github.com/googleapis/java-cloudbuild/issues/456)) ([ad05975](https://www.github.com/googleapis/java-cloudbuild/commit/ad0597543005b36650c577490f8a93a5511fa1c2)) -* typo ([#453](https://www.github.com/googleapis/java-cloudbuild/issues/453)) ([dffb9db](https://www.github.com/googleapis/java-cloudbuild/commit/dffb9db12cc0f557031e1509c5ff13239443e6ba)) - - -### Dependencies - -* update dependency com.google.cloud:google-cloud-shared-dependencies to v0.21.1 ([#460](https://www.github.com/googleapis/java-cloudbuild/issues/460)) ([d34cd4d](https://www.github.com/googleapis/java-cloudbuild/commit/d34cd4d347e637c847900ada7aca788608c69fb8)) -* update dependency com.google.cloud:google-cloud-shared-dependencies to v1 ([#463](https://www.github.com/googleapis/java-cloudbuild/issues/463)) ([82711b3](https://www.github.com/googleapis/java-cloudbuild/commit/82711b36eeeebf187566586e9e2d6441e074562b)) - -### [2.3.1](https://www.github.com/googleapis/java-cloudbuild/compare/v2.3.0...v2.3.1) (2021-04-09) - - -### Dependencies - -* update dependency com.google.cloud:google-cloud-shared-dependencies to v0.21.0 ([#443](https://www.github.com/googleapis/java-cloudbuild/issues/443)) ([c35948a](https://www.github.com/googleapis/java-cloudbuild/commit/c35948a9ff3e4f901d02711d222e69dc57848b7d)) - -## [2.3.0](https://www.github.com/googleapis/java-cloudbuild/compare/v2.2.2...v2.3.0) (2021-03-30) - - -### Features - -* Add `COMMENTS_ENABLED_FOR_EXTERNAL_CONTRIBUTORS_ONLY` for corresponding comment control behavior with triggered builds. ([be35172](https://www.github.com/googleapis/java-cloudbuild/commit/be35172f0fea6a48a863278eb741722c03f7946e)) -* Add `E2_HIGHCPU_8` and `E2_HIGHCPU_32` machine types. ([be35172](https://www.github.com/googleapis/java-cloudbuild/commit/be35172f0fea6a48a863278eb741722c03f7946e)) -* Add `ReceiveTriggerWebhook` for webhooks activating specific triggers. ([be35172](https://www.github.com/googleapis/java-cloudbuild/commit/be35172f0fea6a48a863278eb741722c03f7946e)) -* Add `SecretManager`-related resources and messages for corresponding integration. ([be35172](https://www.github.com/googleapis/java-cloudbuild/commit/be35172f0fea6a48a863278eb741722c03f7946e)) - - -### Documentation - -* Add `$PROJECT_NUMBER` as a substitution variable. ([be35172](https://www.github.com/googleapis/java-cloudbuild/commit/be35172f0fea6a48a863278eb741722c03f7946e)) -* Clarify lifetime/expiration behavior around `ListBuilds` page tokens. ([be35172](https://www.github.com/googleapis/java-cloudbuild/commit/be35172f0fea6a48a863278eb741722c03f7946e)) -* Update field docs on required-ness behavior and fix typos. ([be35172](https://www.github.com/googleapis/java-cloudbuild/commit/be35172f0fea6a48a863278eb741722c03f7946e)) - -### [2.2.2](https://www.github.com/googleapis/java-cloudbuild/compare/v2.2.1...v2.2.2) (2021-03-11) - - -### Dependencies - -* update dependency com.google.cloud:google-cloud-shared-dependencies to v0.20.1 ([#424](https://www.github.com/googleapis/java-cloudbuild/issues/424)) ([b9dac76](https://www.github.com/googleapis/java-cloudbuild/commit/b9dac766182f2fdf5666f74498c1ef91c9f36c89)) - -### [2.2.1](https://www.github.com/googleapis/java-cloudbuild/compare/v2.2.0...v2.2.1) (2021-02-25) - - -### Dependencies - -* update dependency com.google.cloud:google-cloud-shared-dependencies to v0.20.0 ([#410](https://www.github.com/googleapis/java-cloudbuild/issues/410)) ([089be9f](https://www.github.com/googleapis/java-cloudbuild/commit/089be9f54e886dc33d67bd219f3b0f4ddc5d5554)) - -## [2.2.0](https://www.github.com/googleapis/java-cloudbuild/compare/v2.1.11...v2.2.0) (2021-02-25) - - -### Features - -* generate sample code in the Java microgenerator ([#389](https://www.github.com/googleapis/java-cloudbuild/issues/389)) ([8e125d1](https://www.github.com/googleapis/java-cloudbuild/commit/8e125d1544b811bfba006bb02a1ef6e0e52aa435)) - -### [2.1.11](https://www.github.com/googleapis/java-cloudbuild/compare/v2.1.10...v2.1.11) (2021-02-19) - - -### Dependencies - -* update dependency com.google.cloud:google-cloud-shared-dependencies to v0.19.0 ([#396](https://www.github.com/googleapis/java-cloudbuild/issues/396)) ([3f1d74d](https://www.github.com/googleapis/java-cloudbuild/commit/3f1d74dd73eab829bdff0cdd710ec6c033029649)) - -### [2.1.10](https://www.github.com/googleapis/java-cloudbuild/compare/v2.1.9...v2.1.10) (2021-01-14) - - -### Dependencies - -* update dependency com.google.cloud:google-cloud-shared-dependencies to v0.18.0 ([#368](https://www.github.com/googleapis/java-cloudbuild/issues/368)) ([df368d9](https://www.github.com/googleapis/java-cloudbuild/commit/df368d99dc8d71272317fa1d731b845aca261f43)) - -### [2.1.9](https://www.github.com/googleapis/java-cloudbuild/compare/v2.1.8...v2.1.9) (2020-12-15) - - -### Dependencies - -* update dependency com.google.cloud:google-cloud-shared-dependencies to v0.17.0 ([#357](https://www.github.com/googleapis/java-cloudbuild/issues/357)) ([2e20fc1](https://www.github.com/googleapis/java-cloudbuild/commit/2e20fc17150bb6c027efa0dced4d8379d8a6c0ce)) - -### [2.1.8](https://www.github.com/googleapis/java-cloudbuild/compare/v2.1.7...v2.1.8) (2020-12-14) - - -### Dependencies - -* update dependency com.google.cloud:google-cloud-shared-dependencies to v0.16.1 ([82ebd94](https://www.github.com/googleapis/java-cloudbuild/commit/82ebd948c5527899c1af8bf3cef510f3433f6b08)) - -### [2.1.7](https://www.github.com/googleapis/java-cloudbuild/compare/v2.1.6...v2.1.7) (2020-12-02) - - -### Dependencies - -* update dependency com.google.cloud:google-cloud-shared-dependencies to v0.16.0 ([#340](https://www.github.com/googleapis/java-cloudbuild/issues/340)) ([f787291](https://www.github.com/googleapis/java-cloudbuild/commit/f787291f7eaefed97eeb979d04991bd90ab77dcb)) - -### [2.1.6](https://www.github.com/googleapis/java-cloudbuild/compare/v2.1.5...v2.1.6) (2020-11-17) - - -### Dependencies - -* update dependency com.google.cloud:google-cloud-shared-dependencies to v0.15.0 ([#321](https://www.github.com/googleapis/java-cloudbuild/issues/321)) ([ff44b47](https://www.github.com/googleapis/java-cloudbuild/commit/ff44b47e3fb3aa81f8dda65a15fd5ed96609157b)) - -### [2.1.5](https://www.github.com/googleapis/java-cloudbuild/compare/v2.1.4...v2.1.5) (2020-10-31) - - -### Dependencies - -* update dependency com.google.cloud:google-cloud-shared-dependencies to v0.14.1 ([#311](https://www.github.com/googleapis/java-cloudbuild/issues/311)) ([a30aa3f](https://www.github.com/googleapis/java-cloudbuild/commit/a30aa3f345f89ea381e79bbbd55c1675d8eb2a5d)) - -### [2.1.4](https://www.github.com/googleapis/java-cloudbuild/compare/v2.1.3...v2.1.4) (2020-10-21) - - -### Dependencies - -* update dependency com.google.cloud:google-cloud-shared-dependencies to v0.13.0 ([#295](https://www.github.com/googleapis/java-cloudbuild/issues/295)) ([17e8935](https://www.github.com/googleapis/java-cloudbuild/commit/17e8935d8b5cdb61da2196da4bfecc1cfe5dfba0)) - -### [2.1.3](https://www.github.com/googleapis/java-cloudbuild/compare/v2.1.2...v2.1.3) (2020-10-19) - - -### Dependencies - -* update dependency com.google.cloud:google-cloud-shared-dependencies to v0.12.1 ([#289](https://www.github.com/googleapis/java-cloudbuild/issues/289)) ([52a8e53](https://www.github.com/googleapis/java-cloudbuild/commit/52a8e539139c66d02be693f512daf148a834ff27)) - -### [2.1.2](https://www.github.com/googleapis/java-cloudbuild/compare/v2.1.1...v2.1.2) (2020-10-12) - - -### Dependencies - -* update dependency com.google.cloud:google-cloud-shared-dependencies to v0.10.2 ([#271](https://www.github.com/googleapis/java-cloudbuild/issues/271)) ([24e005a](https://www.github.com/googleapis/java-cloudbuild/commit/24e005a488798a28812a83c33c22d6665769832a)) - -### [2.1.1](https://www.github.com/googleapis/java-cloudbuild/compare/v2.1.0...v2.1.1) (2020-09-23) - - -### Dependencies - -* update dependency com.google.cloud:google-cloud-shared-dependencies to v0.10.0 ([#256](https://www.github.com/googleapis/java-cloudbuild/issues/256)) ([d54c253](https://www.github.com/googleapis/java-cloudbuild/commit/d54c253ae014f0066d922b1f2636eac180cf55bf)) - -## [2.1.0](https://www.github.com/googleapis/java-cloudbuild/compare/v2.0.2...v2.1.0) (2020-09-22) - - -### Features - -* add dynamic_substitutions to BuildOptions, STACKDRIVER_ONLY/CLOUD_LOGGING_ONLY to LoggingMode, name/service_account to Build ([#246](https://www.github.com/googleapis/java-cloudbuild/issues/246)) ([455c410](https://www.github.com/googleapis/java-cloudbuild/commit/455c4101bc08461f1ab9944908e8ba642974dd15)) - -### [2.0.2](https://www.github.com/googleapis/java-cloudbuild/compare/v2.0.1...v2.0.2) (2020-09-21) - - -### Dependencies - -* update dependency com.google.cloud:google-cloud-shared-dependencies to v0.9.0 ([#236](https://www.github.com/googleapis/java-cloudbuild/issues/236)) ([37f2ff9](https://www.github.com/googleapis/java-cloudbuild/commit/37f2ff98c064df3d65238d52b12a476c81fcbf2b)) - -### [2.0.1](https://www.github.com/googleapis/java-cloudbuild/compare/v2.0.0...v2.0.1) (2020-08-07) - - -### Bug Fixes - -* convert to grpc_service_config ([#213](https://www.github.com/googleapis/java-cloudbuild/issues/213)) ([c83d27e](https://www.github.com/googleapis/java-cloudbuild/commit/c83d27e4e93d159490de487d3da24db0e4ab40ef)) -* inline markup spans must be separated from the surrounding text by non-word characters ([#214](https://www.github.com/googleapis/java-cloudbuild/issues/214)) ([a692395](https://www.github.com/googleapis/java-cloudbuild/commit/a692395ed77d941ae96c5a5e290d5af9ef978aa2)) - - -### Dependencies - -* update dependency com.google.cloud:google-cloud-shared-dependencies to v0.8.2 ([#206](https://www.github.com/googleapis/java-cloudbuild/issues/206)) ([4aac14a](https://www.github.com/googleapis/java-cloudbuild/commit/4aac14afb46ed4aced878a8f2a5a194e06fc4ab5)) -* update dependency com.google.cloud:google-cloud-shared-dependencies to v0.8.3 ([#209](https://www.github.com/googleapis/java-cloudbuild/issues/209)) ([17c742d](https://www.github.com/googleapis/java-cloudbuild/commit/17c742d3a8b69b204a28b71e5c2341bcfe1d9fa1)) -* update dependency com.google.cloud:google-cloud-shared-dependencies to v0.8.6 ([7311dea](https://www.github.com/googleapis/java-cloudbuild/commit/7311deaeeac8d375b814d6da444a746cb9a8adb1)) - - -### Documentation - -* update generated docs ([#216](https://www.github.com/googleapis/java-cloudbuild/issues/216)) ([ef26812](https://www.github.com/googleapis/java-cloudbuild/commit/ef26812c7c7b91258bcd326f892162bd92688fb2)) - -## [2.0.0](https://www.github.com/googleapis/java-cloudbuild/compare/v1.1.1...v2.0.0) (2020-06-23) - - -### ⚠ BREAKING CHANGES - -* createBuild, retryBuild, runBuildTrigger are LRO, listBuildTriggers returns paginated responses (#150) - -### Features - -* createBuild, retryBuild, runBuildTrigger are LRO, listBuildTriggers returns paginated responses ([#150](https://www.github.com/googleapis/java-cloudbuild/issues/150)) ([e66c82d](https://www.github.com/googleapis/java-cloudbuild/commit/e66c82db4ed0b3501dd08f4bb3af9ec989a670ef)) -* **deps:** adopt flatten plugin and google-cloud-shared-dependencies ([#188](https://www.github.com/googleapis/java-cloudbuild/issues/188)) ([d06149a](https://www.github.com/googleapis/java-cloudbuild/commit/d06149ad9b062e610381774b5ee26f420b080770)) - - -### Dependencies - -* update dependency com.google.api:api-common to v1.9.1 ([#167](https://www.github.com/googleapis/java-cloudbuild/issues/167)) ([7cf2b56](https://www.github.com/googleapis/java-cloudbuild/commit/7cf2b563f9d6ae8995ab1ddaf4876ff3e932ef8e)) -* update dependency com.google.api:api-common to v1.9.2 ([#175](https://www.github.com/googleapis/java-cloudbuild/issues/175)) ([09291dc](https://www.github.com/googleapis/java-cloudbuild/commit/09291dcbe5a375d6ee850e4425bc0c94a44cfba2)) -* update dependency com.google.api.grpc:proto-google-common-protos to v1.18.0 ([#155](https://www.github.com/googleapis/java-cloudbuild/issues/155)) ([02d3f71](https://www.github.com/googleapis/java-cloudbuild/commit/02d3f71eee4332c8176858fd29cb1f4b21f9ff86)) -* update dependency com.google.cloud:google-cloud-core-grpc to v1.93.5 ([#168](https://www.github.com/googleapis/java-cloudbuild/issues/168)) ([41a763a](https://www.github.com/googleapis/java-cloudbuild/commit/41a763ad751322853a50f6206c2447d7027b55bc)) -* update dependency com.google.guava:guava-bom to v29 ([#131](https://www.github.com/googleapis/java-cloudbuild/issues/131)) ([f8a5099](https://www.github.com/googleapis/java-cloudbuild/commit/f8a509970b28211531595e743a9579c8725b86e7)) -* update dependency com.google.protobuf:protobuf-java to v3.12.0 ([#159](https://www.github.com/googleapis/java-cloudbuild/issues/159)) ([555e370](https://www.github.com/googleapis/java-cloudbuild/commit/555e3706c2080b90ff69d2c20a2e15f4dc959531)) -* update dependency com.google.protobuf:protobuf-java to v3.12.2 ([#165](https://www.github.com/googleapis/java-cloudbuild/issues/165)) ([407e6c5](https://www.github.com/googleapis/java-cloudbuild/commit/407e6c556cfc02f73cd13865f104cec99dafaef4)) -* update dependency io.grpc:grpc-bom to v1.29.0 ([#145](https://www.github.com/googleapis/java-cloudbuild/issues/145)) ([9080b63](https://www.github.com/googleapis/java-cloudbuild/commit/9080b63eddefbceafde6cffd0776ade99278a2fd)) -* update dependency io.grpc:grpc-bom to v1.30.0 ([#179](https://www.github.com/googleapis/java-cloudbuild/issues/179)) ([588e18d](https://www.github.com/googleapis/java-cloudbuild/commit/588e18df2a838cdacac2ca3eee3b474c8d2f5578)) -* update dependency org.threeten:threetenbp to v1.4.4 ([#149](https://www.github.com/googleapis/java-cloudbuild/issues/149)) ([1802480](https://www.github.com/googleapis/java-cloudbuild/commit/1802480470a975495c54a3eed9285963af391fc0)) - -### [1.1.1](https://www.github.com/googleapis/java-cloudbuild/compare/v1.1.0...v1.1.1) (2020-04-07) - - -### Dependencies - -* update core dependencies ([#91](https://www.github.com/googleapis/java-cloudbuild/issues/91)) ([bf9e89b](https://www.github.com/googleapis/java-cloudbuild/commit/bf9e89bd289c3f0d1fc04fde59bfc18c1999c3e6)) -* update dependency com.google.cloud:google-cloud-core-grpc to v1.93.4 ([#123](https://www.github.com/googleapis/java-cloudbuild/issues/123)) ([53ee168](https://www.github.com/googleapis/java-cloudbuild/commit/53ee168a8ae66757696a0c00531cf245b98c6ca2)) -* update dependency org.threeten:threetenbp to v1.4.3 ([#104](https://www.github.com/googleapis/java-cloudbuild/issues/104)) ([857dfbe](https://www.github.com/googleapis/java-cloudbuild/commit/857dfbe177714417c832e5a917b94756e8f69d7e)) - -## [1.1.0](https://www.github.com/googleapis/java-cloudbuild/compare/v1.0.3...v1.1.0) (2020-03-30) - - -### Features - -* add queue_ttl to Build, invert_regex to RepoSource ([#100](https://www.github.com/googleapis/java-cloudbuild/issues/100)) ([db14077](https://www.github.com/googleapis/java-cloudbuild/commit/db14077a07f54a260d26483868866b16b200cd2b)) - - -### Dependencies - -* update dependency com.google.api:api-common to v1.9.0 ([#112](https://www.github.com/googleapis/java-cloudbuild/issues/112)) ([76452e2](https://www.github.com/googleapis/java-cloudbuild/commit/76452e288e5d4215057c369e21102009b9ca27b1)) - -### [1.0.3](https://www.github.com/googleapis/java-cloudbuild/compare/v1.0.2...v1.0.3) (2020-03-03) - - -### Dependencies - -* update dependency com.google.cloud:google-cloud-core-grpc to v1.93.1 ([#89](https://www.github.com/googleapis/java-cloudbuild/issues/89)) ([f9c0e9c](https://www.github.com/googleapis/java-cloudbuild/commit/f9c0e9c505b3704c8c1b77368a579a3ad5b8bed3)) - -### [1.0.2](https://www.github.com/googleapis/java-cloudbuild/compare/v1.0.1...v1.0.2) (2020-02-28) - - -### Dependencies - -* update core dependencies to v1.54.0 ([#85](https://www.github.com/googleapis/java-cloudbuild/issues/85)) ([e0de8c7](https://www.github.com/googleapis/java-cloudbuild/commit/e0de8c7d8255172c1e17bca9c4e4ed91f88354de)) -* update dependency com.google.cloud:google-cloud-core-grpc to v1.92.5 ([4ef605c](https://www.github.com/googleapis/java-cloudbuild/commit/4ef605cd3a3a9526f08ffe5ee0475599575b7440)) -* update dependency com.google.cloud:google-cloud-core-grpc to v1.93.0 ([#86](https://www.github.com/googleapis/java-cloudbuild/issues/86)) ([92cdf90](https://www.github.com/googleapis/java-cloudbuild/commit/92cdf9051e50d028eb4f9212339e5978a74328db)) -* update dependency com.google.protobuf:protobuf-java to v3.11.4 ([371e768](https://www.github.com/googleapis/java-cloudbuild/commit/371e768acfadbf0adcfaced5660e19bf07c4ec8e)) -* update dependency io.grpc:grpc-bom to v1.27.1 ([195a990](https://www.github.com/googleapis/java-cloudbuild/commit/195a990978d62b17d9fa48a45b65c45ff3b75913)) -* update dependency io.grpc:grpc-bom to v1.27.2 ([e8e9df4](https://www.github.com/googleapis/java-cloudbuild/commit/e8e9df41f0499050d94fdc6ca7c1ab6498c0e62e)) - -### [1.0.1](https://www.github.com/googleapis/java-cloudbuild/compare/v1.0.0...v1.0.1) (2020-02-04) - - -### Dependencies - -* update core dependencies ([#44](https://www.github.com/googleapis/java-cloudbuild/issues/44)) ([739ef52](https://www.github.com/googleapis/java-cloudbuild/commit/739ef52c3032c6f122deb879f69e08c9cb357234)) -* update core dependencies ([#60](https://www.github.com/googleapis/java-cloudbuild/issues/60)) ([7177376](https://www.github.com/googleapis/java-cloudbuild/commit/71773763f4572f6b70109d40264f065017510f19)) -* update core dependencies ([#63](https://www.github.com/googleapis/java-cloudbuild/issues/63)) ([636bb16](https://www.github.com/googleapis/java-cloudbuild/commit/636bb1681f76b86145ade06c7cff969be59303ad)) -* update dependency com.google.guava:guava-bom to v28.2-android ([#42](https://www.github.com/googleapis/java-cloudbuild/issues/42)) ([370316a](https://www.github.com/googleapis/java-cloudbuild/commit/370316a25c524ea14e88e1521b85eb0c43d2f2a2)) -* update dependency com.google.protobuf:protobuf-java to v3.11.3 ([#65](https://www.github.com/googleapis/java-cloudbuild/issues/65)) ([79603c0](https://www.github.com/googleapis/java-cloudbuild/commit/79603c0a25fc0ad201d9f53a21f3fdc72fa90096)) - -## [1.0.0](https://www.github.com/googleapis/java-cloudbuild/compare/v0.1.1...v1.0.0) (2020-01-24) - - -### Features - -* promote to GA ([#57](https://www.github.com/googleapis/java-cloudbuild/issues/57)) ([944b404](https://www.github.com/googleapis/java-cloudbuild/commit/944b4046032067d1135e837f33a5ebf37774503c)) - - -### Dependencies - -* update dependency org.threeten:threetenbp to v1.4.1 ([1a55c7b](https://www.github.com/googleapis/java-cloudbuild/commit/1a55c7b0e42e91fddcdc829c1ff567e7ede5c5b9)) - -### [0.1.1](https://www.github.com/googleapis/java-cloudbuild/compare/v0.1.0...v0.1.1) (2020-01-07) - - -### Dependencies - -* update dependency com.google.cloud:google-cloud-core-grpc to v1.92.0 ([#33](https://www.github.com/googleapis/java-cloudbuild/issues/33)) ([c40f994](https://www.github.com/googleapis/java-cloudbuild/commit/c40f99419fcae386510751433e7ce355c542215d)) -* update dependency com.google.protobuf:protobuf-java to v3.11.0 ([#29](https://www.github.com/googleapis/java-cloudbuild/issues/29)) ([1a4656c](https://www.github.com/googleapis/java-cloudbuild/commit/1a4656c573fc5192e8690fa31d79ff0fac5e955b)) -* update dependency com.google.protobuf:protobuf-java to v3.11.1 ([17cac58](https://www.github.com/googleapis/java-cloudbuild/commit/17cac58eb284be9428e3a69d04bcda8107f54408)) -* update dependency io.grpc:grpc-bom to v1.26.0 ([#38](https://www.github.com/googleapis/java-cloudbuild/issues/38)) ([3b17aac](https://www.github.com/googleapis/java-cloudbuild/commit/3b17aac86bb11bd34ae61c80b2caa91d58429291)) -* update gax.version to v1.52.0 ([#32](https://www.github.com/googleapis/java-cloudbuild/issues/32)) ([3783661](https://www.github.com/googleapis/java-cloudbuild/commit/378366131d2b3f66b74e7dc098ea0bfb34b3d988)) - -## 0.1.0 (2019-11-11) - - -### Features - -* initial commit ([70fae93](https://www.github.com/googleapis/java-cloudbuild/commit/70fae93284701ba986b67265c5ca5f5ff1152a50)) -* regenerate initial version ([5de1123](https://www.github.com/googleapis/java-cloudbuild/commit/5de1123a8083658c0d6bbbc1024b58145190a413)) - - -### Bug Fixes - -* rename artifact to google-cloud-build ([#14](https://www.github.com/googleapis/java-cloudbuild/issues/14)) ([5d127f2](https://www.github.com/googleapis/java-cloudbuild/commit/5d127f2e712ecdc5fe74c6885f45e067a96475a8)) - - -### Dependencies - -* update dependency com.google.cloud:google-cloud-core-grpc to v1.91.2 ([#1](https://www.github.com/googleapis/java-cloudbuild/issues/1)) ([9d62d45](https://www.github.com/googleapis/java-cloudbuild/commit/9d62d456b324d1b0fb48d8f78404dae3a6c94662)) -* update dependency com.google.cloud:google-cloud-core-grpc to v1.91.3 ([#13](https://www.github.com/googleapis/java-cloudbuild/issues/13)) ([80d982e](https://www.github.com/googleapis/java-cloudbuild/commit/80d982e59503285b6584aaf47170139825ea912f)) -* update dependency io.grpc:grpc-bom to v1.24.0 ([#3](https://www.github.com/googleapis/java-cloudbuild/issues/3)) ([76d06cb](https://www.github.com/googleapis/java-cloudbuild/commit/76d06cb9cc565b1afad7c7a1f6c684dedcf9ef65)) -* update dependency io.grpc:grpc-bom to v1.24.1 ([7ed40cd](https://www.github.com/googleapis/java-cloudbuild/commit/7ed40cd29572a55177440b8a85ae527c8e8efef3)) -* update dependency org.threeten:threetenbp to v1.4.0 ([#4](https://www.github.com/googleapis/java-cloudbuild/issues/4)) ([7d4a2a0](https://www.github.com/googleapis/java-cloudbuild/commit/7d4a2a0350a3bfbe6a2ce18774257765f7697b20)) -* update gax.version to v1.49.1 ([deee1f5](https://www.github.com/googleapis/java-cloudbuild/commit/deee1f56e2e6c07763b7674ed7045957c28fa952)) - - -### Documentation - -* fix artifact name in README ([#6](https://www.github.com/googleapis/java-cloudbuild/issues/6)) ([5359486](https://www.github.com/googleapis/java-cloudbuild/commit/53594868bbe6ebb646a971a640acb299034c6dc9)) -* regenerate client documentation, deprecate GitHubEventsConfig installationId ([#11](https://www.github.com/googleapis/java-cloudbuild/issues/11)) ([8f2094a](https://www.github.com/googleapis/java-cloudbuild/commit/8f2094a7efe0ef2229929e9928139ca52e946772)) -* update README with CI status table ([#7](https://www.github.com/googleapis/java-cloudbuild/issues/7)) ([519bc3b](https://www.github.com/googleapis/java-cloudbuild/commit/519bc3b02f0adee0c807b1c45043e0a5255d2ca7)) diff --git a/codecov.yaml b/codecov.yaml deleted file mode 100644 index 5724ea94..00000000 --- a/codecov.yaml +++ /dev/null @@ -1,4 +0,0 @@ ---- -codecov: - ci: - - source.cloud.google.com diff --git a/google-cloud-build-bom/pom.xml b/google-cloud-build-bom/pom.xml deleted file mode 100644 index 5ca4aa7f..00000000 --- a/google-cloud-build-bom/pom.xml +++ /dev/null @@ -1,81 +0,0 @@ - - - 4.0.0 - com.google.cloud - google-cloud-build-bom - 3.5.7-SNAPSHOT - pom - - com.google.cloud - google-cloud-shared-config - 1.5.3 - - - Google Cloud Build BOM - https://github.com/googleapis/java-cloudbuild - - BOM for Google CloudBuild - - - - Google LLC - - - - - chingor13 - Jeff Ching - chingor@google.com - Google LLC - - Developer - - - - - - scm:git:https://github.com/googleapis/java-cloudbuild.git - scm:git:git@github.com:googleapis/java-cloudbuild.git - https://github.com/googleapis/java-cloudbuild - - - - - The Apache Software License, Version 2.0 - http://www.apache.org/licenses/LICENSE-2.0.txt - repo - - - - - - - com.google.cloud - google-cloud-build - 3.5.7-SNAPSHOT - - - com.google.api.grpc - grpc-google-cloud-build-v1 - 3.5.7-SNAPSHOT - - - com.google.api.grpc - proto-google-cloud-build-v1 - 3.5.7-SNAPSHOT - - - - - - - - org.apache.maven.plugins - maven-checkstyle-plugin - - true - - - - - diff --git a/google-cloud-build/pom.xml b/google-cloud-build/pom.xml deleted file mode 100644 index 6a1e0dac..00000000 --- a/google-cloud-build/pom.xml +++ /dev/null @@ -1,126 +0,0 @@ - - - 4.0.0 - com.google.cloud - google-cloud-build - 3.5.7-SNAPSHOT - jar - Google Cloud Build - https://github.com/googleapis/java-cloudbuild - - Java idiomatic client for Google Cloud Build. - - - com.google.cloud - google-cloud-build-parent - 3.5.7-SNAPSHOT - - - google-cloud-build - - - - io.grpc - grpc-api - - - io.grpc - grpc-stub - - - io.grpc - grpc-protobuf - - - com.google.api - api-common - - - com.google.protobuf - protobuf-java - - - com.google.api.grpc - proto-google-common-protos - - - com.google.api.grpc - proto-google-cloud-build-v1 - - - com.google.guava - guava - - - com.google.api - gax - - - com.google.api - gax-grpc - - - com.google.api - gax-httpjson - - - org.threeten - threetenbp - - - - - junit - junit - test - - - com.google.api.grpc - grpc-google-cloud-build-v1 - test - - - - com.google.api - gax - testlib - test - - - com.google.api - gax-grpc - testlib - test - - - com.google.api - gax-httpjson - testlib - test - - - - - - java9 - - [9,) - - - - javax.annotation - javax.annotation-api - - - - - - - - - org.codehaus.mojo - flatten-maven-plugin - - - - diff --git a/google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/CloudBuildClient.java b/google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/CloudBuildClient.java deleted file mode 100644 index b251a531..00000000 --- a/google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/CloudBuildClient.java +++ /dev/null @@ -1,2810 +0,0 @@ -/* - * Copyright 2022 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package com.google.cloud.devtools.cloudbuild.v1; - -import com.google.api.core.ApiFuture; -import com.google.api.core.ApiFutures; -import com.google.api.core.BetaApi; -import com.google.api.gax.core.BackgroundResource; -import com.google.api.gax.httpjson.longrunning.OperationsClient; -import com.google.api.gax.longrunning.OperationFuture; -import com.google.api.gax.paging.AbstractFixedSizeCollection; -import com.google.api.gax.paging.AbstractPage; -import com.google.api.gax.paging.AbstractPagedListResponse; -import com.google.api.gax.rpc.OperationCallable; -import com.google.api.gax.rpc.PageContext; -import com.google.api.gax.rpc.UnaryCallable; -import com.google.cloud.devtools.cloudbuild.v1.stub.CloudBuildStub; -import com.google.cloud.devtools.cloudbuild.v1.stub.CloudBuildStubSettings; -import com.google.cloudbuild.v1.ApprovalResult; -import com.google.cloudbuild.v1.ApproveBuildRequest; -import com.google.cloudbuild.v1.Build; -import com.google.cloudbuild.v1.BuildOperationMetadata; -import com.google.cloudbuild.v1.BuildTrigger; -import com.google.cloudbuild.v1.CancelBuildRequest; -import com.google.cloudbuild.v1.CreateBuildRequest; -import com.google.cloudbuild.v1.CreateBuildTriggerRequest; -import com.google.cloudbuild.v1.CreateWorkerPoolOperationMetadata; -import com.google.cloudbuild.v1.CreateWorkerPoolRequest; -import com.google.cloudbuild.v1.DeleteBuildTriggerRequest; -import com.google.cloudbuild.v1.DeleteWorkerPoolOperationMetadata; -import com.google.cloudbuild.v1.DeleteWorkerPoolRequest; -import com.google.cloudbuild.v1.GetBuildRequest; -import com.google.cloudbuild.v1.GetBuildTriggerRequest; -import com.google.cloudbuild.v1.GetWorkerPoolRequest; -import com.google.cloudbuild.v1.ListBuildTriggersRequest; -import com.google.cloudbuild.v1.ListBuildTriggersResponse; -import com.google.cloudbuild.v1.ListBuildsRequest; -import com.google.cloudbuild.v1.ListBuildsResponse; -import com.google.cloudbuild.v1.ListWorkerPoolsRequest; -import com.google.cloudbuild.v1.ListWorkerPoolsResponse; -import com.google.cloudbuild.v1.LocationName; -import com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest; -import com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse; -import com.google.cloudbuild.v1.RepoSource; -import com.google.cloudbuild.v1.RetryBuildRequest; -import com.google.cloudbuild.v1.RunBuildTriggerRequest; -import com.google.cloudbuild.v1.UpdateBuildTriggerRequest; -import com.google.cloudbuild.v1.UpdateWorkerPoolOperationMetadata; -import com.google.cloudbuild.v1.UpdateWorkerPoolRequest; -import com.google.cloudbuild.v1.WorkerPool; -import com.google.cloudbuild.v1.WorkerPoolName; -import com.google.common.util.concurrent.MoreExecutors; -import com.google.longrunning.Operation; -import com.google.protobuf.Empty; -import com.google.protobuf.FieldMask; -import java.io.IOException; -import java.util.List; -import java.util.concurrent.TimeUnit; -import javax.annotation.Generated; - -// AUTO-GENERATED DOCUMENTATION AND CLASS. -/** - * Service Description: Creates and manages builds on Google Cloud Platform. - * - *

The main concept used by this API is a `Build`, which describes the location of the source to - * build, how to build the source, and where to store the built artifacts, if any. - * - *

A user can list previously-requested builds or get builds by their ID to determine the status - * of the build. - * - *

This class provides the ability to make remote calls to the backing service through method - * calls that map to API methods. Sample code to get started: - * - *

{@code
- * // This snippet has been automatically generated and should be regarded as a code template only.
- * // It will require modifications to work:
- * // - It may require correct/in-range values for request initialization.
- * // - It may require specifying regional endpoints when creating the service client as shown in
- * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
- * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
- *   String projectId = "projectId-894832108";
- *   String id = "id3355";
- *   Build response = cloudBuildClient.getBuild(projectId, id);
- * }
- * }
- * - *

Note: close() needs to be called on the CloudBuildClient object to clean up resources such as - * threads. In the example above, try-with-resources is used, which automatically calls close(). - * - *

The surface of this class includes several types of Java methods for each of the API's - * methods: - * - *

    - *
  1. A "flattened" method. With this type of method, the fields of the request type have been - * converted into function parameters. It may be the case that not all fields are available as - * parameters, and not every API method will have a flattened method entry point. - *
  2. A "request object" method. This type of method only takes one parameter, a request object, - * which must be constructed before the call. Not every API method will have a request object - * method. - *
  3. A "callable" method. This type of method takes no parameters and returns an immutable API - * callable object, which can be used to initiate calls to the service. - *
- * - *

See the individual methods for example code. - * - *

Many parameters require resource names to be formatted in a particular way. To assist with - * these names, this class includes a format method for each type of name, and additionally a parse - * method to extract the individual identifiers contained within names that are returned. - * - *

This class can be customized by passing in a custom instance of CloudBuildSettings to - * create(). For example: - * - *

To customize credentials: - * - *

{@code
- * // This snippet has been automatically generated and should be regarded as a code template only.
- * // It will require modifications to work:
- * // - It may require correct/in-range values for request initialization.
- * // - It may require specifying regional endpoints when creating the service client as shown in
- * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
- * CloudBuildSettings cloudBuildSettings =
- *     CloudBuildSettings.newBuilder()
- *         .setCredentialsProvider(FixedCredentialsProvider.create(myCredentials))
- *         .build();
- * CloudBuildClient cloudBuildClient = CloudBuildClient.create(cloudBuildSettings);
- * }
- * - *

To customize the endpoint: - * - *

{@code
- * // This snippet has been automatically generated and should be regarded as a code template only.
- * // It will require modifications to work:
- * // - It may require correct/in-range values for request initialization.
- * // - It may require specifying regional endpoints when creating the service client as shown in
- * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
- * CloudBuildSettings cloudBuildSettings =
- *     CloudBuildSettings.newBuilder().setEndpoint(myEndpoint).build();
- * CloudBuildClient cloudBuildClient = CloudBuildClient.create(cloudBuildSettings);
- * }
- * - *

To use REST (HTTP1.1/JSON) transport (instead of gRPC) for sending and receiving requests over - * the wire: - * - *

{@code
- * // This snippet has been automatically generated and should be regarded as a code template only.
- * // It will require modifications to work:
- * // - It may require correct/in-range values for request initialization.
- * // - It may require specifying regional endpoints when creating the service client as shown in
- * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
- * CloudBuildSettings cloudBuildSettings =
- *     CloudBuildSettings.newBuilder()
- *         .setTransportChannelProvider(
- *             CloudBuildSettings.defaultHttpJsonTransportProviderBuilder().build())
- *         .build();
- * CloudBuildClient cloudBuildClient = CloudBuildClient.create(cloudBuildSettings);
- * }
- * - *

Please refer to the GitHub repository's samples for more quickstart code snippets. - */ -@Generated("by gapic-generator-java") -public class CloudBuildClient implements BackgroundResource { - private final CloudBuildSettings settings; - private final CloudBuildStub stub; - private final OperationsClient httpJsonOperationsClient; - private final com.google.longrunning.OperationsClient operationsClient; - - /** Constructs an instance of CloudBuildClient with default settings. */ - public static final CloudBuildClient create() throws IOException { - return create(CloudBuildSettings.newBuilder().build()); - } - - /** - * Constructs an instance of CloudBuildClient, using the given settings. The channels are created - * based on the settings passed in, or defaults for any settings that are not set. - */ - public static final CloudBuildClient create(CloudBuildSettings settings) throws IOException { - return new CloudBuildClient(settings); - } - - /** - * Constructs an instance of CloudBuildClient, using the given stub for making calls. This is for - * advanced usage - prefer using create(CloudBuildSettings). - */ - public static final CloudBuildClient create(CloudBuildStub stub) { - return new CloudBuildClient(stub); - } - - /** - * Constructs an instance of CloudBuildClient, using the given settings. This is protected so that - * it is easy to make a subclass, but otherwise, the static factory methods should be preferred. - */ - protected CloudBuildClient(CloudBuildSettings settings) throws IOException { - this.settings = settings; - this.stub = ((CloudBuildStubSettings) settings.getStubSettings()).createStub(); - this.operationsClient = - com.google.longrunning.OperationsClient.create(this.stub.getOperationsStub()); - this.httpJsonOperationsClient = OperationsClient.create(this.stub.getHttpJsonOperationsStub()); - } - - protected CloudBuildClient(CloudBuildStub stub) { - this.settings = null; - this.stub = stub; - this.operationsClient = - com.google.longrunning.OperationsClient.create(this.stub.getOperationsStub()); - this.httpJsonOperationsClient = OperationsClient.create(this.stub.getHttpJsonOperationsStub()); - } - - public final CloudBuildSettings getSettings() { - return settings; - } - - public CloudBuildStub getStub() { - return stub; - } - - /** - * Returns the OperationsClient that can be used to query the status of a long-running operation - * returned by another API method call. - */ - public final com.google.longrunning.OperationsClient getOperationsClient() { - return operationsClient; - } - - /** - * Returns the OperationsClient that can be used to query the status of a long-running operation - * returned by another API method call. - */ - @BetaApi - public final OperationsClient getHttpJsonOperationsClient() { - return httpJsonOperationsClient; - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Starts a build with the specified configuration. - * - *

This method returns a long-running `Operation`, which includes the build ID. Pass the build - * ID to `GetBuild` to determine the build status (such as `SUCCESS` or `FAILURE`). - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   String projectId = "projectId-894832108";
-   *   Build build = Build.newBuilder().build();
-   *   Build response = cloudBuildClient.createBuildAsync(projectId, build).get();
-   * }
-   * }
- * - * @param projectId Required. ID of the project. - * @param build Required. Build resource to create. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final OperationFuture createBuildAsync( - String projectId, Build build) { - CreateBuildRequest request = - CreateBuildRequest.newBuilder().setProjectId(projectId).setBuild(build).build(); - return createBuildAsync(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Starts a build with the specified configuration. - * - *

This method returns a long-running `Operation`, which includes the build ID. Pass the build - * ID to `GetBuild` to determine the build status (such as `SUCCESS` or `FAILURE`). - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   CreateBuildRequest request =
-   *       CreateBuildRequest.newBuilder()
-   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
-   *           .setProjectId("projectId-894832108")
-   *           .setBuild(Build.newBuilder().build())
-   *           .build();
-   *   Build response = cloudBuildClient.createBuildAsync(request).get();
-   * }
-   * }
- * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final OperationFuture createBuildAsync( - CreateBuildRequest request) { - return createBuildOperationCallable().futureCall(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Starts a build with the specified configuration. - * - *

This method returns a long-running `Operation`, which includes the build ID. Pass the build - * ID to `GetBuild` to determine the build status (such as `SUCCESS` or `FAILURE`). - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   CreateBuildRequest request =
-   *       CreateBuildRequest.newBuilder()
-   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
-   *           .setProjectId("projectId-894832108")
-   *           .setBuild(Build.newBuilder().build())
-   *           .build();
-   *   OperationFuture future =
-   *       cloudBuildClient.createBuildOperationCallable().futureCall(request);
-   *   // Do something.
-   *   Build response = future.get();
-   * }
-   * }
- */ - public final OperationCallable - createBuildOperationCallable() { - return stub.createBuildOperationCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Starts a build with the specified configuration. - * - *

This method returns a long-running `Operation`, which includes the build ID. Pass the build - * ID to `GetBuild` to determine the build status (such as `SUCCESS` or `FAILURE`). - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   CreateBuildRequest request =
-   *       CreateBuildRequest.newBuilder()
-   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
-   *           .setProjectId("projectId-894832108")
-   *           .setBuild(Build.newBuilder().build())
-   *           .build();
-   *   ApiFuture future = cloudBuildClient.createBuildCallable().futureCall(request);
-   *   // Do something.
-   *   Operation response = future.get();
-   * }
-   * }
- */ - public final UnaryCallable createBuildCallable() { - return stub.createBuildCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Returns information about a previously requested build. - * - *

The `Build` that is returned includes its status (such as `SUCCESS`, `FAILURE`, or - * `WORKING`), and timing information. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   String projectId = "projectId-894832108";
-   *   String id = "id3355";
-   *   Build response = cloudBuildClient.getBuild(projectId, id);
-   * }
-   * }
- * - * @param projectId Required. ID of the project. - * @param id Required. ID of the build. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final Build getBuild(String projectId, String id) { - GetBuildRequest request = - GetBuildRequest.newBuilder().setProjectId(projectId).setId(id).build(); - return getBuild(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Returns information about a previously requested build. - * - *

The `Build` that is returned includes its status (such as `SUCCESS`, `FAILURE`, or - * `WORKING`), and timing information. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   GetBuildRequest request =
-   *       GetBuildRequest.newBuilder()
-   *           .setName(BuildName.ofProjectBuildName("[PROJECT]", "[BUILD]").toString())
-   *           .setProjectId("projectId-894832108")
-   *           .setId("id3355")
-   *           .build();
-   *   Build response = cloudBuildClient.getBuild(request);
-   * }
-   * }
- * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final Build getBuild(GetBuildRequest request) { - return getBuildCallable().call(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Returns information about a previously requested build. - * - *

The `Build` that is returned includes its status (such as `SUCCESS`, `FAILURE`, or - * `WORKING`), and timing information. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   GetBuildRequest request =
-   *       GetBuildRequest.newBuilder()
-   *           .setName(BuildName.ofProjectBuildName("[PROJECT]", "[BUILD]").toString())
-   *           .setProjectId("projectId-894832108")
-   *           .setId("id3355")
-   *           .build();
-   *   ApiFuture future = cloudBuildClient.getBuildCallable().futureCall(request);
-   *   // Do something.
-   *   Build response = future.get();
-   * }
-   * }
- */ - public final UnaryCallable getBuildCallable() { - return stub.getBuildCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Lists previously requested builds. - * - *

Previously requested builds may still be in-progress, or may have finished successfully or - * unsuccessfully. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   String projectId = "projectId-894832108";
-   *   String filter = "filter-1274492040";
-   *   for (Build element : cloudBuildClient.listBuilds(projectId, filter).iterateAll()) {
-   *     // doThingsWith(element);
-   *   }
-   * }
-   * }
- * - * @param projectId Required. ID of the project. - * @param filter The raw filter text to constrain the results. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final ListBuildsPagedResponse listBuilds(String projectId, String filter) { - ListBuildsRequest request = - ListBuildsRequest.newBuilder().setProjectId(projectId).setFilter(filter).build(); - return listBuilds(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Lists previously requested builds. - * - *

Previously requested builds may still be in-progress, or may have finished successfully or - * unsuccessfully. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   ListBuildsRequest request =
-   *       ListBuildsRequest.newBuilder()
-   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
-   *           .setProjectId("projectId-894832108")
-   *           .setPageSize(883849137)
-   *           .setPageToken("pageToken873572522")
-   *           .setFilter("filter-1274492040")
-   *           .build();
-   *   for (Build element : cloudBuildClient.listBuilds(request).iterateAll()) {
-   *     // doThingsWith(element);
-   *   }
-   * }
-   * }
- * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final ListBuildsPagedResponse listBuilds(ListBuildsRequest request) { - return listBuildsPagedCallable().call(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Lists previously requested builds. - * - *

Previously requested builds may still be in-progress, or may have finished successfully or - * unsuccessfully. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   ListBuildsRequest request =
-   *       ListBuildsRequest.newBuilder()
-   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
-   *           .setProjectId("projectId-894832108")
-   *           .setPageSize(883849137)
-   *           .setPageToken("pageToken873572522")
-   *           .setFilter("filter-1274492040")
-   *           .build();
-   *   ApiFuture future = cloudBuildClient.listBuildsPagedCallable().futureCall(request);
-   *   // Do something.
-   *   for (Build element : future.get().iterateAll()) {
-   *     // doThingsWith(element);
-   *   }
-   * }
-   * }
- */ - public final UnaryCallable listBuildsPagedCallable() { - return stub.listBuildsPagedCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Lists previously requested builds. - * - *

Previously requested builds may still be in-progress, or may have finished successfully or - * unsuccessfully. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   ListBuildsRequest request =
-   *       ListBuildsRequest.newBuilder()
-   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
-   *           .setProjectId("projectId-894832108")
-   *           .setPageSize(883849137)
-   *           .setPageToken("pageToken873572522")
-   *           .setFilter("filter-1274492040")
-   *           .build();
-   *   while (true) {
-   *     ListBuildsResponse response = cloudBuildClient.listBuildsCallable().call(request);
-   *     for (Build element : response.getBuildsList()) {
-   *       // doThingsWith(element);
-   *     }
-   *     String nextPageToken = response.getNextPageToken();
-   *     if (!Strings.isNullOrEmpty(nextPageToken)) {
-   *       request = request.toBuilder().setPageToken(nextPageToken).build();
-   *     } else {
-   *       break;
-   *     }
-   *   }
-   * }
-   * }
- */ - public final UnaryCallable listBuildsCallable() { - return stub.listBuildsCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Cancels a build in progress. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   String projectId = "projectId-894832108";
-   *   String id = "id3355";
-   *   Build response = cloudBuildClient.cancelBuild(projectId, id);
-   * }
-   * }
- * - * @param projectId Required. ID of the project. - * @param id Required. ID of the build. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final Build cancelBuild(String projectId, String id) { - CancelBuildRequest request = - CancelBuildRequest.newBuilder().setProjectId(projectId).setId(id).build(); - return cancelBuild(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Cancels a build in progress. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   CancelBuildRequest request =
-   *       CancelBuildRequest.newBuilder()
-   *           .setName(BuildName.ofProjectBuildName("[PROJECT]", "[BUILD]").toString())
-   *           .setProjectId("projectId-894832108")
-   *           .setId("id3355")
-   *           .build();
-   *   Build response = cloudBuildClient.cancelBuild(request);
-   * }
-   * }
- * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final Build cancelBuild(CancelBuildRequest request) { - return cancelBuildCallable().call(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Cancels a build in progress. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   CancelBuildRequest request =
-   *       CancelBuildRequest.newBuilder()
-   *           .setName(BuildName.ofProjectBuildName("[PROJECT]", "[BUILD]").toString())
-   *           .setProjectId("projectId-894832108")
-   *           .setId("id3355")
-   *           .build();
-   *   ApiFuture future = cloudBuildClient.cancelBuildCallable().futureCall(request);
-   *   // Do something.
-   *   Build response = future.get();
-   * }
-   * }
- */ - public final UnaryCallable cancelBuildCallable() { - return stub.cancelBuildCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Creates a new build based on the specified build. - * - *

This method creates a new build using the original build request, which may or may not - * result in an identical build. - * - *

For triggered builds: - * - *

    - *
  • Triggered builds resolve to a precise revision; therefore a retry of a triggered build - * will result in a build that uses the same revision. - *
- * - *

For non-triggered builds that specify `RepoSource`: - * - *

    - *
  • If the original build built from the tip of a branch, the retried build will build from - * the tip of that branch, which may not be the same revision as the original build. - *
  • If the original build specified a commit sha or revision ID, the retried build will use - * the identical source. - *
- * - *

For builds that specify `StorageSource`: - * - *

    - *
  • If the original build pulled source from Google Cloud Storage without specifying the - * generation of the object, the new build will use the current object, which may be - * different from the original build source. - *
  • If the original build pulled source from Cloud Storage and specified the generation of - * the object, the new build will attempt to use the same object, which may or may not be - * available depending on the bucket's lifecycle management settings. - *
- * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   String projectId = "projectId-894832108";
-   *   String id = "id3355";
-   *   Build response = cloudBuildClient.retryBuildAsync(projectId, id).get();
-   * }
-   * }
- * - * @param projectId Required. ID of the project. - * @param id Required. Build ID of the original build. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final OperationFuture retryBuildAsync( - String projectId, String id) { - RetryBuildRequest request = - RetryBuildRequest.newBuilder().setProjectId(projectId).setId(id).build(); - return retryBuildAsync(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Creates a new build based on the specified build. - * - *

This method creates a new build using the original build request, which may or may not - * result in an identical build. - * - *

For triggered builds: - * - *

    - *
  • Triggered builds resolve to a precise revision; therefore a retry of a triggered build - * will result in a build that uses the same revision. - *
- * - *

For non-triggered builds that specify `RepoSource`: - * - *

    - *
  • If the original build built from the tip of a branch, the retried build will build from - * the tip of that branch, which may not be the same revision as the original build. - *
  • If the original build specified a commit sha or revision ID, the retried build will use - * the identical source. - *
- * - *

For builds that specify `StorageSource`: - * - *

    - *
  • If the original build pulled source from Google Cloud Storage without specifying the - * generation of the object, the new build will use the current object, which may be - * different from the original build source. - *
  • If the original build pulled source from Cloud Storage and specified the generation of - * the object, the new build will attempt to use the same object, which may or may not be - * available depending on the bucket's lifecycle management settings. - *
- * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   RetryBuildRequest request =
-   *       RetryBuildRequest.newBuilder()
-   *           .setName(BuildName.ofProjectBuildName("[PROJECT]", "[BUILD]").toString())
-   *           .setProjectId("projectId-894832108")
-   *           .setId("id3355")
-   *           .build();
-   *   Build response = cloudBuildClient.retryBuildAsync(request).get();
-   * }
-   * }
- * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final OperationFuture retryBuildAsync( - RetryBuildRequest request) { - return retryBuildOperationCallable().futureCall(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Creates a new build based on the specified build. - * - *

This method creates a new build using the original build request, which may or may not - * result in an identical build. - * - *

For triggered builds: - * - *

    - *
  • Triggered builds resolve to a precise revision; therefore a retry of a triggered build - * will result in a build that uses the same revision. - *
- * - *

For non-triggered builds that specify `RepoSource`: - * - *

    - *
  • If the original build built from the tip of a branch, the retried build will build from - * the tip of that branch, which may not be the same revision as the original build. - *
  • If the original build specified a commit sha or revision ID, the retried build will use - * the identical source. - *
- * - *

For builds that specify `StorageSource`: - * - *

    - *
  • If the original build pulled source from Google Cloud Storage without specifying the - * generation of the object, the new build will use the current object, which may be - * different from the original build source. - *
  • If the original build pulled source from Cloud Storage and specified the generation of - * the object, the new build will attempt to use the same object, which may or may not be - * available depending on the bucket's lifecycle management settings. - *
- * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   RetryBuildRequest request =
-   *       RetryBuildRequest.newBuilder()
-   *           .setName(BuildName.ofProjectBuildName("[PROJECT]", "[BUILD]").toString())
-   *           .setProjectId("projectId-894832108")
-   *           .setId("id3355")
-   *           .build();
-   *   OperationFuture future =
-   *       cloudBuildClient.retryBuildOperationCallable().futureCall(request);
-   *   // Do something.
-   *   Build response = future.get();
-   * }
-   * }
- */ - public final OperationCallable - retryBuildOperationCallable() { - return stub.retryBuildOperationCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Creates a new build based on the specified build. - * - *

This method creates a new build using the original build request, which may or may not - * result in an identical build. - * - *

For triggered builds: - * - *

    - *
  • Triggered builds resolve to a precise revision; therefore a retry of a triggered build - * will result in a build that uses the same revision. - *
- * - *

For non-triggered builds that specify `RepoSource`: - * - *

    - *
  • If the original build built from the tip of a branch, the retried build will build from - * the tip of that branch, which may not be the same revision as the original build. - *
  • If the original build specified a commit sha or revision ID, the retried build will use - * the identical source. - *
- * - *

For builds that specify `StorageSource`: - * - *

    - *
  • If the original build pulled source from Google Cloud Storage without specifying the - * generation of the object, the new build will use the current object, which may be - * different from the original build source. - *
  • If the original build pulled source from Cloud Storage and specified the generation of - * the object, the new build will attempt to use the same object, which may or may not be - * available depending on the bucket's lifecycle management settings. - *
- * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   RetryBuildRequest request =
-   *       RetryBuildRequest.newBuilder()
-   *           .setName(BuildName.ofProjectBuildName("[PROJECT]", "[BUILD]").toString())
-   *           .setProjectId("projectId-894832108")
-   *           .setId("id3355")
-   *           .build();
-   *   ApiFuture future = cloudBuildClient.retryBuildCallable().futureCall(request);
-   *   // Do something.
-   *   Operation response = future.get();
-   * }
-   * }
- */ - public final UnaryCallable retryBuildCallable() { - return stub.retryBuildCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Approves or rejects a pending build. - * - *

If approved, the returned LRO will be analogous to the LRO returned from a CreateBuild call. - * - *

If rejected, the returned LRO will be immediately done. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   String name = "name3373707";
-   *   ApprovalResult approvalResult = ApprovalResult.newBuilder().build();
-   *   Build response = cloudBuildClient.approveBuildAsync(name, approvalResult).get();
-   * }
-   * }
- * - * @param name Required. Name of the target build. For example: - * "projects/{$project_id}/builds/{$build_id}" - * @param approvalResult Approval decision and metadata. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final OperationFuture approveBuildAsync( - String name, ApprovalResult approvalResult) { - ApproveBuildRequest request = - ApproveBuildRequest.newBuilder().setName(name).setApprovalResult(approvalResult).build(); - return approveBuildAsync(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Approves or rejects a pending build. - * - *

If approved, the returned LRO will be analogous to the LRO returned from a CreateBuild call. - * - *

If rejected, the returned LRO will be immediately done. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   ApproveBuildRequest request =
-   *       ApproveBuildRequest.newBuilder()
-   *           .setName("name3373707")
-   *           .setApprovalResult(ApprovalResult.newBuilder().build())
-   *           .build();
-   *   Build response = cloudBuildClient.approveBuildAsync(request).get();
-   * }
-   * }
- * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final OperationFuture approveBuildAsync( - ApproveBuildRequest request) { - return approveBuildOperationCallable().futureCall(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Approves or rejects a pending build. - * - *

If approved, the returned LRO will be analogous to the LRO returned from a CreateBuild call. - * - *

If rejected, the returned LRO will be immediately done. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   ApproveBuildRequest request =
-   *       ApproveBuildRequest.newBuilder()
-   *           .setName("name3373707")
-   *           .setApprovalResult(ApprovalResult.newBuilder().build())
-   *           .build();
-   *   OperationFuture future =
-   *       cloudBuildClient.approveBuildOperationCallable().futureCall(request);
-   *   // Do something.
-   *   Build response = future.get();
-   * }
-   * }
- */ - public final OperationCallable - approveBuildOperationCallable() { - return stub.approveBuildOperationCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Approves or rejects a pending build. - * - *

If approved, the returned LRO will be analogous to the LRO returned from a CreateBuild call. - * - *

If rejected, the returned LRO will be immediately done. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   ApproveBuildRequest request =
-   *       ApproveBuildRequest.newBuilder()
-   *           .setName("name3373707")
-   *           .setApprovalResult(ApprovalResult.newBuilder().build())
-   *           .build();
-   *   ApiFuture future = cloudBuildClient.approveBuildCallable().futureCall(request);
-   *   // Do something.
-   *   Operation response = future.get();
-   * }
-   * }
- */ - public final UnaryCallable approveBuildCallable() { - return stub.approveBuildCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Creates a new `BuildTrigger`. - * - *

This API is experimental. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   String projectId = "projectId-894832108";
-   *   BuildTrigger trigger = BuildTrigger.newBuilder().build();
-   *   BuildTrigger response = cloudBuildClient.createBuildTrigger(projectId, trigger);
-   * }
-   * }
- * - * @param projectId Required. ID of the project for which to configure automatic builds. - * @param trigger Required. `BuildTrigger` to create. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final BuildTrigger createBuildTrigger(String projectId, BuildTrigger trigger) { - CreateBuildTriggerRequest request = - CreateBuildTriggerRequest.newBuilder().setProjectId(projectId).setTrigger(trigger).build(); - return createBuildTrigger(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Creates a new `BuildTrigger`. - * - *

This API is experimental. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   CreateBuildTriggerRequest request =
-   *       CreateBuildTriggerRequest.newBuilder()
-   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
-   *           .setProjectId("projectId-894832108")
-   *           .setTrigger(BuildTrigger.newBuilder().build())
-   *           .build();
-   *   BuildTrigger response = cloudBuildClient.createBuildTrigger(request);
-   * }
-   * }
- * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final BuildTrigger createBuildTrigger(CreateBuildTriggerRequest request) { - return createBuildTriggerCallable().call(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Creates a new `BuildTrigger`. - * - *

This API is experimental. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   CreateBuildTriggerRequest request =
-   *       CreateBuildTriggerRequest.newBuilder()
-   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
-   *           .setProjectId("projectId-894832108")
-   *           .setTrigger(BuildTrigger.newBuilder().build())
-   *           .build();
-   *   ApiFuture future =
-   *       cloudBuildClient.createBuildTriggerCallable().futureCall(request);
-   *   // Do something.
-   *   BuildTrigger response = future.get();
-   * }
-   * }
- */ - public final UnaryCallable createBuildTriggerCallable() { - return stub.createBuildTriggerCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Returns information about a `BuildTrigger`. - * - *

This API is experimental. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   String projectId = "projectId-894832108";
-   *   String triggerId = "triggerId-648752909";
-   *   BuildTrigger response = cloudBuildClient.getBuildTrigger(projectId, triggerId);
-   * }
-   * }
- * - * @param projectId Required. ID of the project that owns the trigger. - * @param triggerId Required. Identifier (`id` or `name`) of the `BuildTrigger` to get. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final BuildTrigger getBuildTrigger(String projectId, String triggerId) { - GetBuildTriggerRequest request = - GetBuildTriggerRequest.newBuilder().setProjectId(projectId).setTriggerId(triggerId).build(); - return getBuildTrigger(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Returns information about a `BuildTrigger`. - * - *

This API is experimental. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   GetBuildTriggerRequest request =
-   *       GetBuildTriggerRequest.newBuilder()
-   *           .setName(BuildTriggerName.ofProjectTriggerName("[PROJECT]", "[TRIGGER]").toString())
-   *           .setProjectId("projectId-894832108")
-   *           .setTriggerId("triggerId-648752909")
-   *           .build();
-   *   BuildTrigger response = cloudBuildClient.getBuildTrigger(request);
-   * }
-   * }
- * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final BuildTrigger getBuildTrigger(GetBuildTriggerRequest request) { - return getBuildTriggerCallable().call(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Returns information about a `BuildTrigger`. - * - *

This API is experimental. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   GetBuildTriggerRequest request =
-   *       GetBuildTriggerRequest.newBuilder()
-   *           .setName(BuildTriggerName.ofProjectTriggerName("[PROJECT]", "[TRIGGER]").toString())
-   *           .setProjectId("projectId-894832108")
-   *           .setTriggerId("triggerId-648752909")
-   *           .build();
-   *   ApiFuture future =
-   *       cloudBuildClient.getBuildTriggerCallable().futureCall(request);
-   *   // Do something.
-   *   BuildTrigger response = future.get();
-   * }
-   * }
- */ - public final UnaryCallable getBuildTriggerCallable() { - return stub.getBuildTriggerCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Lists existing `BuildTrigger`s. - * - *

This API is experimental. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   String projectId = "projectId-894832108";
-   *   for (BuildTrigger element : cloudBuildClient.listBuildTriggers(projectId).iterateAll()) {
-   *     // doThingsWith(element);
-   *   }
-   * }
-   * }
- * - * @param projectId Required. ID of the project for which to list BuildTriggers. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final ListBuildTriggersPagedResponse listBuildTriggers(String projectId) { - ListBuildTriggersRequest request = - ListBuildTriggersRequest.newBuilder().setProjectId(projectId).build(); - return listBuildTriggers(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Lists existing `BuildTrigger`s. - * - *

This API is experimental. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   ListBuildTriggersRequest request =
-   *       ListBuildTriggersRequest.newBuilder()
-   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
-   *           .setProjectId("projectId-894832108")
-   *           .setPageSize(883849137)
-   *           .setPageToken("pageToken873572522")
-   *           .build();
-   *   for (BuildTrigger element : cloudBuildClient.listBuildTriggers(request).iterateAll()) {
-   *     // doThingsWith(element);
-   *   }
-   * }
-   * }
- * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final ListBuildTriggersPagedResponse listBuildTriggers(ListBuildTriggersRequest request) { - return listBuildTriggersPagedCallable().call(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Lists existing `BuildTrigger`s. - * - *

This API is experimental. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   ListBuildTriggersRequest request =
-   *       ListBuildTriggersRequest.newBuilder()
-   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
-   *           .setProjectId("projectId-894832108")
-   *           .setPageSize(883849137)
-   *           .setPageToken("pageToken873572522")
-   *           .build();
-   *   ApiFuture future =
-   *       cloudBuildClient.listBuildTriggersPagedCallable().futureCall(request);
-   *   // Do something.
-   *   for (BuildTrigger element : future.get().iterateAll()) {
-   *     // doThingsWith(element);
-   *   }
-   * }
-   * }
- */ - public final UnaryCallable - listBuildTriggersPagedCallable() { - return stub.listBuildTriggersPagedCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Lists existing `BuildTrigger`s. - * - *

This API is experimental. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   ListBuildTriggersRequest request =
-   *       ListBuildTriggersRequest.newBuilder()
-   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
-   *           .setProjectId("projectId-894832108")
-   *           .setPageSize(883849137)
-   *           .setPageToken("pageToken873572522")
-   *           .build();
-   *   while (true) {
-   *     ListBuildTriggersResponse response =
-   *         cloudBuildClient.listBuildTriggersCallable().call(request);
-   *     for (BuildTrigger element : response.getTriggersList()) {
-   *       // doThingsWith(element);
-   *     }
-   *     String nextPageToken = response.getNextPageToken();
-   *     if (!Strings.isNullOrEmpty(nextPageToken)) {
-   *       request = request.toBuilder().setPageToken(nextPageToken).build();
-   *     } else {
-   *       break;
-   *     }
-   *   }
-   * }
-   * }
- */ - public final UnaryCallable - listBuildTriggersCallable() { - return stub.listBuildTriggersCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Deletes a `BuildTrigger` by its project ID and trigger ID. - * - *

This API is experimental. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   String projectId = "projectId-894832108";
-   *   String triggerId = "triggerId-648752909";
-   *   cloudBuildClient.deleteBuildTrigger(projectId, triggerId);
-   * }
-   * }
- * - * @param projectId Required. ID of the project that owns the trigger. - * @param triggerId Required. ID of the `BuildTrigger` to delete. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final void deleteBuildTrigger(String projectId, String triggerId) { - DeleteBuildTriggerRequest request = - DeleteBuildTriggerRequest.newBuilder() - .setProjectId(projectId) - .setTriggerId(triggerId) - .build(); - deleteBuildTrigger(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Deletes a `BuildTrigger` by its project ID and trigger ID. - * - *

This API is experimental. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   DeleteBuildTriggerRequest request =
-   *       DeleteBuildTriggerRequest.newBuilder()
-   *           .setName(BuildTriggerName.ofProjectTriggerName("[PROJECT]", "[TRIGGER]").toString())
-   *           .setProjectId("projectId-894832108")
-   *           .setTriggerId("triggerId-648752909")
-   *           .build();
-   *   cloudBuildClient.deleteBuildTrigger(request);
-   * }
-   * }
- * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final void deleteBuildTrigger(DeleteBuildTriggerRequest request) { - deleteBuildTriggerCallable().call(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Deletes a `BuildTrigger` by its project ID and trigger ID. - * - *

This API is experimental. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   DeleteBuildTriggerRequest request =
-   *       DeleteBuildTriggerRequest.newBuilder()
-   *           .setName(BuildTriggerName.ofProjectTriggerName("[PROJECT]", "[TRIGGER]").toString())
-   *           .setProjectId("projectId-894832108")
-   *           .setTriggerId("triggerId-648752909")
-   *           .build();
-   *   ApiFuture future = cloudBuildClient.deleteBuildTriggerCallable().futureCall(request);
-   *   // Do something.
-   *   future.get();
-   * }
-   * }
- */ - public final UnaryCallable deleteBuildTriggerCallable() { - return stub.deleteBuildTriggerCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Updates a `BuildTrigger` by its project ID and trigger ID. - * - *

This API is experimental. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   String projectId = "projectId-894832108";
-   *   String triggerId = "triggerId-648752909";
-   *   BuildTrigger trigger = BuildTrigger.newBuilder().build();
-   *   BuildTrigger response = cloudBuildClient.updateBuildTrigger(projectId, triggerId, trigger);
-   * }
-   * }
- * - * @param projectId Required. ID of the project that owns the trigger. - * @param triggerId Required. ID of the `BuildTrigger` to update. - * @param trigger Required. `BuildTrigger` to update. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final BuildTrigger updateBuildTrigger( - String projectId, String triggerId, BuildTrigger trigger) { - UpdateBuildTriggerRequest request = - UpdateBuildTriggerRequest.newBuilder() - .setProjectId(projectId) - .setTriggerId(triggerId) - .setTrigger(trigger) - .build(); - return updateBuildTrigger(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Updates a `BuildTrigger` by its project ID and trigger ID. - * - *

This API is experimental. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   UpdateBuildTriggerRequest request =
-   *       UpdateBuildTriggerRequest.newBuilder()
-   *           .setProjectId("projectId-894832108")
-   *           .setTriggerId("triggerId-648752909")
-   *           .setTrigger(BuildTrigger.newBuilder().build())
-   *           .build();
-   *   BuildTrigger response = cloudBuildClient.updateBuildTrigger(request);
-   * }
-   * }
- * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final BuildTrigger updateBuildTrigger(UpdateBuildTriggerRequest request) { - return updateBuildTriggerCallable().call(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Updates a `BuildTrigger` by its project ID and trigger ID. - * - *

This API is experimental. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   UpdateBuildTriggerRequest request =
-   *       UpdateBuildTriggerRequest.newBuilder()
-   *           .setProjectId("projectId-894832108")
-   *           .setTriggerId("triggerId-648752909")
-   *           .setTrigger(BuildTrigger.newBuilder().build())
-   *           .build();
-   *   ApiFuture future =
-   *       cloudBuildClient.updateBuildTriggerCallable().futureCall(request);
-   *   // Do something.
-   *   BuildTrigger response = future.get();
-   * }
-   * }
- */ - public final UnaryCallable updateBuildTriggerCallable() { - return stub.updateBuildTriggerCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Runs a `BuildTrigger` at a particular source revision. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   String projectId = "projectId-894832108";
-   *   String triggerId = "triggerId-648752909";
-   *   RepoSource source = RepoSource.newBuilder().build();
-   *   Build response = cloudBuildClient.runBuildTriggerAsync(projectId, triggerId, source).get();
-   * }
-   * }
- * - * @param projectId Required. ID of the project. - * @param triggerId Required. ID of the trigger. - * @param source Source to build against this trigger. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final OperationFuture runBuildTriggerAsync( - String projectId, String triggerId, RepoSource source) { - RunBuildTriggerRequest request = - RunBuildTriggerRequest.newBuilder() - .setProjectId(projectId) - .setTriggerId(triggerId) - .setSource(source) - .build(); - return runBuildTriggerAsync(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Runs a `BuildTrigger` at a particular source revision. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   RunBuildTriggerRequest request =
-   *       RunBuildTriggerRequest.newBuilder()
-   *           .setName(BuildTriggerName.ofProjectTriggerName("[PROJECT]", "[TRIGGER]").toString())
-   *           .setProjectId("projectId-894832108")
-   *           .setTriggerId("triggerId-648752909")
-   *           .setSource(RepoSource.newBuilder().build())
-   *           .build();
-   *   Build response = cloudBuildClient.runBuildTriggerAsync(request).get();
-   * }
-   * }
- * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final OperationFuture runBuildTriggerAsync( - RunBuildTriggerRequest request) { - return runBuildTriggerOperationCallable().futureCall(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Runs a `BuildTrigger` at a particular source revision. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   RunBuildTriggerRequest request =
-   *       RunBuildTriggerRequest.newBuilder()
-   *           .setName(BuildTriggerName.ofProjectTriggerName("[PROJECT]", "[TRIGGER]").toString())
-   *           .setProjectId("projectId-894832108")
-   *           .setTriggerId("triggerId-648752909")
-   *           .setSource(RepoSource.newBuilder().build())
-   *           .build();
-   *   OperationFuture future =
-   *       cloudBuildClient.runBuildTriggerOperationCallable().futureCall(request);
-   *   // Do something.
-   *   Build response = future.get();
-   * }
-   * }
- */ - public final OperationCallable - runBuildTriggerOperationCallable() { - return stub.runBuildTriggerOperationCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Runs a `BuildTrigger` at a particular source revision. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   RunBuildTriggerRequest request =
-   *       RunBuildTriggerRequest.newBuilder()
-   *           .setName(BuildTriggerName.ofProjectTriggerName("[PROJECT]", "[TRIGGER]").toString())
-   *           .setProjectId("projectId-894832108")
-   *           .setTriggerId("triggerId-648752909")
-   *           .setSource(RepoSource.newBuilder().build())
-   *           .build();
-   *   ApiFuture future = cloudBuildClient.runBuildTriggerCallable().futureCall(request);
-   *   // Do something.
-   *   Operation response = future.get();
-   * }
-   * }
- */ - public final UnaryCallable runBuildTriggerCallable() { - return stub.runBuildTriggerCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * ReceiveTriggerWebhook [Experimental] is called when the API receives a webhook request targeted - * at a specific trigger. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   ReceiveTriggerWebhookRequest request =
-   *       ReceiveTriggerWebhookRequest.newBuilder()
-   *           .setName("name3373707")
-   *           .setBody(HttpBody.newBuilder().build())
-   *           .setProjectId("projectId-894832108")
-   *           .setTrigger("trigger-1059891784")
-   *           .setSecret("secret-906277200")
-   *           .build();
-   *   ReceiveTriggerWebhookResponse response = cloudBuildClient.receiveTriggerWebhook(request);
-   * }
-   * }
- * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final ReceiveTriggerWebhookResponse receiveTriggerWebhook( - ReceiveTriggerWebhookRequest request) { - return receiveTriggerWebhookCallable().call(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * ReceiveTriggerWebhook [Experimental] is called when the API receives a webhook request targeted - * at a specific trigger. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   ReceiveTriggerWebhookRequest request =
-   *       ReceiveTriggerWebhookRequest.newBuilder()
-   *           .setName("name3373707")
-   *           .setBody(HttpBody.newBuilder().build())
-   *           .setProjectId("projectId-894832108")
-   *           .setTrigger("trigger-1059891784")
-   *           .setSecret("secret-906277200")
-   *           .build();
-   *   ApiFuture future =
-   *       cloudBuildClient.receiveTriggerWebhookCallable().futureCall(request);
-   *   // Do something.
-   *   ReceiveTriggerWebhookResponse response = future.get();
-   * }
-   * }
- */ - public final UnaryCallable - receiveTriggerWebhookCallable() { - return stub.receiveTriggerWebhookCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Creates a `WorkerPool`. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
-   *   WorkerPool workerPool = WorkerPool.newBuilder().build();
-   *   String workerPoolId = "workerPoolId-46320779";
-   *   WorkerPool response =
-   *       cloudBuildClient.createWorkerPoolAsync(parent, workerPool, workerPoolId).get();
-   * }
-   * }
- * - * @param parent Required. The parent resource where this worker pool will be created. Format: - * `projects/{project}/locations/{location}`. - * @param workerPool Required. `WorkerPool` resource to create. - * @param workerPoolId Required. Immutable. The ID to use for the `WorkerPool`, which will become - * the final component of the resource name. - *

This value should be 1-63 characters, and valid characters are /[a-z][0-9]-/. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final OperationFuture createWorkerPoolAsync( - LocationName parent, WorkerPool workerPool, String workerPoolId) { - CreateWorkerPoolRequest request = - CreateWorkerPoolRequest.newBuilder() - .setParent(parent == null ? null : parent.toString()) - .setWorkerPool(workerPool) - .setWorkerPoolId(workerPoolId) - .build(); - return createWorkerPoolAsync(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Creates a `WorkerPool`. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
-   *   WorkerPool workerPool = WorkerPool.newBuilder().build();
-   *   String workerPoolId = "workerPoolId-46320779";
-   *   WorkerPool response =
-   *       cloudBuildClient.createWorkerPoolAsync(parent, workerPool, workerPoolId).get();
-   * }
-   * }
- * - * @param parent Required. The parent resource where this worker pool will be created. Format: - * `projects/{project}/locations/{location}`. - * @param workerPool Required. `WorkerPool` resource to create. - * @param workerPoolId Required. Immutable. The ID to use for the `WorkerPool`, which will become - * the final component of the resource name. - *

This value should be 1-63 characters, and valid characters are /[a-z][0-9]-/. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final OperationFuture createWorkerPoolAsync( - String parent, WorkerPool workerPool, String workerPoolId) { - CreateWorkerPoolRequest request = - CreateWorkerPoolRequest.newBuilder() - .setParent(parent) - .setWorkerPool(workerPool) - .setWorkerPoolId(workerPoolId) - .build(); - return createWorkerPoolAsync(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Creates a `WorkerPool`. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   CreateWorkerPoolRequest request =
-   *       CreateWorkerPoolRequest.newBuilder()
-   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
-   *           .setWorkerPool(WorkerPool.newBuilder().build())
-   *           .setWorkerPoolId("workerPoolId-46320779")
-   *           .setValidateOnly(true)
-   *           .build();
-   *   WorkerPool response = cloudBuildClient.createWorkerPoolAsync(request).get();
-   * }
-   * }
- * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final OperationFuture createWorkerPoolAsync( - CreateWorkerPoolRequest request) { - return createWorkerPoolOperationCallable().futureCall(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Creates a `WorkerPool`. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   CreateWorkerPoolRequest request =
-   *       CreateWorkerPoolRequest.newBuilder()
-   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
-   *           .setWorkerPool(WorkerPool.newBuilder().build())
-   *           .setWorkerPoolId("workerPoolId-46320779")
-   *           .setValidateOnly(true)
-   *           .build();
-   *   OperationFuture future =
-   *       cloudBuildClient.createWorkerPoolOperationCallable().futureCall(request);
-   *   // Do something.
-   *   WorkerPool response = future.get();
-   * }
-   * }
- */ - public final OperationCallable< - CreateWorkerPoolRequest, WorkerPool, CreateWorkerPoolOperationMetadata> - createWorkerPoolOperationCallable() { - return stub.createWorkerPoolOperationCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Creates a `WorkerPool`. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   CreateWorkerPoolRequest request =
-   *       CreateWorkerPoolRequest.newBuilder()
-   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
-   *           .setWorkerPool(WorkerPool.newBuilder().build())
-   *           .setWorkerPoolId("workerPoolId-46320779")
-   *           .setValidateOnly(true)
-   *           .build();
-   *   ApiFuture future = cloudBuildClient.createWorkerPoolCallable().futureCall(request);
-   *   // Do something.
-   *   Operation response = future.get();
-   * }
-   * }
- */ - public final UnaryCallable createWorkerPoolCallable() { - return stub.createWorkerPoolCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Returns details of a `WorkerPool`. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   WorkerPoolName name = WorkerPoolName.of("[PROJECT]", "[LOCATION]", "[WORKER_POOL]");
-   *   WorkerPool response = cloudBuildClient.getWorkerPool(name);
-   * }
-   * }
- * - * @param name Required. The name of the `WorkerPool` to retrieve. Format: - * `projects/{project}/locations/{location}/workerPools/{workerPool}`. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final WorkerPool getWorkerPool(WorkerPoolName name) { - GetWorkerPoolRequest request = - GetWorkerPoolRequest.newBuilder().setName(name == null ? null : name.toString()).build(); - return getWorkerPool(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Returns details of a `WorkerPool`. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   String name = WorkerPoolName.of("[PROJECT]", "[LOCATION]", "[WORKER_POOL]").toString();
-   *   WorkerPool response = cloudBuildClient.getWorkerPool(name);
-   * }
-   * }
- * - * @param name Required. The name of the `WorkerPool` to retrieve. Format: - * `projects/{project}/locations/{location}/workerPools/{workerPool}`. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final WorkerPool getWorkerPool(String name) { - GetWorkerPoolRequest request = GetWorkerPoolRequest.newBuilder().setName(name).build(); - return getWorkerPool(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Returns details of a `WorkerPool`. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   GetWorkerPoolRequest request =
-   *       GetWorkerPoolRequest.newBuilder()
-   *           .setName(WorkerPoolName.of("[PROJECT]", "[LOCATION]", "[WORKER_POOL]").toString())
-   *           .build();
-   *   WorkerPool response = cloudBuildClient.getWorkerPool(request);
-   * }
-   * }
- * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final WorkerPool getWorkerPool(GetWorkerPoolRequest request) { - return getWorkerPoolCallable().call(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Returns details of a `WorkerPool`. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   GetWorkerPoolRequest request =
-   *       GetWorkerPoolRequest.newBuilder()
-   *           .setName(WorkerPoolName.of("[PROJECT]", "[LOCATION]", "[WORKER_POOL]").toString())
-   *           .build();
-   *   ApiFuture future = cloudBuildClient.getWorkerPoolCallable().futureCall(request);
-   *   // Do something.
-   *   WorkerPool response = future.get();
-   * }
-   * }
- */ - public final UnaryCallable getWorkerPoolCallable() { - return stub.getWorkerPoolCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Deletes a `WorkerPool`. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   WorkerPoolName name = WorkerPoolName.of("[PROJECT]", "[LOCATION]", "[WORKER_POOL]");
-   *   cloudBuildClient.deleteWorkerPoolAsync(name).get();
-   * }
-   * }
- * - * @param name Required. The name of the `WorkerPool` to delete. Format: - * `projects/{project}/locations/{workerPool}/workerPools/{workerPool}`. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final OperationFuture deleteWorkerPoolAsync( - WorkerPoolName name) { - DeleteWorkerPoolRequest request = - DeleteWorkerPoolRequest.newBuilder().setName(name == null ? null : name.toString()).build(); - return deleteWorkerPoolAsync(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Deletes a `WorkerPool`. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   String name = WorkerPoolName.of("[PROJECT]", "[LOCATION]", "[WORKER_POOL]").toString();
-   *   cloudBuildClient.deleteWorkerPoolAsync(name).get();
-   * }
-   * }
- * - * @param name Required. The name of the `WorkerPool` to delete. Format: - * `projects/{project}/locations/{workerPool}/workerPools/{workerPool}`. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final OperationFuture deleteWorkerPoolAsync( - String name) { - DeleteWorkerPoolRequest request = DeleteWorkerPoolRequest.newBuilder().setName(name).build(); - return deleteWorkerPoolAsync(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Deletes a `WorkerPool`. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   DeleteWorkerPoolRequest request =
-   *       DeleteWorkerPoolRequest.newBuilder()
-   *           .setName(WorkerPoolName.of("[PROJECT]", "[LOCATION]", "[WORKER_POOL]").toString())
-   *           .setEtag("etag3123477")
-   *           .setAllowMissing(true)
-   *           .setValidateOnly(true)
-   *           .build();
-   *   cloudBuildClient.deleteWorkerPoolAsync(request).get();
-   * }
-   * }
- * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final OperationFuture deleteWorkerPoolAsync( - DeleteWorkerPoolRequest request) { - return deleteWorkerPoolOperationCallable().futureCall(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Deletes a `WorkerPool`. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   DeleteWorkerPoolRequest request =
-   *       DeleteWorkerPoolRequest.newBuilder()
-   *           .setName(WorkerPoolName.of("[PROJECT]", "[LOCATION]", "[WORKER_POOL]").toString())
-   *           .setEtag("etag3123477")
-   *           .setAllowMissing(true)
-   *           .setValidateOnly(true)
-   *           .build();
-   *   OperationFuture future =
-   *       cloudBuildClient.deleteWorkerPoolOperationCallable().futureCall(request);
-   *   // Do something.
-   *   future.get();
-   * }
-   * }
- */ - public final OperationCallable - deleteWorkerPoolOperationCallable() { - return stub.deleteWorkerPoolOperationCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Deletes a `WorkerPool`. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   DeleteWorkerPoolRequest request =
-   *       DeleteWorkerPoolRequest.newBuilder()
-   *           .setName(WorkerPoolName.of("[PROJECT]", "[LOCATION]", "[WORKER_POOL]").toString())
-   *           .setEtag("etag3123477")
-   *           .setAllowMissing(true)
-   *           .setValidateOnly(true)
-   *           .build();
-   *   ApiFuture future = cloudBuildClient.deleteWorkerPoolCallable().futureCall(request);
-   *   // Do something.
-   *   future.get();
-   * }
-   * }
- */ - public final UnaryCallable deleteWorkerPoolCallable() { - return stub.deleteWorkerPoolCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Updates a `WorkerPool`. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   WorkerPool workerPool = WorkerPool.newBuilder().build();
-   *   FieldMask updateMask = FieldMask.newBuilder().build();
-   *   WorkerPool response = cloudBuildClient.updateWorkerPoolAsync(workerPool, updateMask).get();
-   * }
-   * }
- * - * @param workerPool Required. The `WorkerPool` to update. - *

The `name` field is used to identify the `WorkerPool` to update. Format: - * `projects/{project}/locations/{location}/workerPools/{workerPool}`. - * @param updateMask A mask specifying which fields in `worker_pool` to update. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final OperationFuture updateWorkerPoolAsync( - WorkerPool workerPool, FieldMask updateMask) { - UpdateWorkerPoolRequest request = - UpdateWorkerPoolRequest.newBuilder() - .setWorkerPool(workerPool) - .setUpdateMask(updateMask) - .build(); - return updateWorkerPoolAsync(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Updates a `WorkerPool`. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   UpdateWorkerPoolRequest request =
-   *       UpdateWorkerPoolRequest.newBuilder()
-   *           .setWorkerPool(WorkerPool.newBuilder().build())
-   *           .setUpdateMask(FieldMask.newBuilder().build())
-   *           .setValidateOnly(true)
-   *           .build();
-   *   WorkerPool response = cloudBuildClient.updateWorkerPoolAsync(request).get();
-   * }
-   * }
- * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final OperationFuture updateWorkerPoolAsync( - UpdateWorkerPoolRequest request) { - return updateWorkerPoolOperationCallable().futureCall(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Updates a `WorkerPool`. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   UpdateWorkerPoolRequest request =
-   *       UpdateWorkerPoolRequest.newBuilder()
-   *           .setWorkerPool(WorkerPool.newBuilder().build())
-   *           .setUpdateMask(FieldMask.newBuilder().build())
-   *           .setValidateOnly(true)
-   *           .build();
-   *   OperationFuture future =
-   *       cloudBuildClient.updateWorkerPoolOperationCallable().futureCall(request);
-   *   // Do something.
-   *   WorkerPool response = future.get();
-   * }
-   * }
- */ - public final OperationCallable< - UpdateWorkerPoolRequest, WorkerPool, UpdateWorkerPoolOperationMetadata> - updateWorkerPoolOperationCallable() { - return stub.updateWorkerPoolOperationCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Updates a `WorkerPool`. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   UpdateWorkerPoolRequest request =
-   *       UpdateWorkerPoolRequest.newBuilder()
-   *           .setWorkerPool(WorkerPool.newBuilder().build())
-   *           .setUpdateMask(FieldMask.newBuilder().build())
-   *           .setValidateOnly(true)
-   *           .build();
-   *   ApiFuture future = cloudBuildClient.updateWorkerPoolCallable().futureCall(request);
-   *   // Do something.
-   *   Operation response = future.get();
-   * }
-   * }
- */ - public final UnaryCallable updateWorkerPoolCallable() { - return stub.updateWorkerPoolCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Lists `WorkerPool`s. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]");
-   *   for (WorkerPool element : cloudBuildClient.listWorkerPools(parent).iterateAll()) {
-   *     // doThingsWith(element);
-   *   }
-   * }
-   * }
- * - * @param parent Required. The parent of the collection of `WorkerPools`. Format: - * `projects/{project}/locations/{location}`. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final ListWorkerPoolsPagedResponse listWorkerPools(LocationName parent) { - ListWorkerPoolsRequest request = - ListWorkerPoolsRequest.newBuilder() - .setParent(parent == null ? null : parent.toString()) - .build(); - return listWorkerPools(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Lists `WorkerPool`s. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   String parent = LocationName.of("[PROJECT]", "[LOCATION]").toString();
-   *   for (WorkerPool element : cloudBuildClient.listWorkerPools(parent).iterateAll()) {
-   *     // doThingsWith(element);
-   *   }
-   * }
-   * }
- * - * @param parent Required. The parent of the collection of `WorkerPools`. Format: - * `projects/{project}/locations/{location}`. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final ListWorkerPoolsPagedResponse listWorkerPools(String parent) { - ListWorkerPoolsRequest request = ListWorkerPoolsRequest.newBuilder().setParent(parent).build(); - return listWorkerPools(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Lists `WorkerPool`s. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   ListWorkerPoolsRequest request =
-   *       ListWorkerPoolsRequest.newBuilder()
-   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
-   *           .setPageSize(883849137)
-   *           .setPageToken("pageToken873572522")
-   *           .build();
-   *   for (WorkerPool element : cloudBuildClient.listWorkerPools(request).iterateAll()) {
-   *     // doThingsWith(element);
-   *   }
-   * }
-   * }
- * - * @param request The request object containing all of the parameters for the API call. - * @throws com.google.api.gax.rpc.ApiException if the remote call fails - */ - public final ListWorkerPoolsPagedResponse listWorkerPools(ListWorkerPoolsRequest request) { - return listWorkerPoolsPagedCallable().call(request); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Lists `WorkerPool`s. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   ListWorkerPoolsRequest request =
-   *       ListWorkerPoolsRequest.newBuilder()
-   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
-   *           .setPageSize(883849137)
-   *           .setPageToken("pageToken873572522")
-   *           .build();
-   *   ApiFuture future =
-   *       cloudBuildClient.listWorkerPoolsPagedCallable().futureCall(request);
-   *   // Do something.
-   *   for (WorkerPool element : future.get().iterateAll()) {
-   *     // doThingsWith(element);
-   *   }
-   * }
-   * }
- */ - public final UnaryCallable - listWorkerPoolsPagedCallable() { - return stub.listWorkerPoolsPagedCallable(); - } - - // AUTO-GENERATED DOCUMENTATION AND METHOD. - /** - * Lists `WorkerPool`s. - * - *

Sample code: - * - *

{@code
-   * // This snippet has been automatically generated and should be regarded as a code template only.
-   * // It will require modifications to work:
-   * // - It may require correct/in-range values for request initialization.
-   * // - It may require specifying regional endpoints when creating the service client as shown in
-   * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
-   * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
-   *   ListWorkerPoolsRequest request =
-   *       ListWorkerPoolsRequest.newBuilder()
-   *           .setParent(LocationName.of("[PROJECT]", "[LOCATION]").toString())
-   *           .setPageSize(883849137)
-   *           .setPageToken("pageToken873572522")
-   *           .build();
-   *   while (true) {
-   *     ListWorkerPoolsResponse response = cloudBuildClient.listWorkerPoolsCallable().call(request);
-   *     for (WorkerPool element : response.getWorkerPoolsList()) {
-   *       // doThingsWith(element);
-   *     }
-   *     String nextPageToken = response.getNextPageToken();
-   *     if (!Strings.isNullOrEmpty(nextPageToken)) {
-   *       request = request.toBuilder().setPageToken(nextPageToken).build();
-   *     } else {
-   *       break;
-   *     }
-   *   }
-   * }
-   * }
- */ - public final UnaryCallable - listWorkerPoolsCallable() { - return stub.listWorkerPoolsCallable(); - } - - @Override - public final void close() { - stub.close(); - } - - @Override - public void shutdown() { - stub.shutdown(); - } - - @Override - public boolean isShutdown() { - return stub.isShutdown(); - } - - @Override - public boolean isTerminated() { - return stub.isTerminated(); - } - - @Override - public void shutdownNow() { - stub.shutdownNow(); - } - - @Override - public boolean awaitTermination(long duration, TimeUnit unit) throws InterruptedException { - return stub.awaitTermination(duration, unit); - } - - public static class ListBuildsPagedResponse - extends AbstractPagedListResponse< - ListBuildsRequest, - ListBuildsResponse, - Build, - ListBuildsPage, - ListBuildsFixedSizeCollection> { - - public static ApiFuture createAsync( - PageContext context, - ApiFuture futureResponse) { - ApiFuture futurePage = - ListBuildsPage.createEmptyPage().createPageAsync(context, futureResponse); - return ApiFutures.transform( - futurePage, input -> new ListBuildsPagedResponse(input), MoreExecutors.directExecutor()); - } - - private ListBuildsPagedResponse(ListBuildsPage page) { - super(page, ListBuildsFixedSizeCollection.createEmptyCollection()); - } - } - - public static class ListBuildsPage - extends AbstractPage { - - private ListBuildsPage( - PageContext context, - ListBuildsResponse response) { - super(context, response); - } - - private static ListBuildsPage createEmptyPage() { - return new ListBuildsPage(null, null); - } - - @Override - protected ListBuildsPage createPage( - PageContext context, - ListBuildsResponse response) { - return new ListBuildsPage(context, response); - } - - @Override - public ApiFuture createPageAsync( - PageContext context, - ApiFuture futureResponse) { - return super.createPageAsync(context, futureResponse); - } - } - - public static class ListBuildsFixedSizeCollection - extends AbstractFixedSizeCollection< - ListBuildsRequest, - ListBuildsResponse, - Build, - ListBuildsPage, - ListBuildsFixedSizeCollection> { - - private ListBuildsFixedSizeCollection(List pages, int collectionSize) { - super(pages, collectionSize); - } - - private static ListBuildsFixedSizeCollection createEmptyCollection() { - return new ListBuildsFixedSizeCollection(null, 0); - } - - @Override - protected ListBuildsFixedSizeCollection createCollection( - List pages, int collectionSize) { - return new ListBuildsFixedSizeCollection(pages, collectionSize); - } - } - - public static class ListBuildTriggersPagedResponse - extends AbstractPagedListResponse< - ListBuildTriggersRequest, - ListBuildTriggersResponse, - BuildTrigger, - ListBuildTriggersPage, - ListBuildTriggersFixedSizeCollection> { - - public static ApiFuture createAsync( - PageContext context, - ApiFuture futureResponse) { - ApiFuture futurePage = - ListBuildTriggersPage.createEmptyPage().createPageAsync(context, futureResponse); - return ApiFutures.transform( - futurePage, - input -> new ListBuildTriggersPagedResponse(input), - MoreExecutors.directExecutor()); - } - - private ListBuildTriggersPagedResponse(ListBuildTriggersPage page) { - super(page, ListBuildTriggersFixedSizeCollection.createEmptyCollection()); - } - } - - public static class ListBuildTriggersPage - extends AbstractPage< - ListBuildTriggersRequest, - ListBuildTriggersResponse, - BuildTrigger, - ListBuildTriggersPage> { - - private ListBuildTriggersPage( - PageContext context, - ListBuildTriggersResponse response) { - super(context, response); - } - - private static ListBuildTriggersPage createEmptyPage() { - return new ListBuildTriggersPage(null, null); - } - - @Override - protected ListBuildTriggersPage createPage( - PageContext context, - ListBuildTriggersResponse response) { - return new ListBuildTriggersPage(context, response); - } - - @Override - public ApiFuture createPageAsync( - PageContext context, - ApiFuture futureResponse) { - return super.createPageAsync(context, futureResponse); - } - } - - public static class ListBuildTriggersFixedSizeCollection - extends AbstractFixedSizeCollection< - ListBuildTriggersRequest, - ListBuildTriggersResponse, - BuildTrigger, - ListBuildTriggersPage, - ListBuildTriggersFixedSizeCollection> { - - private ListBuildTriggersFixedSizeCollection( - List pages, int collectionSize) { - super(pages, collectionSize); - } - - private static ListBuildTriggersFixedSizeCollection createEmptyCollection() { - return new ListBuildTriggersFixedSizeCollection(null, 0); - } - - @Override - protected ListBuildTriggersFixedSizeCollection createCollection( - List pages, int collectionSize) { - return new ListBuildTriggersFixedSizeCollection(pages, collectionSize); - } - } - - public static class ListWorkerPoolsPagedResponse - extends AbstractPagedListResponse< - ListWorkerPoolsRequest, - ListWorkerPoolsResponse, - WorkerPool, - ListWorkerPoolsPage, - ListWorkerPoolsFixedSizeCollection> { - - public static ApiFuture createAsync( - PageContext context, - ApiFuture futureResponse) { - ApiFuture futurePage = - ListWorkerPoolsPage.createEmptyPage().createPageAsync(context, futureResponse); - return ApiFutures.transform( - futurePage, - input -> new ListWorkerPoolsPagedResponse(input), - MoreExecutors.directExecutor()); - } - - private ListWorkerPoolsPagedResponse(ListWorkerPoolsPage page) { - super(page, ListWorkerPoolsFixedSizeCollection.createEmptyCollection()); - } - } - - public static class ListWorkerPoolsPage - extends AbstractPage< - ListWorkerPoolsRequest, ListWorkerPoolsResponse, WorkerPool, ListWorkerPoolsPage> { - - private ListWorkerPoolsPage( - PageContext context, - ListWorkerPoolsResponse response) { - super(context, response); - } - - private static ListWorkerPoolsPage createEmptyPage() { - return new ListWorkerPoolsPage(null, null); - } - - @Override - protected ListWorkerPoolsPage createPage( - PageContext context, - ListWorkerPoolsResponse response) { - return new ListWorkerPoolsPage(context, response); - } - - @Override - public ApiFuture createPageAsync( - PageContext context, - ApiFuture futureResponse) { - return super.createPageAsync(context, futureResponse); - } - } - - public static class ListWorkerPoolsFixedSizeCollection - extends AbstractFixedSizeCollection< - ListWorkerPoolsRequest, - ListWorkerPoolsResponse, - WorkerPool, - ListWorkerPoolsPage, - ListWorkerPoolsFixedSizeCollection> { - - private ListWorkerPoolsFixedSizeCollection( - List pages, int collectionSize) { - super(pages, collectionSize); - } - - private static ListWorkerPoolsFixedSizeCollection createEmptyCollection() { - return new ListWorkerPoolsFixedSizeCollection(null, 0); - } - - @Override - protected ListWorkerPoolsFixedSizeCollection createCollection( - List pages, int collectionSize) { - return new ListWorkerPoolsFixedSizeCollection(pages, collectionSize); - } - } -} diff --git a/google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/CloudBuildSettings.java b/google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/CloudBuildSettings.java deleted file mode 100644 index ce32e376..00000000 --- a/google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/CloudBuildSettings.java +++ /dev/null @@ -1,515 +0,0 @@ -/* - * Copyright 2022 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package com.google.cloud.devtools.cloudbuild.v1; - -import static com.google.cloud.devtools.cloudbuild.v1.CloudBuildClient.ListBuildTriggersPagedResponse; -import static com.google.cloud.devtools.cloudbuild.v1.CloudBuildClient.ListBuildsPagedResponse; -import static com.google.cloud.devtools.cloudbuild.v1.CloudBuildClient.ListWorkerPoolsPagedResponse; - -import com.google.api.core.ApiFunction; -import com.google.api.core.BetaApi; -import com.google.api.gax.core.GoogleCredentialsProvider; -import com.google.api.gax.core.InstantiatingExecutorProvider; -import com.google.api.gax.grpc.InstantiatingGrpcChannelProvider; -import com.google.api.gax.httpjson.InstantiatingHttpJsonChannelProvider; -import com.google.api.gax.rpc.ApiClientHeaderProvider; -import com.google.api.gax.rpc.ClientContext; -import com.google.api.gax.rpc.ClientSettings; -import com.google.api.gax.rpc.OperationCallSettings; -import com.google.api.gax.rpc.PagedCallSettings; -import com.google.api.gax.rpc.TransportChannelProvider; -import com.google.api.gax.rpc.UnaryCallSettings; -import com.google.cloud.devtools.cloudbuild.v1.stub.CloudBuildStubSettings; -import com.google.cloudbuild.v1.ApproveBuildRequest; -import com.google.cloudbuild.v1.Build; -import com.google.cloudbuild.v1.BuildOperationMetadata; -import com.google.cloudbuild.v1.BuildTrigger; -import com.google.cloudbuild.v1.CancelBuildRequest; -import com.google.cloudbuild.v1.CreateBuildRequest; -import com.google.cloudbuild.v1.CreateBuildTriggerRequest; -import com.google.cloudbuild.v1.CreateWorkerPoolOperationMetadata; -import com.google.cloudbuild.v1.CreateWorkerPoolRequest; -import com.google.cloudbuild.v1.DeleteBuildTriggerRequest; -import com.google.cloudbuild.v1.DeleteWorkerPoolOperationMetadata; -import com.google.cloudbuild.v1.DeleteWorkerPoolRequest; -import com.google.cloudbuild.v1.GetBuildRequest; -import com.google.cloudbuild.v1.GetBuildTriggerRequest; -import com.google.cloudbuild.v1.GetWorkerPoolRequest; -import com.google.cloudbuild.v1.ListBuildTriggersRequest; -import com.google.cloudbuild.v1.ListBuildTriggersResponse; -import com.google.cloudbuild.v1.ListBuildsRequest; -import com.google.cloudbuild.v1.ListBuildsResponse; -import com.google.cloudbuild.v1.ListWorkerPoolsRequest; -import com.google.cloudbuild.v1.ListWorkerPoolsResponse; -import com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest; -import com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse; -import com.google.cloudbuild.v1.RetryBuildRequest; -import com.google.cloudbuild.v1.RunBuildTriggerRequest; -import com.google.cloudbuild.v1.UpdateBuildTriggerRequest; -import com.google.cloudbuild.v1.UpdateWorkerPoolOperationMetadata; -import com.google.cloudbuild.v1.UpdateWorkerPoolRequest; -import com.google.cloudbuild.v1.WorkerPool; -import com.google.longrunning.Operation; -import com.google.protobuf.Empty; -import java.io.IOException; -import java.util.List; -import javax.annotation.Generated; - -// AUTO-GENERATED DOCUMENTATION AND CLASS. -/** - * Settings class to configure an instance of {@link CloudBuildClient}. - * - *

The default instance has everything set to sensible defaults: - * - *

    - *
  • The default service address (cloudbuild.googleapis.com) and default port (443) are used. - *
  • Credentials are acquired automatically through Application Default Credentials. - *
  • Retries are configured for idempotent methods but not for non-idempotent methods. - *
- * - *

The builder of this class is recursive, so contained classes are themselves builders. When - * build() is called, the tree of builders is called to create the complete settings object. - * - *

For example, to set the total timeout of getBuild to 30 seconds: - * - *

{@code
- * // This snippet has been automatically generated and should be regarded as a code template only.
- * // It will require modifications to work:
- * // - It may require correct/in-range values for request initialization.
- * // - It may require specifying regional endpoints when creating the service client as shown in
- * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
- * CloudBuildSettings.Builder cloudBuildSettingsBuilder = CloudBuildSettings.newBuilder();
- * cloudBuildSettingsBuilder
- *     .getBuildSettings()
- *     .setRetrySettings(
- *         cloudBuildSettingsBuilder.getBuildSettings().getRetrySettings().toBuilder()
- *             .setTotalTimeout(Duration.ofSeconds(30))
- *             .build());
- * CloudBuildSettings cloudBuildSettings = cloudBuildSettingsBuilder.build();
- * }
- */ -@Generated("by gapic-generator-java") -public class CloudBuildSettings extends ClientSettings { - - /** Returns the object with the settings used for calls to createBuild. */ - public UnaryCallSettings createBuildSettings() { - return ((CloudBuildStubSettings) getStubSettings()).createBuildSettings(); - } - - /** Returns the object with the settings used for calls to createBuild. */ - public OperationCallSettings - createBuildOperationSettings() { - return ((CloudBuildStubSettings) getStubSettings()).createBuildOperationSettings(); - } - - /** Returns the object with the settings used for calls to getBuild. */ - public UnaryCallSettings getBuildSettings() { - return ((CloudBuildStubSettings) getStubSettings()).getBuildSettings(); - } - - /** Returns the object with the settings used for calls to listBuilds. */ - public PagedCallSettings - listBuildsSettings() { - return ((CloudBuildStubSettings) getStubSettings()).listBuildsSettings(); - } - - /** Returns the object with the settings used for calls to cancelBuild. */ - public UnaryCallSettings cancelBuildSettings() { - return ((CloudBuildStubSettings) getStubSettings()).cancelBuildSettings(); - } - - /** Returns the object with the settings used for calls to retryBuild. */ - public UnaryCallSettings retryBuildSettings() { - return ((CloudBuildStubSettings) getStubSettings()).retryBuildSettings(); - } - - /** Returns the object with the settings used for calls to retryBuild. */ - public OperationCallSettings - retryBuildOperationSettings() { - return ((CloudBuildStubSettings) getStubSettings()).retryBuildOperationSettings(); - } - - /** Returns the object with the settings used for calls to approveBuild. */ - public UnaryCallSettings approveBuildSettings() { - return ((CloudBuildStubSettings) getStubSettings()).approveBuildSettings(); - } - - /** Returns the object with the settings used for calls to approveBuild. */ - public OperationCallSettings - approveBuildOperationSettings() { - return ((CloudBuildStubSettings) getStubSettings()).approveBuildOperationSettings(); - } - - /** Returns the object with the settings used for calls to createBuildTrigger. */ - public UnaryCallSettings createBuildTriggerSettings() { - return ((CloudBuildStubSettings) getStubSettings()).createBuildTriggerSettings(); - } - - /** Returns the object with the settings used for calls to getBuildTrigger. */ - public UnaryCallSettings getBuildTriggerSettings() { - return ((CloudBuildStubSettings) getStubSettings()).getBuildTriggerSettings(); - } - - /** Returns the object with the settings used for calls to listBuildTriggers. */ - public PagedCallSettings< - ListBuildTriggersRequest, ListBuildTriggersResponse, ListBuildTriggersPagedResponse> - listBuildTriggersSettings() { - return ((CloudBuildStubSettings) getStubSettings()).listBuildTriggersSettings(); - } - - /** Returns the object with the settings used for calls to deleteBuildTrigger. */ - public UnaryCallSettings deleteBuildTriggerSettings() { - return ((CloudBuildStubSettings) getStubSettings()).deleteBuildTriggerSettings(); - } - - /** Returns the object with the settings used for calls to updateBuildTrigger. */ - public UnaryCallSettings updateBuildTriggerSettings() { - return ((CloudBuildStubSettings) getStubSettings()).updateBuildTriggerSettings(); - } - - /** Returns the object with the settings used for calls to runBuildTrigger. */ - public UnaryCallSettings runBuildTriggerSettings() { - return ((CloudBuildStubSettings) getStubSettings()).runBuildTriggerSettings(); - } - - /** Returns the object with the settings used for calls to runBuildTrigger. */ - public OperationCallSettings - runBuildTriggerOperationSettings() { - return ((CloudBuildStubSettings) getStubSettings()).runBuildTriggerOperationSettings(); - } - - /** Returns the object with the settings used for calls to receiveTriggerWebhook. */ - public UnaryCallSettings - receiveTriggerWebhookSettings() { - return ((CloudBuildStubSettings) getStubSettings()).receiveTriggerWebhookSettings(); - } - - /** Returns the object with the settings used for calls to createWorkerPool. */ - public UnaryCallSettings createWorkerPoolSettings() { - return ((CloudBuildStubSettings) getStubSettings()).createWorkerPoolSettings(); - } - - /** Returns the object with the settings used for calls to createWorkerPool. */ - public OperationCallSettings< - CreateWorkerPoolRequest, WorkerPool, CreateWorkerPoolOperationMetadata> - createWorkerPoolOperationSettings() { - return ((CloudBuildStubSettings) getStubSettings()).createWorkerPoolOperationSettings(); - } - - /** Returns the object with the settings used for calls to getWorkerPool. */ - public UnaryCallSettings getWorkerPoolSettings() { - return ((CloudBuildStubSettings) getStubSettings()).getWorkerPoolSettings(); - } - - /** Returns the object with the settings used for calls to deleteWorkerPool. */ - public UnaryCallSettings deleteWorkerPoolSettings() { - return ((CloudBuildStubSettings) getStubSettings()).deleteWorkerPoolSettings(); - } - - /** Returns the object with the settings used for calls to deleteWorkerPool. */ - public OperationCallSettings - deleteWorkerPoolOperationSettings() { - return ((CloudBuildStubSettings) getStubSettings()).deleteWorkerPoolOperationSettings(); - } - - /** Returns the object with the settings used for calls to updateWorkerPool. */ - public UnaryCallSettings updateWorkerPoolSettings() { - return ((CloudBuildStubSettings) getStubSettings()).updateWorkerPoolSettings(); - } - - /** Returns the object with the settings used for calls to updateWorkerPool. */ - public OperationCallSettings< - UpdateWorkerPoolRequest, WorkerPool, UpdateWorkerPoolOperationMetadata> - updateWorkerPoolOperationSettings() { - return ((CloudBuildStubSettings) getStubSettings()).updateWorkerPoolOperationSettings(); - } - - /** Returns the object with the settings used for calls to listWorkerPools. */ - public PagedCallSettings< - ListWorkerPoolsRequest, ListWorkerPoolsResponse, ListWorkerPoolsPagedResponse> - listWorkerPoolsSettings() { - return ((CloudBuildStubSettings) getStubSettings()).listWorkerPoolsSettings(); - } - - public static final CloudBuildSettings create(CloudBuildStubSettings stub) throws IOException { - return new CloudBuildSettings.Builder(stub.toBuilder()).build(); - } - - /** Returns a builder for the default ExecutorProvider for this service. */ - public static InstantiatingExecutorProvider.Builder defaultExecutorProviderBuilder() { - return CloudBuildStubSettings.defaultExecutorProviderBuilder(); - } - - /** Returns the default service endpoint. */ - public static String getDefaultEndpoint() { - return CloudBuildStubSettings.getDefaultEndpoint(); - } - - /** Returns the default service scopes. */ - public static List getDefaultServiceScopes() { - return CloudBuildStubSettings.getDefaultServiceScopes(); - } - - /** Returns a builder for the default credentials for this service. */ - public static GoogleCredentialsProvider.Builder defaultCredentialsProviderBuilder() { - return CloudBuildStubSettings.defaultCredentialsProviderBuilder(); - } - - /** Returns a builder for the default gRPC ChannelProvider for this service. */ - public static InstantiatingGrpcChannelProvider.Builder defaultGrpcTransportProviderBuilder() { - return CloudBuildStubSettings.defaultGrpcTransportProviderBuilder(); - } - - /** Returns a builder for the default REST ChannelProvider for this service. */ - @BetaApi - public static InstantiatingHttpJsonChannelProvider.Builder - defaultHttpJsonTransportProviderBuilder() { - return CloudBuildStubSettings.defaultHttpJsonTransportProviderBuilder(); - } - - public static TransportChannelProvider defaultTransportChannelProvider() { - return CloudBuildStubSettings.defaultTransportChannelProvider(); - } - - @BetaApi("The surface for customizing headers is not stable yet and may change in the future.") - public static ApiClientHeaderProvider.Builder defaultApiClientHeaderProviderBuilder() { - return CloudBuildStubSettings.defaultApiClientHeaderProviderBuilder(); - } - - /** Returns a new gRPC builder for this class. */ - public static Builder newBuilder() { - return Builder.createDefault(); - } - - /** Returns a new REST builder for this class. */ - @BetaApi - public static Builder newHttpJsonBuilder() { - return Builder.createHttpJsonDefault(); - } - - /** Returns a new builder for this class. */ - public static Builder newBuilder(ClientContext clientContext) { - return new Builder(clientContext); - } - - /** Returns a builder containing all the values of this settings class. */ - public Builder toBuilder() { - return new Builder(this); - } - - protected CloudBuildSettings(Builder settingsBuilder) throws IOException { - super(settingsBuilder); - } - - /** Builder for CloudBuildSettings. */ - public static class Builder extends ClientSettings.Builder { - - protected Builder() throws IOException { - this(((ClientContext) null)); - } - - protected Builder(ClientContext clientContext) { - super(CloudBuildStubSettings.newBuilder(clientContext)); - } - - protected Builder(CloudBuildSettings settings) { - super(settings.getStubSettings().toBuilder()); - } - - protected Builder(CloudBuildStubSettings.Builder stubSettings) { - super(stubSettings); - } - - private static Builder createDefault() { - return new Builder(CloudBuildStubSettings.newBuilder()); - } - - @BetaApi - private static Builder createHttpJsonDefault() { - return new Builder(CloudBuildStubSettings.newHttpJsonBuilder()); - } - - public CloudBuildStubSettings.Builder getStubSettingsBuilder() { - return ((CloudBuildStubSettings.Builder) getStubSettings()); - } - - /** - * Applies the given settings updater function to all of the unary API methods in this service. - * - *

Note: This method does not support applying settings to streaming methods. - */ - public Builder applyToAllUnaryMethods( - ApiFunction, Void> settingsUpdater) { - super.applyToAllUnaryMethods( - getStubSettingsBuilder().unaryMethodSettingsBuilders(), settingsUpdater); - return this; - } - - /** Returns the builder for the settings used for calls to createBuild. */ - public UnaryCallSettings.Builder createBuildSettings() { - return getStubSettingsBuilder().createBuildSettings(); - } - - /** Returns the builder for the settings used for calls to createBuild. */ - public OperationCallSettings.Builder - createBuildOperationSettings() { - return getStubSettingsBuilder().createBuildOperationSettings(); - } - - /** Returns the builder for the settings used for calls to getBuild. */ - public UnaryCallSettings.Builder getBuildSettings() { - return getStubSettingsBuilder().getBuildSettings(); - } - - /** Returns the builder for the settings used for calls to listBuilds. */ - public PagedCallSettings.Builder - listBuildsSettings() { - return getStubSettingsBuilder().listBuildsSettings(); - } - - /** Returns the builder for the settings used for calls to cancelBuild. */ - public UnaryCallSettings.Builder cancelBuildSettings() { - return getStubSettingsBuilder().cancelBuildSettings(); - } - - /** Returns the builder for the settings used for calls to retryBuild. */ - public UnaryCallSettings.Builder retryBuildSettings() { - return getStubSettingsBuilder().retryBuildSettings(); - } - - /** Returns the builder for the settings used for calls to retryBuild. */ - public OperationCallSettings.Builder - retryBuildOperationSettings() { - return getStubSettingsBuilder().retryBuildOperationSettings(); - } - - /** Returns the builder for the settings used for calls to approveBuild. */ - public UnaryCallSettings.Builder approveBuildSettings() { - return getStubSettingsBuilder().approveBuildSettings(); - } - - /** Returns the builder for the settings used for calls to approveBuild. */ - public OperationCallSettings.Builder - approveBuildOperationSettings() { - return getStubSettingsBuilder().approveBuildOperationSettings(); - } - - /** Returns the builder for the settings used for calls to createBuildTrigger. */ - public UnaryCallSettings.Builder - createBuildTriggerSettings() { - return getStubSettingsBuilder().createBuildTriggerSettings(); - } - - /** Returns the builder for the settings used for calls to getBuildTrigger. */ - public UnaryCallSettings.Builder - getBuildTriggerSettings() { - return getStubSettingsBuilder().getBuildTriggerSettings(); - } - - /** Returns the builder for the settings used for calls to listBuildTriggers. */ - public PagedCallSettings.Builder< - ListBuildTriggersRequest, ListBuildTriggersResponse, ListBuildTriggersPagedResponse> - listBuildTriggersSettings() { - return getStubSettingsBuilder().listBuildTriggersSettings(); - } - - /** Returns the builder for the settings used for calls to deleteBuildTrigger. */ - public UnaryCallSettings.Builder - deleteBuildTriggerSettings() { - return getStubSettingsBuilder().deleteBuildTriggerSettings(); - } - - /** Returns the builder for the settings used for calls to updateBuildTrigger. */ - public UnaryCallSettings.Builder - updateBuildTriggerSettings() { - return getStubSettingsBuilder().updateBuildTriggerSettings(); - } - - /** Returns the builder for the settings used for calls to runBuildTrigger. */ - public UnaryCallSettings.Builder runBuildTriggerSettings() { - return getStubSettingsBuilder().runBuildTriggerSettings(); - } - - /** Returns the builder for the settings used for calls to runBuildTrigger. */ - public OperationCallSettings.Builder - runBuildTriggerOperationSettings() { - return getStubSettingsBuilder().runBuildTriggerOperationSettings(); - } - - /** Returns the builder for the settings used for calls to receiveTriggerWebhook. */ - public UnaryCallSettings.Builder - receiveTriggerWebhookSettings() { - return getStubSettingsBuilder().receiveTriggerWebhookSettings(); - } - - /** Returns the builder for the settings used for calls to createWorkerPool. */ - public UnaryCallSettings.Builder - createWorkerPoolSettings() { - return getStubSettingsBuilder().createWorkerPoolSettings(); - } - - /** Returns the builder for the settings used for calls to createWorkerPool. */ - public OperationCallSettings.Builder< - CreateWorkerPoolRequest, WorkerPool, CreateWorkerPoolOperationMetadata> - createWorkerPoolOperationSettings() { - return getStubSettingsBuilder().createWorkerPoolOperationSettings(); - } - - /** Returns the builder for the settings used for calls to getWorkerPool. */ - public UnaryCallSettings.Builder getWorkerPoolSettings() { - return getStubSettingsBuilder().getWorkerPoolSettings(); - } - - /** Returns the builder for the settings used for calls to deleteWorkerPool. */ - public UnaryCallSettings.Builder - deleteWorkerPoolSettings() { - return getStubSettingsBuilder().deleteWorkerPoolSettings(); - } - - /** Returns the builder for the settings used for calls to deleteWorkerPool. */ - public OperationCallSettings.Builder< - DeleteWorkerPoolRequest, Empty, DeleteWorkerPoolOperationMetadata> - deleteWorkerPoolOperationSettings() { - return getStubSettingsBuilder().deleteWorkerPoolOperationSettings(); - } - - /** Returns the builder for the settings used for calls to updateWorkerPool. */ - public UnaryCallSettings.Builder - updateWorkerPoolSettings() { - return getStubSettingsBuilder().updateWorkerPoolSettings(); - } - - /** Returns the builder for the settings used for calls to updateWorkerPool. */ - public OperationCallSettings.Builder< - UpdateWorkerPoolRequest, WorkerPool, UpdateWorkerPoolOperationMetadata> - updateWorkerPoolOperationSettings() { - return getStubSettingsBuilder().updateWorkerPoolOperationSettings(); - } - - /** Returns the builder for the settings used for calls to listWorkerPools. */ - public PagedCallSettings.Builder< - ListWorkerPoolsRequest, ListWorkerPoolsResponse, ListWorkerPoolsPagedResponse> - listWorkerPoolsSettings() { - return getStubSettingsBuilder().listWorkerPoolsSettings(); - } - - @Override - public CloudBuildSettings build() throws IOException { - return new CloudBuildSettings(this); - } - } -} diff --git a/google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/gapic_metadata.json b/google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/gapic_metadata.json deleted file mode 100644 index 1b680cf9..00000000 --- a/google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/gapic_metadata.json +++ /dev/null @@ -1,72 +0,0 @@ -{ - "schema": "1.0", - "comment": "This file maps proto services/RPCs to the corresponding library clients/methods", - "language": "java", - "protoPackage": "google.devtools.cloudbuild.v1", - "libraryPackage": "com.google.cloud.devtools.cloudbuild.v1", - "services": { - "CloudBuild": { - "clients": { - "grpc": { - "libraryClient": "CloudBuildClient", - "rpcs": { - "ApproveBuild": { - "methods": ["approveBuildAsync", "approveBuildAsync", "approveBuildOperationCallable", "approveBuildCallable"] - }, - "CancelBuild": { - "methods": ["cancelBuild", "cancelBuild", "cancelBuildCallable"] - }, - "CreateBuild": { - "methods": ["createBuildAsync", "createBuildAsync", "createBuildOperationCallable", "createBuildCallable"] - }, - "CreateBuildTrigger": { - "methods": ["createBuildTrigger", "createBuildTrigger", "createBuildTriggerCallable"] - }, - "CreateWorkerPool": { - "methods": ["createWorkerPoolAsync", "createWorkerPoolAsync", "createWorkerPoolAsync", "createWorkerPoolOperationCallable", "createWorkerPoolCallable"] - }, - "DeleteBuildTrigger": { - "methods": ["deleteBuildTrigger", "deleteBuildTrigger", "deleteBuildTriggerCallable"] - }, - "DeleteWorkerPool": { - "methods": ["deleteWorkerPoolAsync", "deleteWorkerPoolAsync", "deleteWorkerPoolAsync", "deleteWorkerPoolOperationCallable", "deleteWorkerPoolCallable"] - }, - "GetBuild": { - "methods": ["getBuild", "getBuild", "getBuildCallable"] - }, - "GetBuildTrigger": { - "methods": ["getBuildTrigger", "getBuildTrigger", "getBuildTriggerCallable"] - }, - "GetWorkerPool": { - "methods": ["getWorkerPool", "getWorkerPool", "getWorkerPool", "getWorkerPoolCallable"] - }, - "ListBuildTriggers": { - "methods": ["listBuildTriggers", "listBuildTriggers", "listBuildTriggersPagedCallable", "listBuildTriggersCallable"] - }, - "ListBuilds": { - "methods": ["listBuilds", "listBuilds", "listBuildsPagedCallable", "listBuildsCallable"] - }, - "ListWorkerPools": { - "methods": ["listWorkerPools", "listWorkerPools", "listWorkerPools", "listWorkerPoolsPagedCallable", "listWorkerPoolsCallable"] - }, - "ReceiveTriggerWebhook": { - "methods": ["receiveTriggerWebhook", "receiveTriggerWebhookCallable"] - }, - "RetryBuild": { - "methods": ["retryBuildAsync", "retryBuildAsync", "retryBuildOperationCallable", "retryBuildCallable"] - }, - "RunBuildTrigger": { - "methods": ["runBuildTriggerAsync", "runBuildTriggerAsync", "runBuildTriggerOperationCallable", "runBuildTriggerCallable"] - }, - "UpdateBuildTrigger": { - "methods": ["updateBuildTrigger", "updateBuildTrigger", "updateBuildTriggerCallable"] - }, - "UpdateWorkerPool": { - "methods": ["updateWorkerPoolAsync", "updateWorkerPoolAsync", "updateWorkerPoolOperationCallable", "updateWorkerPoolCallable"] - } - } - } - } - } - } -} \ No newline at end of file diff --git a/google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/package-info.java b/google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/package-info.java deleted file mode 100644 index 6bb314aa..00000000 --- a/google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/package-info.java +++ /dev/null @@ -1,48 +0,0 @@ -/* - * Copyright 2022 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -/** - * The interfaces provided are listed below, along with usage samples. - * - *

======================= CloudBuildClient ======================= - * - *

Service Description: Creates and manages builds on Google Cloud Platform. - * - *

The main concept used by this API is a `Build`, which describes the location of the source to - * build, how to build the source, and where to store the built artifacts, if any. - * - *

A user can list previously-requested builds or get builds by their ID to determine the status - * of the build. - * - *

Sample for CloudBuildClient: - * - *

{@code
- * // This snippet has been automatically generated and should be regarded as a code template only.
- * // It will require modifications to work:
- * // - It may require correct/in-range values for request initialization.
- * // - It may require specifying regional endpoints when creating the service client as shown in
- * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
- * try (CloudBuildClient cloudBuildClient = CloudBuildClient.create()) {
- *   String projectId = "projectId-894832108";
- *   String id = "id3355";
- *   Build response = cloudBuildClient.getBuild(projectId, id);
- * }
- * }
- */ -@Generated("by gapic-generator-java") -package com.google.cloud.devtools.cloudbuild.v1; - -import javax.annotation.Generated; diff --git a/google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/stub/CloudBuildStub.java b/google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/stub/CloudBuildStub.java deleted file mode 100644 index 7ceb4a8d..00000000 --- a/google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/stub/CloudBuildStub.java +++ /dev/null @@ -1,202 +0,0 @@ -/* - * Copyright 2022 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package com.google.cloud.devtools.cloudbuild.v1.stub; - -import static com.google.cloud.devtools.cloudbuild.v1.CloudBuildClient.ListBuildTriggersPagedResponse; -import static com.google.cloud.devtools.cloudbuild.v1.CloudBuildClient.ListBuildsPagedResponse; -import static com.google.cloud.devtools.cloudbuild.v1.CloudBuildClient.ListWorkerPoolsPagedResponse; - -import com.google.api.gax.core.BackgroundResource; -import com.google.api.gax.rpc.OperationCallable; -import com.google.api.gax.rpc.UnaryCallable; -import com.google.cloudbuild.v1.ApproveBuildRequest; -import com.google.cloudbuild.v1.Build; -import com.google.cloudbuild.v1.BuildOperationMetadata; -import com.google.cloudbuild.v1.BuildTrigger; -import com.google.cloudbuild.v1.CancelBuildRequest; -import com.google.cloudbuild.v1.CreateBuildRequest; -import com.google.cloudbuild.v1.CreateBuildTriggerRequest; -import com.google.cloudbuild.v1.CreateWorkerPoolOperationMetadata; -import com.google.cloudbuild.v1.CreateWorkerPoolRequest; -import com.google.cloudbuild.v1.DeleteBuildTriggerRequest; -import com.google.cloudbuild.v1.DeleteWorkerPoolOperationMetadata; -import com.google.cloudbuild.v1.DeleteWorkerPoolRequest; -import com.google.cloudbuild.v1.GetBuildRequest; -import com.google.cloudbuild.v1.GetBuildTriggerRequest; -import com.google.cloudbuild.v1.GetWorkerPoolRequest; -import com.google.cloudbuild.v1.ListBuildTriggersRequest; -import com.google.cloudbuild.v1.ListBuildTriggersResponse; -import com.google.cloudbuild.v1.ListBuildsRequest; -import com.google.cloudbuild.v1.ListBuildsResponse; -import com.google.cloudbuild.v1.ListWorkerPoolsRequest; -import com.google.cloudbuild.v1.ListWorkerPoolsResponse; -import com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest; -import com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse; -import com.google.cloudbuild.v1.RetryBuildRequest; -import com.google.cloudbuild.v1.RunBuildTriggerRequest; -import com.google.cloudbuild.v1.UpdateBuildTriggerRequest; -import com.google.cloudbuild.v1.UpdateWorkerPoolOperationMetadata; -import com.google.cloudbuild.v1.UpdateWorkerPoolRequest; -import com.google.cloudbuild.v1.WorkerPool; -import com.google.longrunning.Operation; -import com.google.longrunning.stub.OperationsStub; -import com.google.protobuf.Empty; -import javax.annotation.Generated; - -// AUTO-GENERATED DOCUMENTATION AND CLASS. -/** - * Base stub class for the CloudBuild service API. - * - *

This class is for advanced usage and reflects the underlying API directly. - */ -@Generated("by gapic-generator-java") -public abstract class CloudBuildStub implements BackgroundResource { - - public OperationsStub getOperationsStub() { - return null; - } - - public com.google.api.gax.httpjson.longrunning.stub.OperationsStub getHttpJsonOperationsStub() { - return null; - } - - public OperationCallable - createBuildOperationCallable() { - throw new UnsupportedOperationException("Not implemented: createBuildOperationCallable()"); - } - - public UnaryCallable createBuildCallable() { - throw new UnsupportedOperationException("Not implemented: createBuildCallable()"); - } - - public UnaryCallable getBuildCallable() { - throw new UnsupportedOperationException("Not implemented: getBuildCallable()"); - } - - public UnaryCallable listBuildsPagedCallable() { - throw new UnsupportedOperationException("Not implemented: listBuildsPagedCallable()"); - } - - public UnaryCallable listBuildsCallable() { - throw new UnsupportedOperationException("Not implemented: listBuildsCallable()"); - } - - public UnaryCallable cancelBuildCallable() { - throw new UnsupportedOperationException("Not implemented: cancelBuildCallable()"); - } - - public OperationCallable - retryBuildOperationCallable() { - throw new UnsupportedOperationException("Not implemented: retryBuildOperationCallable()"); - } - - public UnaryCallable retryBuildCallable() { - throw new UnsupportedOperationException("Not implemented: retryBuildCallable()"); - } - - public OperationCallable - approveBuildOperationCallable() { - throw new UnsupportedOperationException("Not implemented: approveBuildOperationCallable()"); - } - - public UnaryCallable approveBuildCallable() { - throw new UnsupportedOperationException("Not implemented: approveBuildCallable()"); - } - - public UnaryCallable createBuildTriggerCallable() { - throw new UnsupportedOperationException("Not implemented: createBuildTriggerCallable()"); - } - - public UnaryCallable getBuildTriggerCallable() { - throw new UnsupportedOperationException("Not implemented: getBuildTriggerCallable()"); - } - - public UnaryCallable - listBuildTriggersPagedCallable() { - throw new UnsupportedOperationException("Not implemented: listBuildTriggersPagedCallable()"); - } - - public UnaryCallable - listBuildTriggersCallable() { - throw new UnsupportedOperationException("Not implemented: listBuildTriggersCallable()"); - } - - public UnaryCallable deleteBuildTriggerCallable() { - throw new UnsupportedOperationException("Not implemented: deleteBuildTriggerCallable()"); - } - - public UnaryCallable updateBuildTriggerCallable() { - throw new UnsupportedOperationException("Not implemented: updateBuildTriggerCallable()"); - } - - public OperationCallable - runBuildTriggerOperationCallable() { - throw new UnsupportedOperationException("Not implemented: runBuildTriggerOperationCallable()"); - } - - public UnaryCallable runBuildTriggerCallable() { - throw new UnsupportedOperationException("Not implemented: runBuildTriggerCallable()"); - } - - public UnaryCallable - receiveTriggerWebhookCallable() { - throw new UnsupportedOperationException("Not implemented: receiveTriggerWebhookCallable()"); - } - - public OperationCallable - createWorkerPoolOperationCallable() { - throw new UnsupportedOperationException("Not implemented: createWorkerPoolOperationCallable()"); - } - - public UnaryCallable createWorkerPoolCallable() { - throw new UnsupportedOperationException("Not implemented: createWorkerPoolCallable()"); - } - - public UnaryCallable getWorkerPoolCallable() { - throw new UnsupportedOperationException("Not implemented: getWorkerPoolCallable()"); - } - - public OperationCallable - deleteWorkerPoolOperationCallable() { - throw new UnsupportedOperationException("Not implemented: deleteWorkerPoolOperationCallable()"); - } - - public UnaryCallable deleteWorkerPoolCallable() { - throw new UnsupportedOperationException("Not implemented: deleteWorkerPoolCallable()"); - } - - public OperationCallable - updateWorkerPoolOperationCallable() { - throw new UnsupportedOperationException("Not implemented: updateWorkerPoolOperationCallable()"); - } - - public UnaryCallable updateWorkerPoolCallable() { - throw new UnsupportedOperationException("Not implemented: updateWorkerPoolCallable()"); - } - - public UnaryCallable - listWorkerPoolsPagedCallable() { - throw new UnsupportedOperationException("Not implemented: listWorkerPoolsPagedCallable()"); - } - - public UnaryCallable listWorkerPoolsCallable() { - throw new UnsupportedOperationException("Not implemented: listWorkerPoolsCallable()"); - } - - @Override - public abstract void close(); -} diff --git a/google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/stub/CloudBuildStubSettings.java b/google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/stub/CloudBuildStubSettings.java deleted file mode 100644 index 7c7f1446..00000000 --- a/google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/stub/CloudBuildStubSettings.java +++ /dev/null @@ -1,1297 +0,0 @@ -/* - * Copyright 2022 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package com.google.cloud.devtools.cloudbuild.v1.stub; - -import static com.google.cloud.devtools.cloudbuild.v1.CloudBuildClient.ListBuildTriggersPagedResponse; -import static com.google.cloud.devtools.cloudbuild.v1.CloudBuildClient.ListBuildsPagedResponse; -import static com.google.cloud.devtools.cloudbuild.v1.CloudBuildClient.ListWorkerPoolsPagedResponse; - -import com.google.api.core.ApiFunction; -import com.google.api.core.ApiFuture; -import com.google.api.core.BetaApi; -import com.google.api.gax.core.GaxProperties; -import com.google.api.gax.core.GoogleCredentialsProvider; -import com.google.api.gax.core.InstantiatingExecutorProvider; -import com.google.api.gax.grpc.GaxGrpcProperties; -import com.google.api.gax.grpc.GrpcTransportChannel; -import com.google.api.gax.grpc.InstantiatingGrpcChannelProvider; -import com.google.api.gax.grpc.ProtoOperationTransformers; -import com.google.api.gax.httpjson.GaxHttpJsonProperties; -import com.google.api.gax.httpjson.HttpJsonTransportChannel; -import com.google.api.gax.httpjson.InstantiatingHttpJsonChannelProvider; -import com.google.api.gax.longrunning.OperationSnapshot; -import com.google.api.gax.longrunning.OperationTimedPollAlgorithm; -import com.google.api.gax.retrying.RetrySettings; -import com.google.api.gax.rpc.ApiCallContext; -import com.google.api.gax.rpc.ApiClientHeaderProvider; -import com.google.api.gax.rpc.ClientContext; -import com.google.api.gax.rpc.OperationCallSettings; -import com.google.api.gax.rpc.PageContext; -import com.google.api.gax.rpc.PagedCallSettings; -import com.google.api.gax.rpc.PagedListDescriptor; -import com.google.api.gax.rpc.PagedListResponseFactory; -import com.google.api.gax.rpc.StatusCode; -import com.google.api.gax.rpc.StubSettings; -import com.google.api.gax.rpc.TransportChannelProvider; -import com.google.api.gax.rpc.UnaryCallSettings; -import com.google.api.gax.rpc.UnaryCallable; -import com.google.cloudbuild.v1.ApproveBuildRequest; -import com.google.cloudbuild.v1.Build; -import com.google.cloudbuild.v1.BuildOperationMetadata; -import com.google.cloudbuild.v1.BuildTrigger; -import com.google.cloudbuild.v1.CancelBuildRequest; -import com.google.cloudbuild.v1.CreateBuildRequest; -import com.google.cloudbuild.v1.CreateBuildTriggerRequest; -import com.google.cloudbuild.v1.CreateWorkerPoolOperationMetadata; -import com.google.cloudbuild.v1.CreateWorkerPoolRequest; -import com.google.cloudbuild.v1.DeleteBuildTriggerRequest; -import com.google.cloudbuild.v1.DeleteWorkerPoolOperationMetadata; -import com.google.cloudbuild.v1.DeleteWorkerPoolRequest; -import com.google.cloudbuild.v1.GetBuildRequest; -import com.google.cloudbuild.v1.GetBuildTriggerRequest; -import com.google.cloudbuild.v1.GetWorkerPoolRequest; -import com.google.cloudbuild.v1.ListBuildTriggersRequest; -import com.google.cloudbuild.v1.ListBuildTriggersResponse; -import com.google.cloudbuild.v1.ListBuildsRequest; -import com.google.cloudbuild.v1.ListBuildsResponse; -import com.google.cloudbuild.v1.ListWorkerPoolsRequest; -import com.google.cloudbuild.v1.ListWorkerPoolsResponse; -import com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest; -import com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse; -import com.google.cloudbuild.v1.RetryBuildRequest; -import com.google.cloudbuild.v1.RunBuildTriggerRequest; -import com.google.cloudbuild.v1.UpdateBuildTriggerRequest; -import com.google.cloudbuild.v1.UpdateWorkerPoolOperationMetadata; -import com.google.cloudbuild.v1.UpdateWorkerPoolRequest; -import com.google.cloudbuild.v1.WorkerPool; -import com.google.common.collect.ImmutableList; -import com.google.common.collect.ImmutableMap; -import com.google.common.collect.ImmutableSet; -import com.google.common.collect.Lists; -import com.google.longrunning.Operation; -import com.google.protobuf.Empty; -import java.io.IOException; -import java.util.List; -import javax.annotation.Generated; -import org.threeten.bp.Duration; - -// AUTO-GENERATED DOCUMENTATION AND CLASS. -/** - * Settings class to configure an instance of {@link CloudBuildStub}. - * - *

The default instance has everything set to sensible defaults: - * - *

    - *
  • The default service address (cloudbuild.googleapis.com) and default port (443) are used. - *
  • Credentials are acquired automatically through Application Default Credentials. - *
  • Retries are configured for idempotent methods but not for non-idempotent methods. - *
- * - *

The builder of this class is recursive, so contained classes are themselves builders. When - * build() is called, the tree of builders is called to create the complete settings object. - * - *

For example, to set the total timeout of getBuild to 30 seconds: - * - *

{@code
- * // This snippet has been automatically generated and should be regarded as a code template only.
- * // It will require modifications to work:
- * // - It may require correct/in-range values for request initialization.
- * // - It may require specifying regional endpoints when creating the service client as shown in
- * // https://cloud.google.com/java/docs/setup#configure_endpoints_for_the_client_library
- * CloudBuildStubSettings.Builder cloudBuildSettingsBuilder = CloudBuildStubSettings.newBuilder();
- * cloudBuildSettingsBuilder
- *     .getBuildSettings()
- *     .setRetrySettings(
- *         cloudBuildSettingsBuilder.getBuildSettings().getRetrySettings().toBuilder()
- *             .setTotalTimeout(Duration.ofSeconds(30))
- *             .build());
- * CloudBuildStubSettings cloudBuildSettings = cloudBuildSettingsBuilder.build();
- * }
- */ -@Generated("by gapic-generator-java") -public class CloudBuildStubSettings extends StubSettings { - /** The default scopes of the service. */ - private static final ImmutableList DEFAULT_SERVICE_SCOPES = - ImmutableList.builder().add("https://www.googleapis.com/auth/cloud-platform").build(); - - private final UnaryCallSettings createBuildSettings; - private final OperationCallSettings - createBuildOperationSettings; - private final UnaryCallSettings getBuildSettings; - private final PagedCallSettings - listBuildsSettings; - private final UnaryCallSettings cancelBuildSettings; - private final UnaryCallSettings retryBuildSettings; - private final OperationCallSettings - retryBuildOperationSettings; - private final UnaryCallSettings approveBuildSettings; - private final OperationCallSettings - approveBuildOperationSettings; - private final UnaryCallSettings - createBuildTriggerSettings; - private final UnaryCallSettings getBuildTriggerSettings; - private final PagedCallSettings< - ListBuildTriggersRequest, ListBuildTriggersResponse, ListBuildTriggersPagedResponse> - listBuildTriggersSettings; - private final UnaryCallSettings deleteBuildTriggerSettings; - private final UnaryCallSettings - updateBuildTriggerSettings; - private final UnaryCallSettings runBuildTriggerSettings; - private final OperationCallSettings - runBuildTriggerOperationSettings; - private final UnaryCallSettings - receiveTriggerWebhookSettings; - private final UnaryCallSettings createWorkerPoolSettings; - private final OperationCallSettings< - CreateWorkerPoolRequest, WorkerPool, CreateWorkerPoolOperationMetadata> - createWorkerPoolOperationSettings; - private final UnaryCallSettings getWorkerPoolSettings; - private final UnaryCallSettings deleteWorkerPoolSettings; - private final OperationCallSettings< - DeleteWorkerPoolRequest, Empty, DeleteWorkerPoolOperationMetadata> - deleteWorkerPoolOperationSettings; - private final UnaryCallSettings updateWorkerPoolSettings; - private final OperationCallSettings< - UpdateWorkerPoolRequest, WorkerPool, UpdateWorkerPoolOperationMetadata> - updateWorkerPoolOperationSettings; - private final PagedCallSettings< - ListWorkerPoolsRequest, ListWorkerPoolsResponse, ListWorkerPoolsPagedResponse> - listWorkerPoolsSettings; - - private static final PagedListDescriptor - LIST_BUILDS_PAGE_STR_DESC = - new PagedListDescriptor() { - @Override - public String emptyToken() { - return ""; - } - - @Override - public ListBuildsRequest injectToken(ListBuildsRequest payload, String token) { - return ListBuildsRequest.newBuilder(payload).setPageToken(token).build(); - } - - @Override - public ListBuildsRequest injectPageSize(ListBuildsRequest payload, int pageSize) { - return ListBuildsRequest.newBuilder(payload).setPageSize(pageSize).build(); - } - - @Override - public Integer extractPageSize(ListBuildsRequest payload) { - return payload.getPageSize(); - } - - @Override - public String extractNextToken(ListBuildsResponse payload) { - return payload.getNextPageToken(); - } - - @Override - public Iterable extractResources(ListBuildsResponse payload) { - return payload.getBuildsList() == null - ? ImmutableList.of() - : payload.getBuildsList(); - } - }; - - private static final PagedListDescriptor< - ListBuildTriggersRequest, ListBuildTriggersResponse, BuildTrigger> - LIST_BUILD_TRIGGERS_PAGE_STR_DESC = - new PagedListDescriptor< - ListBuildTriggersRequest, ListBuildTriggersResponse, BuildTrigger>() { - @Override - public String emptyToken() { - return ""; - } - - @Override - public ListBuildTriggersRequest injectToken( - ListBuildTriggersRequest payload, String token) { - return ListBuildTriggersRequest.newBuilder(payload).setPageToken(token).build(); - } - - @Override - public ListBuildTriggersRequest injectPageSize( - ListBuildTriggersRequest payload, int pageSize) { - return ListBuildTriggersRequest.newBuilder(payload).setPageSize(pageSize).build(); - } - - @Override - public Integer extractPageSize(ListBuildTriggersRequest payload) { - return payload.getPageSize(); - } - - @Override - public String extractNextToken(ListBuildTriggersResponse payload) { - return payload.getNextPageToken(); - } - - @Override - public Iterable extractResources(ListBuildTriggersResponse payload) { - return payload.getTriggersList() == null - ? ImmutableList.of() - : payload.getTriggersList(); - } - }; - - private static final PagedListDescriptor< - ListWorkerPoolsRequest, ListWorkerPoolsResponse, WorkerPool> - LIST_WORKER_POOLS_PAGE_STR_DESC = - new PagedListDescriptor() { - @Override - public String emptyToken() { - return ""; - } - - @Override - public ListWorkerPoolsRequest injectToken( - ListWorkerPoolsRequest payload, String token) { - return ListWorkerPoolsRequest.newBuilder(payload).setPageToken(token).build(); - } - - @Override - public ListWorkerPoolsRequest injectPageSize( - ListWorkerPoolsRequest payload, int pageSize) { - return ListWorkerPoolsRequest.newBuilder(payload).setPageSize(pageSize).build(); - } - - @Override - public Integer extractPageSize(ListWorkerPoolsRequest payload) { - return payload.getPageSize(); - } - - @Override - public String extractNextToken(ListWorkerPoolsResponse payload) { - return payload.getNextPageToken(); - } - - @Override - public Iterable extractResources(ListWorkerPoolsResponse payload) { - return payload.getWorkerPoolsList() == null - ? ImmutableList.of() - : payload.getWorkerPoolsList(); - } - }; - - private static final PagedListResponseFactory< - ListBuildsRequest, ListBuildsResponse, ListBuildsPagedResponse> - LIST_BUILDS_PAGE_STR_FACT = - new PagedListResponseFactory< - ListBuildsRequest, ListBuildsResponse, ListBuildsPagedResponse>() { - @Override - public ApiFuture getFuturePagedResponse( - UnaryCallable callable, - ListBuildsRequest request, - ApiCallContext context, - ApiFuture futureResponse) { - PageContext pageContext = - PageContext.create(callable, LIST_BUILDS_PAGE_STR_DESC, request, context); - return ListBuildsPagedResponse.createAsync(pageContext, futureResponse); - } - }; - - private static final PagedListResponseFactory< - ListBuildTriggersRequest, ListBuildTriggersResponse, ListBuildTriggersPagedResponse> - LIST_BUILD_TRIGGERS_PAGE_STR_FACT = - new PagedListResponseFactory< - ListBuildTriggersRequest, - ListBuildTriggersResponse, - ListBuildTriggersPagedResponse>() { - @Override - public ApiFuture getFuturePagedResponse( - UnaryCallable callable, - ListBuildTriggersRequest request, - ApiCallContext context, - ApiFuture futureResponse) { - PageContext - pageContext = - PageContext.create( - callable, LIST_BUILD_TRIGGERS_PAGE_STR_DESC, request, context); - return ListBuildTriggersPagedResponse.createAsync(pageContext, futureResponse); - } - }; - - private static final PagedListResponseFactory< - ListWorkerPoolsRequest, ListWorkerPoolsResponse, ListWorkerPoolsPagedResponse> - LIST_WORKER_POOLS_PAGE_STR_FACT = - new PagedListResponseFactory< - ListWorkerPoolsRequest, ListWorkerPoolsResponse, ListWorkerPoolsPagedResponse>() { - @Override - public ApiFuture getFuturePagedResponse( - UnaryCallable callable, - ListWorkerPoolsRequest request, - ApiCallContext context, - ApiFuture futureResponse) { - PageContext pageContext = - PageContext.create(callable, LIST_WORKER_POOLS_PAGE_STR_DESC, request, context); - return ListWorkerPoolsPagedResponse.createAsync(pageContext, futureResponse); - } - }; - - /** Returns the object with the settings used for calls to createBuild. */ - public UnaryCallSettings createBuildSettings() { - return createBuildSettings; - } - - /** Returns the object with the settings used for calls to createBuild. */ - public OperationCallSettings - createBuildOperationSettings() { - return createBuildOperationSettings; - } - - /** Returns the object with the settings used for calls to getBuild. */ - public UnaryCallSettings getBuildSettings() { - return getBuildSettings; - } - - /** Returns the object with the settings used for calls to listBuilds. */ - public PagedCallSettings - listBuildsSettings() { - return listBuildsSettings; - } - - /** Returns the object with the settings used for calls to cancelBuild. */ - public UnaryCallSettings cancelBuildSettings() { - return cancelBuildSettings; - } - - /** Returns the object with the settings used for calls to retryBuild. */ - public UnaryCallSettings retryBuildSettings() { - return retryBuildSettings; - } - - /** Returns the object with the settings used for calls to retryBuild. */ - public OperationCallSettings - retryBuildOperationSettings() { - return retryBuildOperationSettings; - } - - /** Returns the object with the settings used for calls to approveBuild. */ - public UnaryCallSettings approveBuildSettings() { - return approveBuildSettings; - } - - /** Returns the object with the settings used for calls to approveBuild. */ - public OperationCallSettings - approveBuildOperationSettings() { - return approveBuildOperationSettings; - } - - /** Returns the object with the settings used for calls to createBuildTrigger. */ - public UnaryCallSettings createBuildTriggerSettings() { - return createBuildTriggerSettings; - } - - /** Returns the object with the settings used for calls to getBuildTrigger. */ - public UnaryCallSettings getBuildTriggerSettings() { - return getBuildTriggerSettings; - } - - /** Returns the object with the settings used for calls to listBuildTriggers. */ - public PagedCallSettings< - ListBuildTriggersRequest, ListBuildTriggersResponse, ListBuildTriggersPagedResponse> - listBuildTriggersSettings() { - return listBuildTriggersSettings; - } - - /** Returns the object with the settings used for calls to deleteBuildTrigger. */ - public UnaryCallSettings deleteBuildTriggerSettings() { - return deleteBuildTriggerSettings; - } - - /** Returns the object with the settings used for calls to updateBuildTrigger. */ - public UnaryCallSettings updateBuildTriggerSettings() { - return updateBuildTriggerSettings; - } - - /** Returns the object with the settings used for calls to runBuildTrigger. */ - public UnaryCallSettings runBuildTriggerSettings() { - return runBuildTriggerSettings; - } - - /** Returns the object with the settings used for calls to runBuildTrigger. */ - public OperationCallSettings - runBuildTriggerOperationSettings() { - return runBuildTriggerOperationSettings; - } - - /** Returns the object with the settings used for calls to receiveTriggerWebhook. */ - public UnaryCallSettings - receiveTriggerWebhookSettings() { - return receiveTriggerWebhookSettings; - } - - /** Returns the object with the settings used for calls to createWorkerPool. */ - public UnaryCallSettings createWorkerPoolSettings() { - return createWorkerPoolSettings; - } - - /** Returns the object with the settings used for calls to createWorkerPool. */ - public OperationCallSettings< - CreateWorkerPoolRequest, WorkerPool, CreateWorkerPoolOperationMetadata> - createWorkerPoolOperationSettings() { - return createWorkerPoolOperationSettings; - } - - /** Returns the object with the settings used for calls to getWorkerPool. */ - public UnaryCallSettings getWorkerPoolSettings() { - return getWorkerPoolSettings; - } - - /** Returns the object with the settings used for calls to deleteWorkerPool. */ - public UnaryCallSettings deleteWorkerPoolSettings() { - return deleteWorkerPoolSettings; - } - - /** Returns the object with the settings used for calls to deleteWorkerPool. */ - public OperationCallSettings - deleteWorkerPoolOperationSettings() { - return deleteWorkerPoolOperationSettings; - } - - /** Returns the object with the settings used for calls to updateWorkerPool. */ - public UnaryCallSettings updateWorkerPoolSettings() { - return updateWorkerPoolSettings; - } - - /** Returns the object with the settings used for calls to updateWorkerPool. */ - public OperationCallSettings< - UpdateWorkerPoolRequest, WorkerPool, UpdateWorkerPoolOperationMetadata> - updateWorkerPoolOperationSettings() { - return updateWorkerPoolOperationSettings; - } - - /** Returns the object with the settings used for calls to listWorkerPools. */ - public PagedCallSettings< - ListWorkerPoolsRequest, ListWorkerPoolsResponse, ListWorkerPoolsPagedResponse> - listWorkerPoolsSettings() { - return listWorkerPoolsSettings; - } - - public CloudBuildStub createStub() throws IOException { - if (getTransportChannelProvider() - .getTransportName() - .equals(GrpcTransportChannel.getGrpcTransportName())) { - return GrpcCloudBuildStub.create(this); - } - if (getTransportChannelProvider() - .getTransportName() - .equals(HttpJsonTransportChannel.getHttpJsonTransportName())) { - return HttpJsonCloudBuildStub.create(this); - } - throw new UnsupportedOperationException( - String.format( - "Transport not supported: %s", getTransportChannelProvider().getTransportName())); - } - - /** Returns a builder for the default ExecutorProvider for this service. */ - public static InstantiatingExecutorProvider.Builder defaultExecutorProviderBuilder() { - return InstantiatingExecutorProvider.newBuilder(); - } - - /** Returns the default service endpoint. */ - public static String getDefaultEndpoint() { - return "cloudbuild.googleapis.com:443"; - } - - /** Returns the default mTLS service endpoint. */ - public static String getDefaultMtlsEndpoint() { - return "cloudbuild.mtls.googleapis.com:443"; - } - - /** Returns the default service scopes. */ - public static List getDefaultServiceScopes() { - return DEFAULT_SERVICE_SCOPES; - } - - /** Returns a builder for the default credentials for this service. */ - public static GoogleCredentialsProvider.Builder defaultCredentialsProviderBuilder() { - return GoogleCredentialsProvider.newBuilder() - .setScopesToApply(DEFAULT_SERVICE_SCOPES) - .setUseJwtAccessWithScope(true); - } - - /** Returns a builder for the default gRPC ChannelProvider for this service. */ - public static InstantiatingGrpcChannelProvider.Builder defaultGrpcTransportProviderBuilder() { - return InstantiatingGrpcChannelProvider.newBuilder() - .setMaxInboundMessageSize(Integer.MAX_VALUE); - } - - /** Returns a builder for the default REST ChannelProvider for this service. */ - @BetaApi - public static InstantiatingHttpJsonChannelProvider.Builder - defaultHttpJsonTransportProviderBuilder() { - return InstantiatingHttpJsonChannelProvider.newBuilder(); - } - - public static TransportChannelProvider defaultTransportChannelProvider() { - return defaultGrpcTransportProviderBuilder().build(); - } - - @BetaApi("The surface for customizing headers is not stable yet and may change in the future.") - public static ApiClientHeaderProvider.Builder defaultGrpcApiClientHeaderProviderBuilder() { - return ApiClientHeaderProvider.newBuilder() - .setGeneratedLibToken( - "gapic", GaxProperties.getLibraryVersion(CloudBuildStubSettings.class)) - .setTransportToken( - GaxGrpcProperties.getGrpcTokenName(), GaxGrpcProperties.getGrpcVersion()); - } - - @BetaApi("The surface for customizing headers is not stable yet and may change in the future.") - public static ApiClientHeaderProvider.Builder defaultHttpJsonApiClientHeaderProviderBuilder() { - return ApiClientHeaderProvider.newBuilder() - .setGeneratedLibToken( - "gapic", GaxProperties.getLibraryVersion(CloudBuildStubSettings.class)) - .setTransportToken( - GaxHttpJsonProperties.getHttpJsonTokenName(), - GaxHttpJsonProperties.getHttpJsonVersion()); - } - - public static ApiClientHeaderProvider.Builder defaultApiClientHeaderProviderBuilder() { - return CloudBuildStubSettings.defaultGrpcApiClientHeaderProviderBuilder(); - } - - /** Returns a new gRPC builder for this class. */ - public static Builder newBuilder() { - return Builder.createDefault(); - } - - /** Returns a new REST builder for this class. */ - public static Builder newHttpJsonBuilder() { - return Builder.createHttpJsonDefault(); - } - - /** Returns a new builder for this class. */ - public static Builder newBuilder(ClientContext clientContext) { - return new Builder(clientContext); - } - - /** Returns a builder containing all the values of this settings class. */ - public Builder toBuilder() { - return new Builder(this); - } - - protected CloudBuildStubSettings(Builder settingsBuilder) throws IOException { - super(settingsBuilder); - - createBuildSettings = settingsBuilder.createBuildSettings().build(); - createBuildOperationSettings = settingsBuilder.createBuildOperationSettings().build(); - getBuildSettings = settingsBuilder.getBuildSettings().build(); - listBuildsSettings = settingsBuilder.listBuildsSettings().build(); - cancelBuildSettings = settingsBuilder.cancelBuildSettings().build(); - retryBuildSettings = settingsBuilder.retryBuildSettings().build(); - retryBuildOperationSettings = settingsBuilder.retryBuildOperationSettings().build(); - approveBuildSettings = settingsBuilder.approveBuildSettings().build(); - approveBuildOperationSettings = settingsBuilder.approveBuildOperationSettings().build(); - createBuildTriggerSettings = settingsBuilder.createBuildTriggerSettings().build(); - getBuildTriggerSettings = settingsBuilder.getBuildTriggerSettings().build(); - listBuildTriggersSettings = settingsBuilder.listBuildTriggersSettings().build(); - deleteBuildTriggerSettings = settingsBuilder.deleteBuildTriggerSettings().build(); - updateBuildTriggerSettings = settingsBuilder.updateBuildTriggerSettings().build(); - runBuildTriggerSettings = settingsBuilder.runBuildTriggerSettings().build(); - runBuildTriggerOperationSettings = settingsBuilder.runBuildTriggerOperationSettings().build(); - receiveTriggerWebhookSettings = settingsBuilder.receiveTriggerWebhookSettings().build(); - createWorkerPoolSettings = settingsBuilder.createWorkerPoolSettings().build(); - createWorkerPoolOperationSettings = settingsBuilder.createWorkerPoolOperationSettings().build(); - getWorkerPoolSettings = settingsBuilder.getWorkerPoolSettings().build(); - deleteWorkerPoolSettings = settingsBuilder.deleteWorkerPoolSettings().build(); - deleteWorkerPoolOperationSettings = settingsBuilder.deleteWorkerPoolOperationSettings().build(); - updateWorkerPoolSettings = settingsBuilder.updateWorkerPoolSettings().build(); - updateWorkerPoolOperationSettings = settingsBuilder.updateWorkerPoolOperationSettings().build(); - listWorkerPoolsSettings = settingsBuilder.listWorkerPoolsSettings().build(); - } - - /** Builder for CloudBuildStubSettings. */ - public static class Builder extends StubSettings.Builder { - private final ImmutableList> unaryMethodSettingsBuilders; - private final UnaryCallSettings.Builder createBuildSettings; - private final OperationCallSettings.Builder - createBuildOperationSettings; - private final UnaryCallSettings.Builder getBuildSettings; - private final PagedCallSettings.Builder< - ListBuildsRequest, ListBuildsResponse, ListBuildsPagedResponse> - listBuildsSettings; - private final UnaryCallSettings.Builder cancelBuildSettings; - private final UnaryCallSettings.Builder retryBuildSettings; - private final OperationCallSettings.Builder - retryBuildOperationSettings; - private final UnaryCallSettings.Builder approveBuildSettings; - private final OperationCallSettings.Builder - approveBuildOperationSettings; - private final UnaryCallSettings.Builder - createBuildTriggerSettings; - private final UnaryCallSettings.Builder - getBuildTriggerSettings; - private final PagedCallSettings.Builder< - ListBuildTriggersRequest, ListBuildTriggersResponse, ListBuildTriggersPagedResponse> - listBuildTriggersSettings; - private final UnaryCallSettings.Builder - deleteBuildTriggerSettings; - private final UnaryCallSettings.Builder - updateBuildTriggerSettings; - private final UnaryCallSettings.Builder - runBuildTriggerSettings; - private final OperationCallSettings.Builder< - RunBuildTriggerRequest, Build, BuildOperationMetadata> - runBuildTriggerOperationSettings; - private final UnaryCallSettings.Builder< - ReceiveTriggerWebhookRequest, ReceiveTriggerWebhookResponse> - receiveTriggerWebhookSettings; - private final UnaryCallSettings.Builder - createWorkerPoolSettings; - private final OperationCallSettings.Builder< - CreateWorkerPoolRequest, WorkerPool, CreateWorkerPoolOperationMetadata> - createWorkerPoolOperationSettings; - private final UnaryCallSettings.Builder getWorkerPoolSettings; - private final UnaryCallSettings.Builder - deleteWorkerPoolSettings; - private final OperationCallSettings.Builder< - DeleteWorkerPoolRequest, Empty, DeleteWorkerPoolOperationMetadata> - deleteWorkerPoolOperationSettings; - private final UnaryCallSettings.Builder - updateWorkerPoolSettings; - private final OperationCallSettings.Builder< - UpdateWorkerPoolRequest, WorkerPool, UpdateWorkerPoolOperationMetadata> - updateWorkerPoolOperationSettings; - private final PagedCallSettings.Builder< - ListWorkerPoolsRequest, ListWorkerPoolsResponse, ListWorkerPoolsPagedResponse> - listWorkerPoolsSettings; - private static final ImmutableMap> - RETRYABLE_CODE_DEFINITIONS; - - static { - ImmutableMap.Builder> definitions = - ImmutableMap.builder(); - definitions.put( - "no_retry_1_codes", ImmutableSet.copyOf(Lists.newArrayList())); - definitions.put( - "retry_policy_0_codes", - ImmutableSet.copyOf( - Lists.newArrayList( - StatusCode.Code.UNAVAILABLE, StatusCode.Code.DEADLINE_EXCEEDED))); - definitions.put("no_retry_codes", ImmutableSet.copyOf(Lists.newArrayList())); - RETRYABLE_CODE_DEFINITIONS = definitions.build(); - } - - private static final ImmutableMap RETRY_PARAM_DEFINITIONS; - - static { - ImmutableMap.Builder definitions = ImmutableMap.builder(); - RetrySettings settings = null; - settings = - RetrySettings.newBuilder() - .setInitialRpcTimeout(Duration.ofMillis(600000L)) - .setRpcTimeoutMultiplier(1.0) - .setMaxRpcTimeout(Duration.ofMillis(600000L)) - .setTotalTimeout(Duration.ofMillis(600000L)) - .build(); - definitions.put("no_retry_1_params", settings); - settings = - RetrySettings.newBuilder() - .setInitialRetryDelay(Duration.ofMillis(100L)) - .setRetryDelayMultiplier(1.3) - .setMaxRetryDelay(Duration.ofMillis(60000L)) - .setInitialRpcTimeout(Duration.ofMillis(600000L)) - .setRpcTimeoutMultiplier(1.0) - .setMaxRpcTimeout(Duration.ofMillis(600000L)) - .setTotalTimeout(Duration.ofMillis(600000L)) - .build(); - definitions.put("retry_policy_0_params", settings); - settings = RetrySettings.newBuilder().setRpcTimeoutMultiplier(1.0).build(); - definitions.put("no_retry_params", settings); - RETRY_PARAM_DEFINITIONS = definitions.build(); - } - - protected Builder() { - this(((ClientContext) null)); - } - - protected Builder(ClientContext clientContext) { - super(clientContext); - - createBuildSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); - createBuildOperationSettings = OperationCallSettings.newBuilder(); - getBuildSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); - listBuildsSettings = PagedCallSettings.newBuilder(LIST_BUILDS_PAGE_STR_FACT); - cancelBuildSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); - retryBuildSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); - retryBuildOperationSettings = OperationCallSettings.newBuilder(); - approveBuildSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); - approveBuildOperationSettings = OperationCallSettings.newBuilder(); - createBuildTriggerSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); - getBuildTriggerSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); - listBuildTriggersSettings = PagedCallSettings.newBuilder(LIST_BUILD_TRIGGERS_PAGE_STR_FACT); - deleteBuildTriggerSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); - updateBuildTriggerSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); - runBuildTriggerSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); - runBuildTriggerOperationSettings = OperationCallSettings.newBuilder(); - receiveTriggerWebhookSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); - createWorkerPoolSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); - createWorkerPoolOperationSettings = OperationCallSettings.newBuilder(); - getWorkerPoolSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); - deleteWorkerPoolSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); - deleteWorkerPoolOperationSettings = OperationCallSettings.newBuilder(); - updateWorkerPoolSettings = UnaryCallSettings.newUnaryCallSettingsBuilder(); - updateWorkerPoolOperationSettings = OperationCallSettings.newBuilder(); - listWorkerPoolsSettings = PagedCallSettings.newBuilder(LIST_WORKER_POOLS_PAGE_STR_FACT); - - unaryMethodSettingsBuilders = - ImmutableList.>of( - createBuildSettings, - getBuildSettings, - listBuildsSettings, - cancelBuildSettings, - retryBuildSettings, - approveBuildSettings, - createBuildTriggerSettings, - getBuildTriggerSettings, - listBuildTriggersSettings, - deleteBuildTriggerSettings, - updateBuildTriggerSettings, - runBuildTriggerSettings, - receiveTriggerWebhookSettings, - createWorkerPoolSettings, - getWorkerPoolSettings, - deleteWorkerPoolSettings, - updateWorkerPoolSettings, - listWorkerPoolsSettings); - initDefaults(this); - } - - protected Builder(CloudBuildStubSettings settings) { - super(settings); - - createBuildSettings = settings.createBuildSettings.toBuilder(); - createBuildOperationSettings = settings.createBuildOperationSettings.toBuilder(); - getBuildSettings = settings.getBuildSettings.toBuilder(); - listBuildsSettings = settings.listBuildsSettings.toBuilder(); - cancelBuildSettings = settings.cancelBuildSettings.toBuilder(); - retryBuildSettings = settings.retryBuildSettings.toBuilder(); - retryBuildOperationSettings = settings.retryBuildOperationSettings.toBuilder(); - approveBuildSettings = settings.approveBuildSettings.toBuilder(); - approveBuildOperationSettings = settings.approveBuildOperationSettings.toBuilder(); - createBuildTriggerSettings = settings.createBuildTriggerSettings.toBuilder(); - getBuildTriggerSettings = settings.getBuildTriggerSettings.toBuilder(); - listBuildTriggersSettings = settings.listBuildTriggersSettings.toBuilder(); - deleteBuildTriggerSettings = settings.deleteBuildTriggerSettings.toBuilder(); - updateBuildTriggerSettings = settings.updateBuildTriggerSettings.toBuilder(); - runBuildTriggerSettings = settings.runBuildTriggerSettings.toBuilder(); - runBuildTriggerOperationSettings = settings.runBuildTriggerOperationSettings.toBuilder(); - receiveTriggerWebhookSettings = settings.receiveTriggerWebhookSettings.toBuilder(); - createWorkerPoolSettings = settings.createWorkerPoolSettings.toBuilder(); - createWorkerPoolOperationSettings = settings.createWorkerPoolOperationSettings.toBuilder(); - getWorkerPoolSettings = settings.getWorkerPoolSettings.toBuilder(); - deleteWorkerPoolSettings = settings.deleteWorkerPoolSettings.toBuilder(); - deleteWorkerPoolOperationSettings = settings.deleteWorkerPoolOperationSettings.toBuilder(); - updateWorkerPoolSettings = settings.updateWorkerPoolSettings.toBuilder(); - updateWorkerPoolOperationSettings = settings.updateWorkerPoolOperationSettings.toBuilder(); - listWorkerPoolsSettings = settings.listWorkerPoolsSettings.toBuilder(); - - unaryMethodSettingsBuilders = - ImmutableList.>of( - createBuildSettings, - getBuildSettings, - listBuildsSettings, - cancelBuildSettings, - retryBuildSettings, - approveBuildSettings, - createBuildTriggerSettings, - getBuildTriggerSettings, - listBuildTriggersSettings, - deleteBuildTriggerSettings, - updateBuildTriggerSettings, - runBuildTriggerSettings, - receiveTriggerWebhookSettings, - createWorkerPoolSettings, - getWorkerPoolSettings, - deleteWorkerPoolSettings, - updateWorkerPoolSettings, - listWorkerPoolsSettings); - } - - private static Builder createDefault() { - Builder builder = new Builder(((ClientContext) null)); - - builder.setTransportChannelProvider(defaultTransportChannelProvider()); - builder.setCredentialsProvider(defaultCredentialsProviderBuilder().build()); - builder.setInternalHeaderProvider(defaultApiClientHeaderProviderBuilder().build()); - builder.setEndpoint(getDefaultEndpoint()); - builder.setMtlsEndpoint(getDefaultMtlsEndpoint()); - builder.setSwitchToMtlsEndpointAllowed(true); - - return initDefaults(builder); - } - - private static Builder createHttpJsonDefault() { - Builder builder = new Builder(((ClientContext) null)); - - builder.setTransportChannelProvider(defaultHttpJsonTransportProviderBuilder().build()); - builder.setCredentialsProvider(defaultCredentialsProviderBuilder().build()); - builder.setInternalHeaderProvider(defaultHttpJsonApiClientHeaderProviderBuilder().build()); - builder.setEndpoint(getDefaultEndpoint()); - builder.setMtlsEndpoint(getDefaultMtlsEndpoint()); - builder.setSwitchToMtlsEndpointAllowed(true); - - return initDefaults(builder); - } - - private static Builder initDefaults(Builder builder) { - builder - .createBuildSettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_1_codes")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_1_params")); - - builder - .getBuildSettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); - - builder - .listBuildsSettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); - - builder - .cancelBuildSettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_1_codes")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_1_params")); - - builder - .retryBuildSettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_1_codes")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_1_params")); - - builder - .approveBuildSettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); - - builder - .createBuildTriggerSettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_1_codes")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_1_params")); - - builder - .getBuildTriggerSettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); - - builder - .listBuildTriggersSettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); - - builder - .deleteBuildTriggerSettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); - - builder - .updateBuildTriggerSettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_1_codes")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_1_params")); - - builder - .runBuildTriggerSettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_1_codes")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_1_params")); - - builder - .receiveTriggerWebhookSettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")); - - builder - .createWorkerPoolSettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_1_codes")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_1_params")); - - builder - .getWorkerPoolSettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); - - builder - .deleteWorkerPoolSettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_1_codes")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_1_params")); - - builder - .updateWorkerPoolSettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_1_codes")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_1_params")); - - builder - .listWorkerPoolsSettings() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("retry_policy_0_codes")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("retry_policy_0_params")); - - builder - .createBuildOperationSettings() - .setInitialCallSettings( - UnaryCallSettings.newUnaryCallSettingsBuilder() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_1_codes")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_1_params")) - .build()) - .setResponseTransformer( - ProtoOperationTransformers.ResponseTransformer.create(Build.class)) - .setMetadataTransformer( - ProtoOperationTransformers.MetadataTransformer.create(BuildOperationMetadata.class)) - .setPollingAlgorithm( - OperationTimedPollAlgorithm.create( - RetrySettings.newBuilder() - .setInitialRetryDelay(Duration.ofMillis(5000L)) - .setRetryDelayMultiplier(1.5) - .setMaxRetryDelay(Duration.ofMillis(45000L)) - .setInitialRpcTimeout(Duration.ZERO) - .setRpcTimeoutMultiplier(1.0) - .setMaxRpcTimeout(Duration.ZERO) - .setTotalTimeout(Duration.ofMillis(300000L)) - .build())); - - builder - .retryBuildOperationSettings() - .setInitialCallSettings( - UnaryCallSettings.newUnaryCallSettingsBuilder() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_1_codes")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_1_params")) - .build()) - .setResponseTransformer( - ProtoOperationTransformers.ResponseTransformer.create(Build.class)) - .setMetadataTransformer( - ProtoOperationTransformers.MetadataTransformer.create(BuildOperationMetadata.class)) - .setPollingAlgorithm( - OperationTimedPollAlgorithm.create( - RetrySettings.newBuilder() - .setInitialRetryDelay(Duration.ofMillis(5000L)) - .setRetryDelayMultiplier(1.5) - .setMaxRetryDelay(Duration.ofMillis(45000L)) - .setInitialRpcTimeout(Duration.ZERO) - .setRpcTimeoutMultiplier(1.0) - .setMaxRpcTimeout(Duration.ZERO) - .setTotalTimeout(Duration.ofMillis(300000L)) - .build())); - - builder - .approveBuildOperationSettings() - .setInitialCallSettings( - UnaryCallSettings - .newUnaryCallSettingsBuilder() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_codes")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_params")) - .build()) - .setResponseTransformer( - ProtoOperationTransformers.ResponseTransformer.create(Build.class)) - .setMetadataTransformer( - ProtoOperationTransformers.MetadataTransformer.create(BuildOperationMetadata.class)) - .setPollingAlgorithm( - OperationTimedPollAlgorithm.create( - RetrySettings.newBuilder() - .setInitialRetryDelay(Duration.ofMillis(5000L)) - .setRetryDelayMultiplier(1.5) - .setMaxRetryDelay(Duration.ofMillis(45000L)) - .setInitialRpcTimeout(Duration.ZERO) - .setRpcTimeoutMultiplier(1.0) - .setMaxRpcTimeout(Duration.ZERO) - .setTotalTimeout(Duration.ofMillis(300000L)) - .build())); - - builder - .runBuildTriggerOperationSettings() - .setInitialCallSettings( - UnaryCallSettings - .newUnaryCallSettingsBuilder() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_1_codes")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_1_params")) - .build()) - .setResponseTransformer( - ProtoOperationTransformers.ResponseTransformer.create(Build.class)) - .setMetadataTransformer( - ProtoOperationTransformers.MetadataTransformer.create(BuildOperationMetadata.class)) - .setPollingAlgorithm( - OperationTimedPollAlgorithm.create( - RetrySettings.newBuilder() - .setInitialRetryDelay(Duration.ofMillis(5000L)) - .setRetryDelayMultiplier(1.5) - .setMaxRetryDelay(Duration.ofMillis(45000L)) - .setInitialRpcTimeout(Duration.ZERO) - .setRpcTimeoutMultiplier(1.0) - .setMaxRpcTimeout(Duration.ZERO) - .setTotalTimeout(Duration.ofMillis(300000L)) - .build())); - - builder - .createWorkerPoolOperationSettings() - .setInitialCallSettings( - UnaryCallSettings - .newUnaryCallSettingsBuilder() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_1_codes")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_1_params")) - .build()) - .setResponseTransformer( - ProtoOperationTransformers.ResponseTransformer.create(WorkerPool.class)) - .setMetadataTransformer( - ProtoOperationTransformers.MetadataTransformer.create( - CreateWorkerPoolOperationMetadata.class)) - .setPollingAlgorithm( - OperationTimedPollAlgorithm.create( - RetrySettings.newBuilder() - .setInitialRetryDelay(Duration.ofMillis(5000L)) - .setRetryDelayMultiplier(1.5) - .setMaxRetryDelay(Duration.ofMillis(45000L)) - .setInitialRpcTimeout(Duration.ZERO) - .setRpcTimeoutMultiplier(1.0) - .setMaxRpcTimeout(Duration.ZERO) - .setTotalTimeout(Duration.ofMillis(300000L)) - .build())); - - builder - .deleteWorkerPoolOperationSettings() - .setInitialCallSettings( - UnaryCallSettings - .newUnaryCallSettingsBuilder() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_1_codes")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_1_params")) - .build()) - .setResponseTransformer( - ProtoOperationTransformers.ResponseTransformer.create(Empty.class)) - .setMetadataTransformer( - ProtoOperationTransformers.MetadataTransformer.create( - DeleteWorkerPoolOperationMetadata.class)) - .setPollingAlgorithm( - OperationTimedPollAlgorithm.create( - RetrySettings.newBuilder() - .setInitialRetryDelay(Duration.ofMillis(5000L)) - .setRetryDelayMultiplier(1.5) - .setMaxRetryDelay(Duration.ofMillis(45000L)) - .setInitialRpcTimeout(Duration.ZERO) - .setRpcTimeoutMultiplier(1.0) - .setMaxRpcTimeout(Duration.ZERO) - .setTotalTimeout(Duration.ofMillis(300000L)) - .build())); - - builder - .updateWorkerPoolOperationSettings() - .setInitialCallSettings( - UnaryCallSettings - .newUnaryCallSettingsBuilder() - .setRetryableCodes(RETRYABLE_CODE_DEFINITIONS.get("no_retry_1_codes")) - .setRetrySettings(RETRY_PARAM_DEFINITIONS.get("no_retry_1_params")) - .build()) - .setResponseTransformer( - ProtoOperationTransformers.ResponseTransformer.create(WorkerPool.class)) - .setMetadataTransformer( - ProtoOperationTransformers.MetadataTransformer.create( - UpdateWorkerPoolOperationMetadata.class)) - .setPollingAlgorithm( - OperationTimedPollAlgorithm.create( - RetrySettings.newBuilder() - .setInitialRetryDelay(Duration.ofMillis(5000L)) - .setRetryDelayMultiplier(1.5) - .setMaxRetryDelay(Duration.ofMillis(45000L)) - .setInitialRpcTimeout(Duration.ZERO) - .setRpcTimeoutMultiplier(1.0) - .setMaxRpcTimeout(Duration.ZERO) - .setTotalTimeout(Duration.ofMillis(300000L)) - .build())); - - return builder; - } - - /** - * Applies the given settings updater function to all of the unary API methods in this service. - * - *

Note: This method does not support applying settings to streaming methods. - */ - public Builder applyToAllUnaryMethods( - ApiFunction, Void> settingsUpdater) { - super.applyToAllUnaryMethods(unaryMethodSettingsBuilders, settingsUpdater); - return this; - } - - public ImmutableList> unaryMethodSettingsBuilders() { - return unaryMethodSettingsBuilders; - } - - /** Returns the builder for the settings used for calls to createBuild. */ - public UnaryCallSettings.Builder createBuildSettings() { - return createBuildSettings; - } - - /** Returns the builder for the settings used for calls to createBuild. */ - @BetaApi( - "The surface for use by generated code is not stable yet and may change in the future.") - public OperationCallSettings.Builder - createBuildOperationSettings() { - return createBuildOperationSettings; - } - - /** Returns the builder for the settings used for calls to getBuild. */ - public UnaryCallSettings.Builder getBuildSettings() { - return getBuildSettings; - } - - /** Returns the builder for the settings used for calls to listBuilds. */ - public PagedCallSettings.Builder - listBuildsSettings() { - return listBuildsSettings; - } - - /** Returns the builder for the settings used for calls to cancelBuild. */ - public UnaryCallSettings.Builder cancelBuildSettings() { - return cancelBuildSettings; - } - - /** Returns the builder for the settings used for calls to retryBuild. */ - public UnaryCallSettings.Builder retryBuildSettings() { - return retryBuildSettings; - } - - /** Returns the builder for the settings used for calls to retryBuild. */ - @BetaApi( - "The surface for use by generated code is not stable yet and may change in the future.") - public OperationCallSettings.Builder - retryBuildOperationSettings() { - return retryBuildOperationSettings; - } - - /** Returns the builder for the settings used for calls to approveBuild. */ - public UnaryCallSettings.Builder approveBuildSettings() { - return approveBuildSettings; - } - - /** Returns the builder for the settings used for calls to approveBuild. */ - @BetaApi( - "The surface for use by generated code is not stable yet and may change in the future.") - public OperationCallSettings.Builder - approveBuildOperationSettings() { - return approveBuildOperationSettings; - } - - /** Returns the builder for the settings used for calls to createBuildTrigger. */ - public UnaryCallSettings.Builder - createBuildTriggerSettings() { - return createBuildTriggerSettings; - } - - /** Returns the builder for the settings used for calls to getBuildTrigger. */ - public UnaryCallSettings.Builder - getBuildTriggerSettings() { - return getBuildTriggerSettings; - } - - /** Returns the builder for the settings used for calls to listBuildTriggers. */ - public PagedCallSettings.Builder< - ListBuildTriggersRequest, ListBuildTriggersResponse, ListBuildTriggersPagedResponse> - listBuildTriggersSettings() { - return listBuildTriggersSettings; - } - - /** Returns the builder for the settings used for calls to deleteBuildTrigger. */ - public UnaryCallSettings.Builder - deleteBuildTriggerSettings() { - return deleteBuildTriggerSettings; - } - - /** Returns the builder for the settings used for calls to updateBuildTrigger. */ - public UnaryCallSettings.Builder - updateBuildTriggerSettings() { - return updateBuildTriggerSettings; - } - - /** Returns the builder for the settings used for calls to runBuildTrigger. */ - public UnaryCallSettings.Builder runBuildTriggerSettings() { - return runBuildTriggerSettings; - } - - /** Returns the builder for the settings used for calls to runBuildTrigger. */ - @BetaApi( - "The surface for use by generated code is not stable yet and may change in the future.") - public OperationCallSettings.Builder - runBuildTriggerOperationSettings() { - return runBuildTriggerOperationSettings; - } - - /** Returns the builder for the settings used for calls to receiveTriggerWebhook. */ - public UnaryCallSettings.Builder - receiveTriggerWebhookSettings() { - return receiveTriggerWebhookSettings; - } - - /** Returns the builder for the settings used for calls to createWorkerPool. */ - public UnaryCallSettings.Builder - createWorkerPoolSettings() { - return createWorkerPoolSettings; - } - - /** Returns the builder for the settings used for calls to createWorkerPool. */ - @BetaApi( - "The surface for use by generated code is not stable yet and may change in the future.") - public OperationCallSettings.Builder< - CreateWorkerPoolRequest, WorkerPool, CreateWorkerPoolOperationMetadata> - createWorkerPoolOperationSettings() { - return createWorkerPoolOperationSettings; - } - - /** Returns the builder for the settings used for calls to getWorkerPool. */ - public UnaryCallSettings.Builder getWorkerPoolSettings() { - return getWorkerPoolSettings; - } - - /** Returns the builder for the settings used for calls to deleteWorkerPool. */ - public UnaryCallSettings.Builder - deleteWorkerPoolSettings() { - return deleteWorkerPoolSettings; - } - - /** Returns the builder for the settings used for calls to deleteWorkerPool. */ - @BetaApi( - "The surface for use by generated code is not stable yet and may change in the future.") - public OperationCallSettings.Builder< - DeleteWorkerPoolRequest, Empty, DeleteWorkerPoolOperationMetadata> - deleteWorkerPoolOperationSettings() { - return deleteWorkerPoolOperationSettings; - } - - /** Returns the builder for the settings used for calls to updateWorkerPool. */ - public UnaryCallSettings.Builder - updateWorkerPoolSettings() { - return updateWorkerPoolSettings; - } - - /** Returns the builder for the settings used for calls to updateWorkerPool. */ - @BetaApi( - "The surface for use by generated code is not stable yet and may change in the future.") - public OperationCallSettings.Builder< - UpdateWorkerPoolRequest, WorkerPool, UpdateWorkerPoolOperationMetadata> - updateWorkerPoolOperationSettings() { - return updateWorkerPoolOperationSettings; - } - - /** Returns the builder for the settings used for calls to listWorkerPools. */ - public PagedCallSettings.Builder< - ListWorkerPoolsRequest, ListWorkerPoolsResponse, ListWorkerPoolsPagedResponse> - listWorkerPoolsSettings() { - return listWorkerPoolsSettings; - } - - @Override - public CloudBuildStubSettings build() throws IOException { - return new CloudBuildStubSettings(this); - } - } -} diff --git a/google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/stub/GrpcCloudBuildCallableFactory.java b/google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/stub/GrpcCloudBuildCallableFactory.java deleted file mode 100644 index 4f35db60..00000000 --- a/google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/stub/GrpcCloudBuildCallableFactory.java +++ /dev/null @@ -1,113 +0,0 @@ -/* - * Copyright 2022 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package com.google.cloud.devtools.cloudbuild.v1.stub; - -import com.google.api.gax.grpc.GrpcCallSettings; -import com.google.api.gax.grpc.GrpcCallableFactory; -import com.google.api.gax.grpc.GrpcStubCallableFactory; -import com.google.api.gax.rpc.BatchingCallSettings; -import com.google.api.gax.rpc.BidiStreamingCallable; -import com.google.api.gax.rpc.ClientContext; -import com.google.api.gax.rpc.ClientStreamingCallable; -import com.google.api.gax.rpc.OperationCallSettings; -import com.google.api.gax.rpc.OperationCallable; -import com.google.api.gax.rpc.PagedCallSettings; -import com.google.api.gax.rpc.ServerStreamingCallSettings; -import com.google.api.gax.rpc.ServerStreamingCallable; -import com.google.api.gax.rpc.StreamingCallSettings; -import com.google.api.gax.rpc.UnaryCallSettings; -import com.google.api.gax.rpc.UnaryCallable; -import com.google.longrunning.Operation; -import com.google.longrunning.stub.OperationsStub; -import javax.annotation.Generated; - -// AUTO-GENERATED DOCUMENTATION AND CLASS. -/** - * gRPC callable factory implementation for the CloudBuild service API. - * - *

This class is for advanced usage. - */ -@Generated("by gapic-generator-java") -public class GrpcCloudBuildCallableFactory implements GrpcStubCallableFactory { - - @Override - public UnaryCallable createUnaryCallable( - GrpcCallSettings grpcCallSettings, - UnaryCallSettings callSettings, - ClientContext clientContext) { - return GrpcCallableFactory.createUnaryCallable(grpcCallSettings, callSettings, clientContext); - } - - @Override - public - UnaryCallable createPagedCallable( - GrpcCallSettings grpcCallSettings, - PagedCallSettings callSettings, - ClientContext clientContext) { - return GrpcCallableFactory.createPagedCallable(grpcCallSettings, callSettings, clientContext); - } - - @Override - public UnaryCallable createBatchingCallable( - GrpcCallSettings grpcCallSettings, - BatchingCallSettings callSettings, - ClientContext clientContext) { - return GrpcCallableFactory.createBatchingCallable( - grpcCallSettings, callSettings, clientContext); - } - - @Override - public - OperationCallable createOperationCallable( - GrpcCallSettings grpcCallSettings, - OperationCallSettings callSettings, - ClientContext clientContext, - OperationsStub operationsStub) { - return GrpcCallableFactory.createOperationCallable( - grpcCallSettings, callSettings, clientContext, operationsStub); - } - - @Override - public - BidiStreamingCallable createBidiStreamingCallable( - GrpcCallSettings grpcCallSettings, - StreamingCallSettings callSettings, - ClientContext clientContext) { - return GrpcCallableFactory.createBidiStreamingCallable( - grpcCallSettings, callSettings, clientContext); - } - - @Override - public - ServerStreamingCallable createServerStreamingCallable( - GrpcCallSettings grpcCallSettings, - ServerStreamingCallSettings callSettings, - ClientContext clientContext) { - return GrpcCallableFactory.createServerStreamingCallable( - grpcCallSettings, callSettings, clientContext); - } - - @Override - public - ClientStreamingCallable createClientStreamingCallable( - GrpcCallSettings grpcCallSettings, - StreamingCallSettings callSettings, - ClientContext clientContext) { - return GrpcCallableFactory.createClientStreamingCallable( - grpcCallSettings, callSettings, clientContext); - } -} diff --git a/google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/stub/GrpcCloudBuildStub.java b/google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/stub/GrpcCloudBuildStub.java deleted file mode 100644 index 8794bbfc..00000000 --- a/google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/stub/GrpcCloudBuildStub.java +++ /dev/null @@ -1,854 +0,0 @@ -/* - * Copyright 2022 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package com.google.cloud.devtools.cloudbuild.v1.stub; - -import static com.google.cloud.devtools.cloudbuild.v1.CloudBuildClient.ListBuildTriggersPagedResponse; -import static com.google.cloud.devtools.cloudbuild.v1.CloudBuildClient.ListBuildsPagedResponse; -import static com.google.cloud.devtools.cloudbuild.v1.CloudBuildClient.ListWorkerPoolsPagedResponse; - -import com.google.api.gax.core.BackgroundResource; -import com.google.api.gax.core.BackgroundResourceAggregation; -import com.google.api.gax.grpc.GrpcCallSettings; -import com.google.api.gax.grpc.GrpcStubCallableFactory; -import com.google.api.gax.rpc.ClientContext; -import com.google.api.gax.rpc.OperationCallable; -import com.google.api.gax.rpc.UnaryCallable; -import com.google.cloudbuild.v1.ApproveBuildRequest; -import com.google.cloudbuild.v1.Build; -import com.google.cloudbuild.v1.BuildOperationMetadata; -import com.google.cloudbuild.v1.BuildTrigger; -import com.google.cloudbuild.v1.CancelBuildRequest; -import com.google.cloudbuild.v1.CreateBuildRequest; -import com.google.cloudbuild.v1.CreateBuildTriggerRequest; -import com.google.cloudbuild.v1.CreateWorkerPoolOperationMetadata; -import com.google.cloudbuild.v1.CreateWorkerPoolRequest; -import com.google.cloudbuild.v1.DeleteBuildTriggerRequest; -import com.google.cloudbuild.v1.DeleteWorkerPoolOperationMetadata; -import com.google.cloudbuild.v1.DeleteWorkerPoolRequest; -import com.google.cloudbuild.v1.GetBuildRequest; -import com.google.cloudbuild.v1.GetBuildTriggerRequest; -import com.google.cloudbuild.v1.GetWorkerPoolRequest; -import com.google.cloudbuild.v1.ListBuildTriggersRequest; -import com.google.cloudbuild.v1.ListBuildTriggersResponse; -import com.google.cloudbuild.v1.ListBuildsRequest; -import com.google.cloudbuild.v1.ListBuildsResponse; -import com.google.cloudbuild.v1.ListWorkerPoolsRequest; -import com.google.cloudbuild.v1.ListWorkerPoolsResponse; -import com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest; -import com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse; -import com.google.cloudbuild.v1.RetryBuildRequest; -import com.google.cloudbuild.v1.RunBuildTriggerRequest; -import com.google.cloudbuild.v1.UpdateBuildTriggerRequest; -import com.google.cloudbuild.v1.UpdateWorkerPoolOperationMetadata; -import com.google.cloudbuild.v1.UpdateWorkerPoolRequest; -import com.google.cloudbuild.v1.WorkerPool; -import com.google.common.collect.ImmutableMap; -import com.google.longrunning.Operation; -import com.google.longrunning.stub.GrpcOperationsStub; -import com.google.protobuf.Empty; -import io.grpc.MethodDescriptor; -import io.grpc.protobuf.ProtoUtils; -import java.io.IOException; -import java.util.concurrent.TimeUnit; -import javax.annotation.Generated; - -// AUTO-GENERATED DOCUMENTATION AND CLASS. -/** - * gRPC stub implementation for the CloudBuild service API. - * - *

This class is for advanced usage and reflects the underlying API directly. - */ -@Generated("by gapic-generator-java") -public class GrpcCloudBuildStub extends CloudBuildStub { - private static final MethodDescriptor createBuildMethodDescriptor = - MethodDescriptor.newBuilder() - .setType(MethodDescriptor.MethodType.UNARY) - .setFullMethodName("google.devtools.cloudbuild.v1.CloudBuild/CreateBuild") - .setRequestMarshaller(ProtoUtils.marshaller(CreateBuildRequest.getDefaultInstance())) - .setResponseMarshaller(ProtoUtils.marshaller(Operation.getDefaultInstance())) - .build(); - - private static final MethodDescriptor getBuildMethodDescriptor = - MethodDescriptor.newBuilder() - .setType(MethodDescriptor.MethodType.UNARY) - .setFullMethodName("google.devtools.cloudbuild.v1.CloudBuild/GetBuild") - .setRequestMarshaller(ProtoUtils.marshaller(GetBuildRequest.getDefaultInstance())) - .setResponseMarshaller(ProtoUtils.marshaller(Build.getDefaultInstance())) - .build(); - - private static final MethodDescriptor - listBuildsMethodDescriptor = - MethodDescriptor.newBuilder() - .setType(MethodDescriptor.MethodType.UNARY) - .setFullMethodName("google.devtools.cloudbuild.v1.CloudBuild/ListBuilds") - .setRequestMarshaller(ProtoUtils.marshaller(ListBuildsRequest.getDefaultInstance())) - .setResponseMarshaller(ProtoUtils.marshaller(ListBuildsResponse.getDefaultInstance())) - .build(); - - private static final MethodDescriptor cancelBuildMethodDescriptor = - MethodDescriptor.newBuilder() - .setType(MethodDescriptor.MethodType.UNARY) - .setFullMethodName("google.devtools.cloudbuild.v1.CloudBuild/CancelBuild") - .setRequestMarshaller(ProtoUtils.marshaller(CancelBuildRequest.getDefaultInstance())) - .setResponseMarshaller(ProtoUtils.marshaller(Build.getDefaultInstance())) - .build(); - - private static final MethodDescriptor retryBuildMethodDescriptor = - MethodDescriptor.newBuilder() - .setType(MethodDescriptor.MethodType.UNARY) - .setFullMethodName("google.devtools.cloudbuild.v1.CloudBuild/RetryBuild") - .setRequestMarshaller(ProtoUtils.marshaller(RetryBuildRequest.getDefaultInstance())) - .setResponseMarshaller(ProtoUtils.marshaller(Operation.getDefaultInstance())) - .build(); - - private static final MethodDescriptor - approveBuildMethodDescriptor = - MethodDescriptor.newBuilder() - .setType(MethodDescriptor.MethodType.UNARY) - .setFullMethodName("google.devtools.cloudbuild.v1.CloudBuild/ApproveBuild") - .setRequestMarshaller(ProtoUtils.marshaller(ApproveBuildRequest.getDefaultInstance())) - .setResponseMarshaller(ProtoUtils.marshaller(Operation.getDefaultInstance())) - .build(); - - private static final MethodDescriptor - createBuildTriggerMethodDescriptor = - MethodDescriptor.newBuilder() - .setType(MethodDescriptor.MethodType.UNARY) - .setFullMethodName("google.devtools.cloudbuild.v1.CloudBuild/CreateBuildTrigger") - .setRequestMarshaller( - ProtoUtils.marshaller(CreateBuildTriggerRequest.getDefaultInstance())) - .setResponseMarshaller(ProtoUtils.marshaller(BuildTrigger.getDefaultInstance())) - .build(); - - private static final MethodDescriptor - getBuildTriggerMethodDescriptor = - MethodDescriptor.newBuilder() - .setType(MethodDescriptor.MethodType.UNARY) - .setFullMethodName("google.devtools.cloudbuild.v1.CloudBuild/GetBuildTrigger") - .setRequestMarshaller( - ProtoUtils.marshaller(GetBuildTriggerRequest.getDefaultInstance())) - .setResponseMarshaller(ProtoUtils.marshaller(BuildTrigger.getDefaultInstance())) - .build(); - - private static final MethodDescriptor - listBuildTriggersMethodDescriptor = - MethodDescriptor.newBuilder() - .setType(MethodDescriptor.MethodType.UNARY) - .setFullMethodName("google.devtools.cloudbuild.v1.CloudBuild/ListBuildTriggers") - .setRequestMarshaller( - ProtoUtils.marshaller(ListBuildTriggersRequest.getDefaultInstance())) - .setResponseMarshaller( - ProtoUtils.marshaller(ListBuildTriggersResponse.getDefaultInstance())) - .build(); - - private static final MethodDescriptor - deleteBuildTriggerMethodDescriptor = - MethodDescriptor.newBuilder() - .setType(MethodDescriptor.MethodType.UNARY) - .setFullMethodName("google.devtools.cloudbuild.v1.CloudBuild/DeleteBuildTrigger") - .setRequestMarshaller( - ProtoUtils.marshaller(DeleteBuildTriggerRequest.getDefaultInstance())) - .setResponseMarshaller(ProtoUtils.marshaller(Empty.getDefaultInstance())) - .build(); - - private static final MethodDescriptor - updateBuildTriggerMethodDescriptor = - MethodDescriptor.newBuilder() - .setType(MethodDescriptor.MethodType.UNARY) - .setFullMethodName("google.devtools.cloudbuild.v1.CloudBuild/UpdateBuildTrigger") - .setRequestMarshaller( - ProtoUtils.marshaller(UpdateBuildTriggerRequest.getDefaultInstance())) - .setResponseMarshaller(ProtoUtils.marshaller(BuildTrigger.getDefaultInstance())) - .build(); - - private static final MethodDescriptor - runBuildTriggerMethodDescriptor = - MethodDescriptor.newBuilder() - .setType(MethodDescriptor.MethodType.UNARY) - .setFullMethodName("google.devtools.cloudbuild.v1.CloudBuild/RunBuildTrigger") - .setRequestMarshaller( - ProtoUtils.marshaller(RunBuildTriggerRequest.getDefaultInstance())) - .setResponseMarshaller(ProtoUtils.marshaller(Operation.getDefaultInstance())) - .build(); - - private static final MethodDescriptor - receiveTriggerWebhookMethodDescriptor = - MethodDescriptor.newBuilder() - .setType(MethodDescriptor.MethodType.UNARY) - .setFullMethodName("google.devtools.cloudbuild.v1.CloudBuild/ReceiveTriggerWebhook") - .setRequestMarshaller( - ProtoUtils.marshaller(ReceiveTriggerWebhookRequest.getDefaultInstance())) - .setResponseMarshaller( - ProtoUtils.marshaller(ReceiveTriggerWebhookResponse.getDefaultInstance())) - .build(); - - private static final MethodDescriptor - createWorkerPoolMethodDescriptor = - MethodDescriptor.newBuilder() - .setType(MethodDescriptor.MethodType.UNARY) - .setFullMethodName("google.devtools.cloudbuild.v1.CloudBuild/CreateWorkerPool") - .setRequestMarshaller( - ProtoUtils.marshaller(CreateWorkerPoolRequest.getDefaultInstance())) - .setResponseMarshaller(ProtoUtils.marshaller(Operation.getDefaultInstance())) - .build(); - - private static final MethodDescriptor - getWorkerPoolMethodDescriptor = - MethodDescriptor.newBuilder() - .setType(MethodDescriptor.MethodType.UNARY) - .setFullMethodName("google.devtools.cloudbuild.v1.CloudBuild/GetWorkerPool") - .setRequestMarshaller( - ProtoUtils.marshaller(GetWorkerPoolRequest.getDefaultInstance())) - .setResponseMarshaller(ProtoUtils.marshaller(WorkerPool.getDefaultInstance())) - .build(); - - private static final MethodDescriptor - deleteWorkerPoolMethodDescriptor = - MethodDescriptor.newBuilder() - .setType(MethodDescriptor.MethodType.UNARY) - .setFullMethodName("google.devtools.cloudbuild.v1.CloudBuild/DeleteWorkerPool") - .setRequestMarshaller( - ProtoUtils.marshaller(DeleteWorkerPoolRequest.getDefaultInstance())) - .setResponseMarshaller(ProtoUtils.marshaller(Operation.getDefaultInstance())) - .build(); - - private static final MethodDescriptor - updateWorkerPoolMethodDescriptor = - MethodDescriptor.newBuilder() - .setType(MethodDescriptor.MethodType.UNARY) - .setFullMethodName("google.devtools.cloudbuild.v1.CloudBuild/UpdateWorkerPool") - .setRequestMarshaller( - ProtoUtils.marshaller(UpdateWorkerPoolRequest.getDefaultInstance())) - .setResponseMarshaller(ProtoUtils.marshaller(Operation.getDefaultInstance())) - .build(); - - private static final MethodDescriptor - listWorkerPoolsMethodDescriptor = - MethodDescriptor.newBuilder() - .setType(MethodDescriptor.MethodType.UNARY) - .setFullMethodName("google.devtools.cloudbuild.v1.CloudBuild/ListWorkerPools") - .setRequestMarshaller( - ProtoUtils.marshaller(ListWorkerPoolsRequest.getDefaultInstance())) - .setResponseMarshaller( - ProtoUtils.marshaller(ListWorkerPoolsResponse.getDefaultInstance())) - .build(); - - private final UnaryCallable createBuildCallable; - private final OperationCallable - createBuildOperationCallable; - private final UnaryCallable getBuildCallable; - private final UnaryCallable listBuildsCallable; - private final UnaryCallable listBuildsPagedCallable; - private final UnaryCallable cancelBuildCallable; - private final UnaryCallable retryBuildCallable; - private final OperationCallable - retryBuildOperationCallable; - private final UnaryCallable approveBuildCallable; - private final OperationCallable - approveBuildOperationCallable; - private final UnaryCallable createBuildTriggerCallable; - private final UnaryCallable getBuildTriggerCallable; - private final UnaryCallable - listBuildTriggersCallable; - private final UnaryCallable - listBuildTriggersPagedCallable; - private final UnaryCallable deleteBuildTriggerCallable; - private final UnaryCallable updateBuildTriggerCallable; - private final UnaryCallable runBuildTriggerCallable; - private final OperationCallable - runBuildTriggerOperationCallable; - private final UnaryCallable - receiveTriggerWebhookCallable; - private final UnaryCallable createWorkerPoolCallable; - private final OperationCallable< - CreateWorkerPoolRequest, WorkerPool, CreateWorkerPoolOperationMetadata> - createWorkerPoolOperationCallable; - private final UnaryCallable getWorkerPoolCallable; - private final UnaryCallable deleteWorkerPoolCallable; - private final OperationCallable - deleteWorkerPoolOperationCallable; - private final UnaryCallable updateWorkerPoolCallable; - private final OperationCallable< - UpdateWorkerPoolRequest, WorkerPool, UpdateWorkerPoolOperationMetadata> - updateWorkerPoolOperationCallable; - private final UnaryCallable - listWorkerPoolsCallable; - private final UnaryCallable - listWorkerPoolsPagedCallable; - - private final BackgroundResource backgroundResources; - private final GrpcOperationsStub operationsStub; - private final GrpcStubCallableFactory callableFactory; - - public static final GrpcCloudBuildStub create(CloudBuildStubSettings settings) - throws IOException { - return new GrpcCloudBuildStub(settings, ClientContext.create(settings)); - } - - public static final GrpcCloudBuildStub create(ClientContext clientContext) throws IOException { - return new GrpcCloudBuildStub(CloudBuildStubSettings.newBuilder().build(), clientContext); - } - - public static final GrpcCloudBuildStub create( - ClientContext clientContext, GrpcStubCallableFactory callableFactory) throws IOException { - return new GrpcCloudBuildStub( - CloudBuildStubSettings.newBuilder().build(), clientContext, callableFactory); - } - - /** - * Constructs an instance of GrpcCloudBuildStub, using the given settings. This is protected so - * that it is easy to make a subclass, but otherwise, the static factory methods should be - * preferred. - */ - protected GrpcCloudBuildStub(CloudBuildStubSettings settings, ClientContext clientContext) - throws IOException { - this(settings, clientContext, new GrpcCloudBuildCallableFactory()); - } - - /** - * Constructs an instance of GrpcCloudBuildStub, using the given settings. This is protected so - * that it is easy to make a subclass, but otherwise, the static factory methods should be - * preferred. - */ - protected GrpcCloudBuildStub( - CloudBuildStubSettings settings, - ClientContext clientContext, - GrpcStubCallableFactory callableFactory) - throws IOException { - this.callableFactory = callableFactory; - this.operationsStub = GrpcOperationsStub.create(clientContext, callableFactory); - - GrpcCallSettings createBuildTransportSettings = - GrpcCallSettings.newBuilder() - .setMethodDescriptor(createBuildMethodDescriptor) - .setParamsExtractor( - request -> { - ImmutableMap.Builder params = ImmutableMap.builder(); - params.put("parent", String.valueOf(request.getParent())); - params.put("project_id", String.valueOf(request.getProjectId())); - return params.build(); - }) - .build(); - GrpcCallSettings getBuildTransportSettings = - GrpcCallSettings.newBuilder() - .setMethodDescriptor(getBuildMethodDescriptor) - .setParamsExtractor( - request -> { - ImmutableMap.Builder params = ImmutableMap.builder(); - params.put("id", String.valueOf(request.getId())); - params.put("name", String.valueOf(request.getName())); - params.put("project_id", String.valueOf(request.getProjectId())); - return params.build(); - }) - .build(); - GrpcCallSettings listBuildsTransportSettings = - GrpcCallSettings.newBuilder() - .setMethodDescriptor(listBuildsMethodDescriptor) - .setParamsExtractor( - request -> { - ImmutableMap.Builder params = ImmutableMap.builder(); - params.put("parent", String.valueOf(request.getParent())); - params.put("project_id", String.valueOf(request.getProjectId())); - return params.build(); - }) - .build(); - GrpcCallSettings cancelBuildTransportSettings = - GrpcCallSettings.newBuilder() - .setMethodDescriptor(cancelBuildMethodDescriptor) - .setParamsExtractor( - request -> { - ImmutableMap.Builder params = ImmutableMap.builder(); - params.put("id", String.valueOf(request.getId())); - params.put("name", String.valueOf(request.getName())); - params.put("project_id", String.valueOf(request.getProjectId())); - return params.build(); - }) - .build(); - GrpcCallSettings retryBuildTransportSettings = - GrpcCallSettings.newBuilder() - .setMethodDescriptor(retryBuildMethodDescriptor) - .setParamsExtractor( - request -> { - ImmutableMap.Builder params = ImmutableMap.builder(); - params.put("id", String.valueOf(request.getId())); - params.put("name", String.valueOf(request.getName())); - params.put("project_id", String.valueOf(request.getProjectId())); - return params.build(); - }) - .build(); - GrpcCallSettings approveBuildTransportSettings = - GrpcCallSettings.newBuilder() - .setMethodDescriptor(approveBuildMethodDescriptor) - .setParamsExtractor( - request -> { - ImmutableMap.Builder params = ImmutableMap.builder(); - params.put("name", String.valueOf(request.getName())); - return params.build(); - }) - .build(); - GrpcCallSettings createBuildTriggerTransportSettings = - GrpcCallSettings.newBuilder() - .setMethodDescriptor(createBuildTriggerMethodDescriptor) - .setParamsExtractor( - request -> { - ImmutableMap.Builder params = ImmutableMap.builder(); - params.put("parent", String.valueOf(request.getParent())); - params.put("project_id", String.valueOf(request.getProjectId())); - return params.build(); - }) - .build(); - GrpcCallSettings getBuildTriggerTransportSettings = - GrpcCallSettings.newBuilder() - .setMethodDescriptor(getBuildTriggerMethodDescriptor) - .setParamsExtractor( - request -> { - ImmutableMap.Builder params = ImmutableMap.builder(); - params.put("name", String.valueOf(request.getName())); - params.put("project_id", String.valueOf(request.getProjectId())); - params.put("trigger_id", String.valueOf(request.getTriggerId())); - return params.build(); - }) - .build(); - GrpcCallSettings - listBuildTriggersTransportSettings = - GrpcCallSettings.newBuilder() - .setMethodDescriptor(listBuildTriggersMethodDescriptor) - .setParamsExtractor( - request -> { - ImmutableMap.Builder params = ImmutableMap.builder(); - params.put("parent", String.valueOf(request.getParent())); - params.put("project_id", String.valueOf(request.getProjectId())); - return params.build(); - }) - .build(); - GrpcCallSettings deleteBuildTriggerTransportSettings = - GrpcCallSettings.newBuilder() - .setMethodDescriptor(deleteBuildTriggerMethodDescriptor) - .setParamsExtractor( - request -> { - ImmutableMap.Builder params = ImmutableMap.builder(); - params.put("name", String.valueOf(request.getName())); - params.put("project_id", String.valueOf(request.getProjectId())); - params.put("trigger_id", String.valueOf(request.getTriggerId())); - return params.build(); - }) - .build(); - GrpcCallSettings updateBuildTriggerTransportSettings = - GrpcCallSettings.newBuilder() - .setMethodDescriptor(updateBuildTriggerMethodDescriptor) - .setParamsExtractor( - request -> { - ImmutableMap.Builder params = ImmutableMap.builder(); - params.put("project_id", String.valueOf(request.getProjectId())); - params.put( - "trigger.resource_name", - String.valueOf(request.getTrigger().getResourceName())); - params.put("trigger_id", String.valueOf(request.getTriggerId())); - return params.build(); - }) - .build(); - GrpcCallSettings runBuildTriggerTransportSettings = - GrpcCallSettings.newBuilder() - .setMethodDescriptor(runBuildTriggerMethodDescriptor) - .setParamsExtractor( - request -> { - ImmutableMap.Builder params = ImmutableMap.builder(); - params.put("name", String.valueOf(request.getName())); - params.put("project_id", String.valueOf(request.getProjectId())); - params.put("trigger_id", String.valueOf(request.getTriggerId())); - return params.build(); - }) - .build(); - GrpcCallSettings - receiveTriggerWebhookTransportSettings = - GrpcCallSettings - .newBuilder() - .setMethodDescriptor(receiveTriggerWebhookMethodDescriptor) - .setParamsExtractor( - request -> { - ImmutableMap.Builder params = ImmutableMap.builder(); - params.put("name", String.valueOf(request.getName())); - params.put("project_id", String.valueOf(request.getProjectId())); - params.put("trigger", String.valueOf(request.getTrigger())); - return params.build(); - }) - .build(); - GrpcCallSettings createWorkerPoolTransportSettings = - GrpcCallSettings.newBuilder() - .setMethodDescriptor(createWorkerPoolMethodDescriptor) - .setParamsExtractor( - request -> { - ImmutableMap.Builder params = ImmutableMap.builder(); - params.put("parent", String.valueOf(request.getParent())); - return params.build(); - }) - .build(); - GrpcCallSettings getWorkerPoolTransportSettings = - GrpcCallSettings.newBuilder() - .setMethodDescriptor(getWorkerPoolMethodDescriptor) - .setParamsExtractor( - request -> { - ImmutableMap.Builder params = ImmutableMap.builder(); - params.put("name", String.valueOf(request.getName())); - return params.build(); - }) - .build(); - GrpcCallSettings deleteWorkerPoolTransportSettings = - GrpcCallSettings.newBuilder() - .setMethodDescriptor(deleteWorkerPoolMethodDescriptor) - .setParamsExtractor( - request -> { - ImmutableMap.Builder params = ImmutableMap.builder(); - params.put("name", String.valueOf(request.getName())); - return params.build(); - }) - .build(); - GrpcCallSettings updateWorkerPoolTransportSettings = - GrpcCallSettings.newBuilder() - .setMethodDescriptor(updateWorkerPoolMethodDescriptor) - .setParamsExtractor( - request -> { - ImmutableMap.Builder params = ImmutableMap.builder(); - params.put("worker_pool.name", String.valueOf(request.getWorkerPool().getName())); - return params.build(); - }) - .build(); - GrpcCallSettings - listWorkerPoolsTransportSettings = - GrpcCallSettings.newBuilder() - .setMethodDescriptor(listWorkerPoolsMethodDescriptor) - .setParamsExtractor( - request -> { - ImmutableMap.Builder params = ImmutableMap.builder(); - params.put("parent", String.valueOf(request.getParent())); - return params.build(); - }) - .build(); - - this.createBuildCallable = - callableFactory.createUnaryCallable( - createBuildTransportSettings, settings.createBuildSettings(), clientContext); - this.createBuildOperationCallable = - callableFactory.createOperationCallable( - createBuildTransportSettings, - settings.createBuildOperationSettings(), - clientContext, - operationsStub); - this.getBuildCallable = - callableFactory.createUnaryCallable( - getBuildTransportSettings, settings.getBuildSettings(), clientContext); - this.listBuildsCallable = - callableFactory.createUnaryCallable( - listBuildsTransportSettings, settings.listBuildsSettings(), clientContext); - this.listBuildsPagedCallable = - callableFactory.createPagedCallable( - listBuildsTransportSettings, settings.listBuildsSettings(), clientContext); - this.cancelBuildCallable = - callableFactory.createUnaryCallable( - cancelBuildTransportSettings, settings.cancelBuildSettings(), clientContext); - this.retryBuildCallable = - callableFactory.createUnaryCallable( - retryBuildTransportSettings, settings.retryBuildSettings(), clientContext); - this.retryBuildOperationCallable = - callableFactory.createOperationCallable( - retryBuildTransportSettings, - settings.retryBuildOperationSettings(), - clientContext, - operationsStub); - this.approveBuildCallable = - callableFactory.createUnaryCallable( - approveBuildTransportSettings, settings.approveBuildSettings(), clientContext); - this.approveBuildOperationCallable = - callableFactory.createOperationCallable( - approveBuildTransportSettings, - settings.approveBuildOperationSettings(), - clientContext, - operationsStub); - this.createBuildTriggerCallable = - callableFactory.createUnaryCallable( - createBuildTriggerTransportSettings, - settings.createBuildTriggerSettings(), - clientContext); - this.getBuildTriggerCallable = - callableFactory.createUnaryCallable( - getBuildTriggerTransportSettings, settings.getBuildTriggerSettings(), clientContext); - this.listBuildTriggersCallable = - callableFactory.createUnaryCallable( - listBuildTriggersTransportSettings, - settings.listBuildTriggersSettings(), - clientContext); - this.listBuildTriggersPagedCallable = - callableFactory.createPagedCallable( - listBuildTriggersTransportSettings, - settings.listBuildTriggersSettings(), - clientContext); - this.deleteBuildTriggerCallable = - callableFactory.createUnaryCallable( - deleteBuildTriggerTransportSettings, - settings.deleteBuildTriggerSettings(), - clientContext); - this.updateBuildTriggerCallable = - callableFactory.createUnaryCallable( - updateBuildTriggerTransportSettings, - settings.updateBuildTriggerSettings(), - clientContext); - this.runBuildTriggerCallable = - callableFactory.createUnaryCallable( - runBuildTriggerTransportSettings, settings.runBuildTriggerSettings(), clientContext); - this.runBuildTriggerOperationCallable = - callableFactory.createOperationCallable( - runBuildTriggerTransportSettings, - settings.runBuildTriggerOperationSettings(), - clientContext, - operationsStub); - this.receiveTriggerWebhookCallable = - callableFactory.createUnaryCallable( - receiveTriggerWebhookTransportSettings, - settings.receiveTriggerWebhookSettings(), - clientContext); - this.createWorkerPoolCallable = - callableFactory.createUnaryCallable( - createWorkerPoolTransportSettings, settings.createWorkerPoolSettings(), clientContext); - this.createWorkerPoolOperationCallable = - callableFactory.createOperationCallable( - createWorkerPoolTransportSettings, - settings.createWorkerPoolOperationSettings(), - clientContext, - operationsStub); - this.getWorkerPoolCallable = - callableFactory.createUnaryCallable( - getWorkerPoolTransportSettings, settings.getWorkerPoolSettings(), clientContext); - this.deleteWorkerPoolCallable = - callableFactory.createUnaryCallable( - deleteWorkerPoolTransportSettings, settings.deleteWorkerPoolSettings(), clientContext); - this.deleteWorkerPoolOperationCallable = - callableFactory.createOperationCallable( - deleteWorkerPoolTransportSettings, - settings.deleteWorkerPoolOperationSettings(), - clientContext, - operationsStub); - this.updateWorkerPoolCallable = - callableFactory.createUnaryCallable( - updateWorkerPoolTransportSettings, settings.updateWorkerPoolSettings(), clientContext); - this.updateWorkerPoolOperationCallable = - callableFactory.createOperationCallable( - updateWorkerPoolTransportSettings, - settings.updateWorkerPoolOperationSettings(), - clientContext, - operationsStub); - this.listWorkerPoolsCallable = - callableFactory.createUnaryCallable( - listWorkerPoolsTransportSettings, settings.listWorkerPoolsSettings(), clientContext); - this.listWorkerPoolsPagedCallable = - callableFactory.createPagedCallable( - listWorkerPoolsTransportSettings, settings.listWorkerPoolsSettings(), clientContext); - - this.backgroundResources = - new BackgroundResourceAggregation(clientContext.getBackgroundResources()); - } - - public GrpcOperationsStub getOperationsStub() { - return operationsStub; - } - - @Override - public UnaryCallable createBuildCallable() { - return createBuildCallable; - } - - @Override - public OperationCallable - createBuildOperationCallable() { - return createBuildOperationCallable; - } - - @Override - public UnaryCallable getBuildCallable() { - return getBuildCallable; - } - - @Override - public UnaryCallable listBuildsCallable() { - return listBuildsCallable; - } - - @Override - public UnaryCallable listBuildsPagedCallable() { - return listBuildsPagedCallable; - } - - @Override - public UnaryCallable cancelBuildCallable() { - return cancelBuildCallable; - } - - @Override - public UnaryCallable retryBuildCallable() { - return retryBuildCallable; - } - - @Override - public OperationCallable - retryBuildOperationCallable() { - return retryBuildOperationCallable; - } - - @Override - public UnaryCallable approveBuildCallable() { - return approveBuildCallable; - } - - @Override - public OperationCallable - approveBuildOperationCallable() { - return approveBuildOperationCallable; - } - - @Override - public UnaryCallable createBuildTriggerCallable() { - return createBuildTriggerCallable; - } - - @Override - public UnaryCallable getBuildTriggerCallable() { - return getBuildTriggerCallable; - } - - @Override - public UnaryCallable - listBuildTriggersCallable() { - return listBuildTriggersCallable; - } - - @Override - public UnaryCallable - listBuildTriggersPagedCallable() { - return listBuildTriggersPagedCallable; - } - - @Override - public UnaryCallable deleteBuildTriggerCallable() { - return deleteBuildTriggerCallable; - } - - @Override - public UnaryCallable updateBuildTriggerCallable() { - return updateBuildTriggerCallable; - } - - @Override - public UnaryCallable runBuildTriggerCallable() { - return runBuildTriggerCallable; - } - - @Override - public OperationCallable - runBuildTriggerOperationCallable() { - return runBuildTriggerOperationCallable; - } - - @Override - public UnaryCallable - receiveTriggerWebhookCallable() { - return receiveTriggerWebhookCallable; - } - - @Override - public UnaryCallable createWorkerPoolCallable() { - return createWorkerPoolCallable; - } - - @Override - public OperationCallable - createWorkerPoolOperationCallable() { - return createWorkerPoolOperationCallable; - } - - @Override - public UnaryCallable getWorkerPoolCallable() { - return getWorkerPoolCallable; - } - - @Override - public UnaryCallable deleteWorkerPoolCallable() { - return deleteWorkerPoolCallable; - } - - @Override - public OperationCallable - deleteWorkerPoolOperationCallable() { - return deleteWorkerPoolOperationCallable; - } - - @Override - public UnaryCallable updateWorkerPoolCallable() { - return updateWorkerPoolCallable; - } - - @Override - public OperationCallable - updateWorkerPoolOperationCallable() { - return updateWorkerPoolOperationCallable; - } - - @Override - public UnaryCallable listWorkerPoolsCallable() { - return listWorkerPoolsCallable; - } - - @Override - public UnaryCallable - listWorkerPoolsPagedCallable() { - return listWorkerPoolsPagedCallable; - } - - @Override - public final void close() { - try { - backgroundResources.close(); - } catch (RuntimeException e) { - throw e; - } catch (Exception e) { - throw new IllegalStateException("Failed to close resource", e); - } - } - - @Override - public void shutdown() { - backgroundResources.shutdown(); - } - - @Override - public boolean isShutdown() { - return backgroundResources.isShutdown(); - } - - @Override - public boolean isTerminated() { - return backgroundResources.isTerminated(); - } - - @Override - public void shutdownNow() { - backgroundResources.shutdownNow(); - } - - @Override - public boolean awaitTermination(long duration, TimeUnit unit) throws InterruptedException { - return backgroundResources.awaitTermination(duration, unit); - } -} diff --git a/google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/stub/HttpJsonCloudBuildCallableFactory.java b/google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/stub/HttpJsonCloudBuildCallableFactory.java deleted file mode 100644 index dbf58da0..00000000 --- a/google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/stub/HttpJsonCloudBuildCallableFactory.java +++ /dev/null @@ -1,105 +0,0 @@ -/* - * Copyright 2022 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package com.google.cloud.devtools.cloudbuild.v1.stub; - -import com.google.api.core.BetaApi; -import com.google.api.gax.httpjson.HttpJsonCallSettings; -import com.google.api.gax.httpjson.HttpJsonCallableFactory; -import com.google.api.gax.httpjson.HttpJsonOperationSnapshotCallable; -import com.google.api.gax.httpjson.HttpJsonStubCallableFactory; -import com.google.api.gax.httpjson.longrunning.stub.OperationsStub; -import com.google.api.gax.rpc.BatchingCallSettings; -import com.google.api.gax.rpc.ClientContext; -import com.google.api.gax.rpc.OperationCallSettings; -import com.google.api.gax.rpc.OperationCallable; -import com.google.api.gax.rpc.PagedCallSettings; -import com.google.api.gax.rpc.ServerStreamingCallSettings; -import com.google.api.gax.rpc.ServerStreamingCallable; -import com.google.api.gax.rpc.UnaryCallSettings; -import com.google.api.gax.rpc.UnaryCallable; -import com.google.longrunning.Operation; -import javax.annotation.Generated; - -// AUTO-GENERATED DOCUMENTATION AND CLASS. -/** - * REST callable factory implementation for the CloudBuild service API. - * - *

This class is for advanced usage. - */ -@Generated("by gapic-generator-java") -@BetaApi -public class HttpJsonCloudBuildCallableFactory - implements HttpJsonStubCallableFactory { - - @Override - public UnaryCallable createUnaryCallable( - HttpJsonCallSettings httpJsonCallSettings, - UnaryCallSettings callSettings, - ClientContext clientContext) { - return HttpJsonCallableFactory.createUnaryCallable( - httpJsonCallSettings, callSettings, clientContext); - } - - @Override - public - UnaryCallable createPagedCallable( - HttpJsonCallSettings httpJsonCallSettings, - PagedCallSettings callSettings, - ClientContext clientContext) { - return HttpJsonCallableFactory.createPagedCallable( - httpJsonCallSettings, callSettings, clientContext); - } - - @Override - public UnaryCallable createBatchingCallable( - HttpJsonCallSettings httpJsonCallSettings, - BatchingCallSettings callSettings, - ClientContext clientContext) { - return HttpJsonCallableFactory.createBatchingCallable( - httpJsonCallSettings, callSettings, clientContext); - } - - @BetaApi( - "The surface for long-running operations is not stable yet and may change in the future.") - @Override - public - OperationCallable createOperationCallable( - HttpJsonCallSettings httpJsonCallSettings, - OperationCallSettings callSettings, - ClientContext clientContext, - OperationsStub operationsStub) { - UnaryCallable innerCallable = - HttpJsonCallableFactory.createBaseUnaryCallable( - httpJsonCallSettings, callSettings.getInitialCallSettings(), clientContext); - HttpJsonOperationSnapshotCallable initialCallable = - new HttpJsonOperationSnapshotCallable( - innerCallable, - httpJsonCallSettings.getMethodDescriptor().getOperationSnapshotFactory()); - return HttpJsonCallableFactory.createOperationCallable( - callSettings, clientContext, operationsStub.longRunningClient(), initialCallable); - } - - @Override - public - ServerStreamingCallable createServerStreamingCallable( - HttpJsonCallSettings httpJsonCallSettings, - ServerStreamingCallSettings callSettings, - ClientContext clientContext) { - return HttpJsonCallableFactory.createServerStreamingCallable( - httpJsonCallSettings, callSettings, clientContext); - } -} diff --git a/google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/stub/HttpJsonCloudBuildStub.java b/google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/stub/HttpJsonCloudBuildStub.java deleted file mode 100644 index 9ecc4e78..00000000 --- a/google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/stub/HttpJsonCloudBuildStub.java +++ /dev/null @@ -1,1337 +0,0 @@ -/* - * Copyright 2022 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package com.google.cloud.devtools.cloudbuild.v1.stub; - -import static com.google.cloud.devtools.cloudbuild.v1.CloudBuildClient.ListBuildTriggersPagedResponse; -import static com.google.cloud.devtools.cloudbuild.v1.CloudBuildClient.ListBuildsPagedResponse; -import static com.google.cloud.devtools.cloudbuild.v1.CloudBuildClient.ListWorkerPoolsPagedResponse; - -import com.google.api.core.BetaApi; -import com.google.api.core.InternalApi; -import com.google.api.gax.core.BackgroundResource; -import com.google.api.gax.core.BackgroundResourceAggregation; -import com.google.api.gax.httpjson.ApiMethodDescriptor; -import com.google.api.gax.httpjson.HttpJsonCallSettings; -import com.google.api.gax.httpjson.HttpJsonOperationSnapshot; -import com.google.api.gax.httpjson.HttpJsonStubCallableFactory; -import com.google.api.gax.httpjson.ProtoMessageRequestFormatter; -import com.google.api.gax.httpjson.ProtoMessageResponseParser; -import com.google.api.gax.httpjson.ProtoRestSerializer; -import com.google.api.gax.httpjson.longrunning.stub.HttpJsonOperationsStub; -import com.google.api.gax.rpc.ClientContext; -import com.google.api.gax.rpc.OperationCallable; -import com.google.api.gax.rpc.UnaryCallable; -import com.google.cloudbuild.v1.ApproveBuildRequest; -import com.google.cloudbuild.v1.Build; -import com.google.cloudbuild.v1.BuildOperationMetadata; -import com.google.cloudbuild.v1.BuildTrigger; -import com.google.cloudbuild.v1.CancelBuildRequest; -import com.google.cloudbuild.v1.CreateBuildRequest; -import com.google.cloudbuild.v1.CreateBuildTriggerRequest; -import com.google.cloudbuild.v1.CreateWorkerPoolOperationMetadata; -import com.google.cloudbuild.v1.CreateWorkerPoolRequest; -import com.google.cloudbuild.v1.DeleteBuildTriggerRequest; -import com.google.cloudbuild.v1.DeleteWorkerPoolOperationMetadata; -import com.google.cloudbuild.v1.DeleteWorkerPoolRequest; -import com.google.cloudbuild.v1.GetBuildRequest; -import com.google.cloudbuild.v1.GetBuildTriggerRequest; -import com.google.cloudbuild.v1.GetWorkerPoolRequest; -import com.google.cloudbuild.v1.ListBuildTriggersRequest; -import com.google.cloudbuild.v1.ListBuildTriggersResponse; -import com.google.cloudbuild.v1.ListBuildsRequest; -import com.google.cloudbuild.v1.ListBuildsResponse; -import com.google.cloudbuild.v1.ListWorkerPoolsRequest; -import com.google.cloudbuild.v1.ListWorkerPoolsResponse; -import com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest; -import com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse; -import com.google.cloudbuild.v1.RetryBuildRequest; -import com.google.cloudbuild.v1.RunBuildTriggerRequest; -import com.google.cloudbuild.v1.UpdateBuildTriggerRequest; -import com.google.cloudbuild.v1.UpdateWorkerPoolOperationMetadata; -import com.google.cloudbuild.v1.UpdateWorkerPoolRequest; -import com.google.cloudbuild.v1.WorkerPool; -import com.google.longrunning.Operation; -import com.google.protobuf.Empty; -import com.google.protobuf.TypeRegistry; -import java.io.IOException; -import java.util.ArrayList; -import java.util.HashMap; -import java.util.List; -import java.util.Map; -import java.util.concurrent.TimeUnit; -import javax.annotation.Generated; - -// AUTO-GENERATED DOCUMENTATION AND CLASS. -/** - * REST stub implementation for the CloudBuild service API. - * - *

This class is for advanced usage and reflects the underlying API directly. - */ -@Generated("by gapic-generator-java") -@BetaApi -public class HttpJsonCloudBuildStub extends CloudBuildStub { - private static final TypeRegistry typeRegistry = - TypeRegistry.newBuilder() - .add(Empty.getDescriptor()) - .add(DeleteWorkerPoolOperationMetadata.getDescriptor()) - .add(UpdateWorkerPoolOperationMetadata.getDescriptor()) - .add(Build.getDescriptor()) - .add(WorkerPool.getDescriptor()) - .add(CreateWorkerPoolOperationMetadata.getDescriptor()) - .add(BuildOperationMetadata.getDescriptor()) - .build(); - - private static final ApiMethodDescriptor - createBuildMethodDescriptor = - ApiMethodDescriptor.newBuilder() - .setFullMethodName("google.devtools.cloudbuild.v1.CloudBuild/CreateBuild") - .setHttpMethod("POST") - .setType(ApiMethodDescriptor.MethodType.UNARY) - .setRequestFormatter( - ProtoMessageRequestFormatter.newBuilder() - .setPath( - "/v1/projects/{projectId}/builds", - request -> { - Map fields = new HashMap<>(); - ProtoRestSerializer serializer = - ProtoRestSerializer.create(); - serializer.putPathParam(fields, "parent", request.getParent()); - serializer.putPathParam(fields, "projectId", request.getProjectId()); - return fields; - }) - .setAdditionalPaths("/v1/{parent=projects/*/locations/*}/builds") - .setQueryParamsExtractor( - request -> { - Map> fields = new HashMap<>(); - ProtoRestSerializer serializer = - ProtoRestSerializer.create(); - return fields; - }) - .setRequestBodyExtractor( - request -> - ProtoRestSerializer.create() - .toBody("build", request.getBuild(), false)) - .build()) - .setResponseParser( - ProtoMessageResponseParser.newBuilder() - .setDefaultInstance(Operation.getDefaultInstance()) - .setDefaultTypeRegistry(typeRegistry) - .build()) - .setOperationSnapshotFactory( - (CreateBuildRequest request, Operation response) -> - HttpJsonOperationSnapshot.create(response)) - .build(); - - private static final ApiMethodDescriptor getBuildMethodDescriptor = - ApiMethodDescriptor.newBuilder() - .setFullMethodName("google.devtools.cloudbuild.v1.CloudBuild/GetBuild") - .setHttpMethod("GET") - .setType(ApiMethodDescriptor.MethodType.UNARY) - .setRequestFormatter( - ProtoMessageRequestFormatter.newBuilder() - .setPath( - "/v1/projects/{projectId}/builds/{id}", - request -> { - Map fields = new HashMap<>(); - ProtoRestSerializer serializer = - ProtoRestSerializer.create(); - serializer.putPathParam(fields, "id", request.getId()); - serializer.putPathParam(fields, "name", request.getName()); - serializer.putPathParam(fields, "projectId", request.getProjectId()); - return fields; - }) - .setAdditionalPaths("/v1/{name=projects/*/locations/*/builds/*}") - .setQueryParamsExtractor( - request -> { - Map> fields = new HashMap<>(); - ProtoRestSerializer serializer = - ProtoRestSerializer.create(); - return fields; - }) - .setRequestBodyExtractor(request -> null) - .build()) - .setResponseParser( - ProtoMessageResponseParser.newBuilder() - .setDefaultInstance(Build.getDefaultInstance()) - .setDefaultTypeRegistry(typeRegistry) - .build()) - .build(); - - private static final ApiMethodDescriptor - listBuildsMethodDescriptor = - ApiMethodDescriptor.newBuilder() - .setFullMethodName("google.devtools.cloudbuild.v1.CloudBuild/ListBuilds") - .setHttpMethod("GET") - .setType(ApiMethodDescriptor.MethodType.UNARY) - .setRequestFormatter( - ProtoMessageRequestFormatter.newBuilder() - .setPath( - "/v1/projects/{projectId}/builds", - request -> { - Map fields = new HashMap<>(); - ProtoRestSerializer serializer = - ProtoRestSerializer.create(); - serializer.putPathParam(fields, "parent", request.getParent()); - serializer.putPathParam(fields, "projectId", request.getProjectId()); - return fields; - }) - .setAdditionalPaths("/v1/{parent=projects/*/locations/*}/builds") - .setQueryParamsExtractor( - request -> { - Map> fields = new HashMap<>(); - ProtoRestSerializer serializer = - ProtoRestSerializer.create(); - serializer.putQueryParam(fields, "filter", request.getFilter()); - serializer.putQueryParam(fields, "pageSize", request.getPageSize()); - serializer.putQueryParam(fields, "pageToken", request.getPageToken()); - return fields; - }) - .setRequestBodyExtractor(request -> null) - .build()) - .setResponseParser( - ProtoMessageResponseParser.newBuilder() - .setDefaultInstance(ListBuildsResponse.getDefaultInstance()) - .setDefaultTypeRegistry(typeRegistry) - .build()) - .build(); - - private static final ApiMethodDescriptor cancelBuildMethodDescriptor = - ApiMethodDescriptor.newBuilder() - .setFullMethodName("google.devtools.cloudbuild.v1.CloudBuild/CancelBuild") - .setHttpMethod("POST") - .setType(ApiMethodDescriptor.MethodType.UNARY) - .setRequestFormatter( - ProtoMessageRequestFormatter.newBuilder() - .setPath( - "/v1/projects/{projectId}/builds/{id}:cancel", - request -> { - Map fields = new HashMap<>(); - ProtoRestSerializer serializer = - ProtoRestSerializer.create(); - serializer.putPathParam(fields, "id", request.getId()); - serializer.putPathParam(fields, "name", request.getName()); - serializer.putPathParam(fields, "projectId", request.getProjectId()); - return fields; - }) - .setAdditionalPaths("/v1/{name=projects/*/locations/*/builds/*}:cancel") - .setQueryParamsExtractor( - request -> { - Map> fields = new HashMap<>(); - ProtoRestSerializer serializer = - ProtoRestSerializer.create(); - return fields; - }) - .setRequestBodyExtractor( - request -> - ProtoRestSerializer.create() - .toBody( - "*", - request - .toBuilder() - .clearId() - .clearName() - .clearProjectId() - .build(), - false)) - .build()) - .setResponseParser( - ProtoMessageResponseParser.newBuilder() - .setDefaultInstance(Build.getDefaultInstance()) - .setDefaultTypeRegistry(typeRegistry) - .build()) - .build(); - - private static final ApiMethodDescriptor - retryBuildMethodDescriptor = - ApiMethodDescriptor.newBuilder() - .setFullMethodName("google.devtools.cloudbuild.v1.CloudBuild/RetryBuild") - .setHttpMethod("POST") - .setType(ApiMethodDescriptor.MethodType.UNARY) - .setRequestFormatter( - ProtoMessageRequestFormatter.newBuilder() - .setPath( - "/v1/projects/{projectId}/builds/{id}:retry", - request -> { - Map fields = new HashMap<>(); - ProtoRestSerializer serializer = - ProtoRestSerializer.create(); - serializer.putPathParam(fields, "id", request.getId()); - serializer.putPathParam(fields, "name", request.getName()); - serializer.putPathParam(fields, "projectId", request.getProjectId()); - return fields; - }) - .setAdditionalPaths("/v1/{name=projects/*/locations/*/builds/*}:retry") - .setQueryParamsExtractor( - request -> { - Map> fields = new HashMap<>(); - ProtoRestSerializer serializer = - ProtoRestSerializer.create(); - return fields; - }) - .setRequestBodyExtractor( - request -> - ProtoRestSerializer.create() - .toBody( - "*", - request - .toBuilder() - .clearId() - .clearName() - .clearProjectId() - .build(), - false)) - .build()) - .setResponseParser( - ProtoMessageResponseParser.newBuilder() - .setDefaultInstance(Operation.getDefaultInstance()) - .setDefaultTypeRegistry(typeRegistry) - .build()) - .setOperationSnapshotFactory( - (RetryBuildRequest request, Operation response) -> - HttpJsonOperationSnapshot.create(response)) - .build(); - - private static final ApiMethodDescriptor - approveBuildMethodDescriptor = - ApiMethodDescriptor.newBuilder() - .setFullMethodName("google.devtools.cloudbuild.v1.CloudBuild/ApproveBuild") - .setHttpMethod("POST") - .setType(ApiMethodDescriptor.MethodType.UNARY) - .setRequestFormatter( - ProtoMessageRequestFormatter.newBuilder() - .setPath( - "/v1/{name=projects/*/builds/*}:approve", - request -> { - Map fields = new HashMap<>(); - ProtoRestSerializer serializer = - ProtoRestSerializer.create(); - serializer.putPathParam(fields, "name", request.getName()); - return fields; - }) - .setAdditionalPaths("/v1/{name=projects/*/locations/*/builds/*}:approve") - .setQueryParamsExtractor( - request -> { - Map> fields = new HashMap<>(); - ProtoRestSerializer serializer = - ProtoRestSerializer.create(); - return fields; - }) - .setRequestBodyExtractor( - request -> - ProtoRestSerializer.create() - .toBody("*", request.toBuilder().clearName().build(), false)) - .build()) - .setResponseParser( - ProtoMessageResponseParser.newBuilder() - .setDefaultInstance(Operation.getDefaultInstance()) - .setDefaultTypeRegistry(typeRegistry) - .build()) - .setOperationSnapshotFactory( - (ApproveBuildRequest request, Operation response) -> - HttpJsonOperationSnapshot.create(response)) - .build(); - - private static final ApiMethodDescriptor - createBuildTriggerMethodDescriptor = - ApiMethodDescriptor.newBuilder() - .setFullMethodName("google.devtools.cloudbuild.v1.CloudBuild/CreateBuildTrigger") - .setHttpMethod("POST") - .setType(ApiMethodDescriptor.MethodType.UNARY) - .setRequestFormatter( - ProtoMessageRequestFormatter.newBuilder() - .setPath( - "/v1/projects/{projectId}/triggers", - request -> { - Map fields = new HashMap<>(); - ProtoRestSerializer serializer = - ProtoRestSerializer.create(); - serializer.putPathParam(fields, "parent", request.getParent()); - serializer.putPathParam(fields, "projectId", request.getProjectId()); - return fields; - }) - .setAdditionalPaths("/v1/{parent=projects/*/locations/*}/triggers") - .setQueryParamsExtractor( - request -> { - Map> fields = new HashMap<>(); - ProtoRestSerializer serializer = - ProtoRestSerializer.create(); - return fields; - }) - .setRequestBodyExtractor( - request -> - ProtoRestSerializer.create() - .toBody("trigger", request.getTrigger(), false)) - .build()) - .setResponseParser( - ProtoMessageResponseParser.newBuilder() - .setDefaultInstance(BuildTrigger.getDefaultInstance()) - .setDefaultTypeRegistry(typeRegistry) - .build()) - .build(); - - private static final ApiMethodDescriptor - getBuildTriggerMethodDescriptor = - ApiMethodDescriptor.newBuilder() - .setFullMethodName("google.devtools.cloudbuild.v1.CloudBuild/GetBuildTrigger") - .setHttpMethod("GET") - .setType(ApiMethodDescriptor.MethodType.UNARY) - .setRequestFormatter( - ProtoMessageRequestFormatter.newBuilder() - .setPath( - "/v1/projects/{projectId}/triggers/{triggerId}", - request -> { - Map fields = new HashMap<>(); - ProtoRestSerializer serializer = - ProtoRestSerializer.create(); - serializer.putPathParam(fields, "name", request.getName()); - serializer.putPathParam(fields, "projectId", request.getProjectId()); - serializer.putPathParam(fields, "triggerId", request.getTriggerId()); - return fields; - }) - .setAdditionalPaths("/v1/{name=projects/*/locations/*/triggers/*}") - .setQueryParamsExtractor( - request -> { - Map> fields = new HashMap<>(); - ProtoRestSerializer serializer = - ProtoRestSerializer.create(); - return fields; - }) - .setRequestBodyExtractor(request -> null) - .build()) - .setResponseParser( - ProtoMessageResponseParser.newBuilder() - .setDefaultInstance(BuildTrigger.getDefaultInstance()) - .setDefaultTypeRegistry(typeRegistry) - .build()) - .build(); - - private static final ApiMethodDescriptor - listBuildTriggersMethodDescriptor = - ApiMethodDescriptor.newBuilder() - .setFullMethodName("google.devtools.cloudbuild.v1.CloudBuild/ListBuildTriggers") - .setHttpMethod("GET") - .setType(ApiMethodDescriptor.MethodType.UNARY) - .setRequestFormatter( - ProtoMessageRequestFormatter.newBuilder() - .setPath( - "/v1/projects/{projectId}/triggers", - request -> { - Map fields = new HashMap<>(); - ProtoRestSerializer serializer = - ProtoRestSerializer.create(); - serializer.putPathParam(fields, "parent", request.getParent()); - serializer.putPathParam(fields, "projectId", request.getProjectId()); - return fields; - }) - .setAdditionalPaths("/v1/{parent=projects/*/locations/*}/triggers") - .setQueryParamsExtractor( - request -> { - Map> fields = new HashMap<>(); - ProtoRestSerializer serializer = - ProtoRestSerializer.create(); - serializer.putQueryParam(fields, "pageSize", request.getPageSize()); - serializer.putQueryParam(fields, "pageToken", request.getPageToken()); - return fields; - }) - .setRequestBodyExtractor(request -> null) - .build()) - .setResponseParser( - ProtoMessageResponseParser.newBuilder() - .setDefaultInstance(ListBuildTriggersResponse.getDefaultInstance()) - .setDefaultTypeRegistry(typeRegistry) - .build()) - .build(); - - private static final ApiMethodDescriptor - deleteBuildTriggerMethodDescriptor = - ApiMethodDescriptor.newBuilder() - .setFullMethodName("google.devtools.cloudbuild.v1.CloudBuild/DeleteBuildTrigger") - .setHttpMethod("DELETE") - .setType(ApiMethodDescriptor.MethodType.UNARY) - .setRequestFormatter( - ProtoMessageRequestFormatter.newBuilder() - .setPath( - "/v1/projects/{projectId}/triggers/{triggerId}", - request -> { - Map fields = new HashMap<>(); - ProtoRestSerializer serializer = - ProtoRestSerializer.create(); - serializer.putPathParam(fields, "name", request.getName()); - serializer.putPathParam(fields, "projectId", request.getProjectId()); - serializer.putPathParam(fields, "triggerId", request.getTriggerId()); - return fields; - }) - .setAdditionalPaths("/v1/{name=projects/*/locations/*/triggers/*}") - .setQueryParamsExtractor( - request -> { - Map> fields = new HashMap<>(); - ProtoRestSerializer serializer = - ProtoRestSerializer.create(); - return fields; - }) - .setRequestBodyExtractor(request -> null) - .build()) - .setResponseParser( - ProtoMessageResponseParser.newBuilder() - .setDefaultInstance(Empty.getDefaultInstance()) - .setDefaultTypeRegistry(typeRegistry) - .build()) - .build(); - - private static final ApiMethodDescriptor - updateBuildTriggerMethodDescriptor = - ApiMethodDescriptor.newBuilder() - .setFullMethodName("google.devtools.cloudbuild.v1.CloudBuild/UpdateBuildTrigger") - .setHttpMethod("PATCH") - .setType(ApiMethodDescriptor.MethodType.UNARY) - .setRequestFormatter( - ProtoMessageRequestFormatter.newBuilder() - .setPath( - "/v1/projects/{projectId}/triggers/{triggerId}", - request -> { - Map fields = new HashMap<>(); - ProtoRestSerializer serializer = - ProtoRestSerializer.create(); - serializer.putPathParam(fields, "projectId", request.getProjectId()); - serializer.putPathParam( - fields, - "trigger.resourceName", - request.getTrigger().getResourceName()); - serializer.putPathParam(fields, "triggerId", request.getTriggerId()); - return fields; - }) - .setAdditionalPaths( - "/v1/{trigger.resourceName=projects/*/locations/*/triggers/*}") - .setQueryParamsExtractor( - request -> { - Map> fields = new HashMap<>(); - ProtoRestSerializer serializer = - ProtoRestSerializer.create(); - return fields; - }) - .setRequestBodyExtractor( - request -> - ProtoRestSerializer.create() - .toBody("trigger", request.getTrigger(), false)) - .build()) - .setResponseParser( - ProtoMessageResponseParser.newBuilder() - .setDefaultInstance(BuildTrigger.getDefaultInstance()) - .setDefaultTypeRegistry(typeRegistry) - .build()) - .build(); - - private static final ApiMethodDescriptor - runBuildTriggerMethodDescriptor = - ApiMethodDescriptor.newBuilder() - .setFullMethodName("google.devtools.cloudbuild.v1.CloudBuild/RunBuildTrigger") - .setHttpMethod("POST") - .setType(ApiMethodDescriptor.MethodType.UNARY) - .setRequestFormatter( - ProtoMessageRequestFormatter.newBuilder() - .setPath( - "/v1/projects/{projectId}/triggers/{triggerId}:run", - request -> { - Map fields = new HashMap<>(); - ProtoRestSerializer serializer = - ProtoRestSerializer.create(); - serializer.putPathParam(fields, "name", request.getName()); - serializer.putPathParam(fields, "projectId", request.getProjectId()); - serializer.putPathParam(fields, "triggerId", request.getTriggerId()); - return fields; - }) - .setAdditionalPaths("/v1/{name=projects/*/locations/*/triggers/*}:run") - .setQueryParamsExtractor( - request -> { - Map> fields = new HashMap<>(); - ProtoRestSerializer serializer = - ProtoRestSerializer.create(); - return fields; - }) - .setRequestBodyExtractor( - request -> - ProtoRestSerializer.create() - .toBody("source", request.getSource(), false)) - .build()) - .setResponseParser( - ProtoMessageResponseParser.newBuilder() - .setDefaultInstance(Operation.getDefaultInstance()) - .setDefaultTypeRegistry(typeRegistry) - .build()) - .setOperationSnapshotFactory( - (RunBuildTriggerRequest request, Operation response) -> - HttpJsonOperationSnapshot.create(response)) - .build(); - - private static final ApiMethodDescriptor< - ReceiveTriggerWebhookRequest, ReceiveTriggerWebhookResponse> - receiveTriggerWebhookMethodDescriptor = - ApiMethodDescriptor - .newBuilder() - .setFullMethodName("google.devtools.cloudbuild.v1.CloudBuild/ReceiveTriggerWebhook") - .setHttpMethod("POST") - .setType(ApiMethodDescriptor.MethodType.UNARY) - .setRequestFormatter( - ProtoMessageRequestFormatter.newBuilder() - .setPath( - "/v1/projects/{projectId}/triggers/{trigger}:webhook", - request -> { - Map fields = new HashMap<>(); - ProtoRestSerializer serializer = - ProtoRestSerializer.create(); - serializer.putPathParam(fields, "name", request.getName()); - serializer.putPathParam(fields, "projectId", request.getProjectId()); - serializer.putPathParam(fields, "trigger", request.getTrigger()); - return fields; - }) - .setAdditionalPaths("/v1/{name=projects/*/locations/*/triggers/*}:webhook") - .setQueryParamsExtractor( - request -> { - Map> fields = new HashMap<>(); - ProtoRestSerializer serializer = - ProtoRestSerializer.create(); - serializer.putQueryParam(fields, "secret", request.getSecret()); - return fields; - }) - .setRequestBodyExtractor( - request -> - ProtoRestSerializer.create().toBody("body", request.getBody(), false)) - .build()) - .setResponseParser( - ProtoMessageResponseParser.newBuilder() - .setDefaultInstance(ReceiveTriggerWebhookResponse.getDefaultInstance()) - .setDefaultTypeRegistry(typeRegistry) - .build()) - .build(); - - private static final ApiMethodDescriptor - createWorkerPoolMethodDescriptor = - ApiMethodDescriptor.newBuilder() - .setFullMethodName("google.devtools.cloudbuild.v1.CloudBuild/CreateWorkerPool") - .setHttpMethod("POST") - .setType(ApiMethodDescriptor.MethodType.UNARY) - .setRequestFormatter( - ProtoMessageRequestFormatter.newBuilder() - .setPath( - "/v1/{parent=projects/*/locations/*}/workerPools", - request -> { - Map fields = new HashMap<>(); - ProtoRestSerializer serializer = - ProtoRestSerializer.create(); - serializer.putPathParam(fields, "parent", request.getParent()); - return fields; - }) - .setQueryParamsExtractor( - request -> { - Map> fields = new HashMap<>(); - ProtoRestSerializer serializer = - ProtoRestSerializer.create(); - serializer.putQueryParam( - fields, "validateOnly", request.getValidateOnly()); - serializer.putQueryParam( - fields, "workerPoolId", request.getWorkerPoolId()); - return fields; - }) - .setRequestBodyExtractor( - request -> - ProtoRestSerializer.create() - .toBody("workerPool", request.getWorkerPool(), false)) - .build()) - .setResponseParser( - ProtoMessageResponseParser.newBuilder() - .setDefaultInstance(Operation.getDefaultInstance()) - .setDefaultTypeRegistry(typeRegistry) - .build()) - .setOperationSnapshotFactory( - (CreateWorkerPoolRequest request, Operation response) -> - HttpJsonOperationSnapshot.create(response)) - .build(); - - private static final ApiMethodDescriptor - getWorkerPoolMethodDescriptor = - ApiMethodDescriptor.newBuilder() - .setFullMethodName("google.devtools.cloudbuild.v1.CloudBuild/GetWorkerPool") - .setHttpMethod("GET") - .setType(ApiMethodDescriptor.MethodType.UNARY) - .setRequestFormatter( - ProtoMessageRequestFormatter.newBuilder() - .setPath( - "/v1/{name=projects/*/locations/*/workerPools/*}", - request -> { - Map fields = new HashMap<>(); - ProtoRestSerializer serializer = - ProtoRestSerializer.create(); - serializer.putPathParam(fields, "name", request.getName()); - return fields; - }) - .setQueryParamsExtractor( - request -> { - Map> fields = new HashMap<>(); - ProtoRestSerializer serializer = - ProtoRestSerializer.create(); - return fields; - }) - .setRequestBodyExtractor(request -> null) - .build()) - .setResponseParser( - ProtoMessageResponseParser.newBuilder() - .setDefaultInstance(WorkerPool.getDefaultInstance()) - .setDefaultTypeRegistry(typeRegistry) - .build()) - .build(); - - private static final ApiMethodDescriptor - deleteWorkerPoolMethodDescriptor = - ApiMethodDescriptor.newBuilder() - .setFullMethodName("google.devtools.cloudbuild.v1.CloudBuild/DeleteWorkerPool") - .setHttpMethod("DELETE") - .setType(ApiMethodDescriptor.MethodType.UNARY) - .setRequestFormatter( - ProtoMessageRequestFormatter.newBuilder() - .setPath( - "/v1/{name=projects/*/locations/*/workerPools/*}", - request -> { - Map fields = new HashMap<>(); - ProtoRestSerializer serializer = - ProtoRestSerializer.create(); - serializer.putPathParam(fields, "name", request.getName()); - return fields; - }) - .setQueryParamsExtractor( - request -> { - Map> fields = new HashMap<>(); - ProtoRestSerializer serializer = - ProtoRestSerializer.create(); - serializer.putQueryParam( - fields, "allowMissing", request.getAllowMissing()); - serializer.putQueryParam(fields, "etag", request.getEtag()); - serializer.putQueryParam( - fields, "validateOnly", request.getValidateOnly()); - return fields; - }) - .setRequestBodyExtractor(request -> null) - .build()) - .setResponseParser( - ProtoMessageResponseParser.newBuilder() - .setDefaultInstance(Operation.getDefaultInstance()) - .setDefaultTypeRegistry(typeRegistry) - .build()) - .setOperationSnapshotFactory( - (DeleteWorkerPoolRequest request, Operation response) -> - HttpJsonOperationSnapshot.create(response)) - .build(); - - private static final ApiMethodDescriptor - updateWorkerPoolMethodDescriptor = - ApiMethodDescriptor.newBuilder() - .setFullMethodName("google.devtools.cloudbuild.v1.CloudBuild/UpdateWorkerPool") - .setHttpMethod("PATCH") - .setType(ApiMethodDescriptor.MethodType.UNARY) - .setRequestFormatter( - ProtoMessageRequestFormatter.newBuilder() - .setPath( - "/v1/{workerPool.name=projects/*/locations/*/workerPools/*}", - request -> { - Map fields = new HashMap<>(); - ProtoRestSerializer serializer = - ProtoRestSerializer.create(); - serializer.putPathParam( - fields, "workerPool.name", request.getWorkerPool().getName()); - return fields; - }) - .setQueryParamsExtractor( - request -> { - Map> fields = new HashMap<>(); - ProtoRestSerializer serializer = - ProtoRestSerializer.create(); - serializer.putQueryParam(fields, "updateMask", request.getUpdateMask()); - serializer.putQueryParam( - fields, "validateOnly", request.getValidateOnly()); - return fields; - }) - .setRequestBodyExtractor( - request -> - ProtoRestSerializer.create() - .toBody("workerPool", request.getWorkerPool(), false)) - .build()) - .setResponseParser( - ProtoMessageResponseParser.newBuilder() - .setDefaultInstance(Operation.getDefaultInstance()) - .setDefaultTypeRegistry(typeRegistry) - .build()) - .setOperationSnapshotFactory( - (UpdateWorkerPoolRequest request, Operation response) -> - HttpJsonOperationSnapshot.create(response)) - .build(); - - private static final ApiMethodDescriptor - listWorkerPoolsMethodDescriptor = - ApiMethodDescriptor.newBuilder() - .setFullMethodName("google.devtools.cloudbuild.v1.CloudBuild/ListWorkerPools") - .setHttpMethod("GET") - .setType(ApiMethodDescriptor.MethodType.UNARY) - .setRequestFormatter( - ProtoMessageRequestFormatter.newBuilder() - .setPath( - "/v1/{parent=projects/*/locations/*}/workerPools", - request -> { - Map fields = new HashMap<>(); - ProtoRestSerializer serializer = - ProtoRestSerializer.create(); - serializer.putPathParam(fields, "parent", request.getParent()); - return fields; - }) - .setQueryParamsExtractor( - request -> { - Map> fields = new HashMap<>(); - ProtoRestSerializer serializer = - ProtoRestSerializer.create(); - serializer.putQueryParam(fields, "pageSize", request.getPageSize()); - serializer.putQueryParam(fields, "pageToken", request.getPageToken()); - return fields; - }) - .setRequestBodyExtractor(request -> null) - .build()) - .setResponseParser( - ProtoMessageResponseParser.newBuilder() - .setDefaultInstance(ListWorkerPoolsResponse.getDefaultInstance()) - .setDefaultTypeRegistry(typeRegistry) - .build()) - .build(); - - private final UnaryCallable createBuildCallable; - private final OperationCallable - createBuildOperationCallable; - private final UnaryCallable getBuildCallable; - private final UnaryCallable listBuildsCallable; - private final UnaryCallable listBuildsPagedCallable; - private final UnaryCallable cancelBuildCallable; - private final UnaryCallable retryBuildCallable; - private final OperationCallable - retryBuildOperationCallable; - private final UnaryCallable approveBuildCallable; - private final OperationCallable - approveBuildOperationCallable; - private final UnaryCallable createBuildTriggerCallable; - private final UnaryCallable getBuildTriggerCallable; - private final UnaryCallable - listBuildTriggersCallable; - private final UnaryCallable - listBuildTriggersPagedCallable; - private final UnaryCallable deleteBuildTriggerCallable; - private final UnaryCallable updateBuildTriggerCallable; - private final UnaryCallable runBuildTriggerCallable; - private final OperationCallable - runBuildTriggerOperationCallable; - private final UnaryCallable - receiveTriggerWebhookCallable; - private final UnaryCallable createWorkerPoolCallable; - private final OperationCallable< - CreateWorkerPoolRequest, WorkerPool, CreateWorkerPoolOperationMetadata> - createWorkerPoolOperationCallable; - private final UnaryCallable getWorkerPoolCallable; - private final UnaryCallable deleteWorkerPoolCallable; - private final OperationCallable - deleteWorkerPoolOperationCallable; - private final UnaryCallable updateWorkerPoolCallable; - private final OperationCallable< - UpdateWorkerPoolRequest, WorkerPool, UpdateWorkerPoolOperationMetadata> - updateWorkerPoolOperationCallable; - private final UnaryCallable - listWorkerPoolsCallable; - private final UnaryCallable - listWorkerPoolsPagedCallable; - - private final BackgroundResource backgroundResources; - private final HttpJsonOperationsStub httpJsonOperationsStub; - private final HttpJsonStubCallableFactory callableFactory; - - public static final HttpJsonCloudBuildStub create(CloudBuildStubSettings settings) - throws IOException { - return new HttpJsonCloudBuildStub(settings, ClientContext.create(settings)); - } - - public static final HttpJsonCloudBuildStub create(ClientContext clientContext) - throws IOException { - return new HttpJsonCloudBuildStub( - CloudBuildStubSettings.newHttpJsonBuilder().build(), clientContext); - } - - public static final HttpJsonCloudBuildStub create( - ClientContext clientContext, HttpJsonStubCallableFactory callableFactory) throws IOException { - return new HttpJsonCloudBuildStub( - CloudBuildStubSettings.newHttpJsonBuilder().build(), clientContext, callableFactory); - } - - /** - * Constructs an instance of HttpJsonCloudBuildStub, using the given settings. This is protected - * so that it is easy to make a subclass, but otherwise, the static factory methods should be - * preferred. - */ - protected HttpJsonCloudBuildStub(CloudBuildStubSettings settings, ClientContext clientContext) - throws IOException { - this(settings, clientContext, new HttpJsonCloudBuildCallableFactory()); - } - - /** - * Constructs an instance of HttpJsonCloudBuildStub, using the given settings. This is protected - * so that it is easy to make a subclass, but otherwise, the static factory methods should be - * preferred. - */ - protected HttpJsonCloudBuildStub( - CloudBuildStubSettings settings, - ClientContext clientContext, - HttpJsonStubCallableFactory callableFactory) - throws IOException { - this.callableFactory = callableFactory; - this.httpJsonOperationsStub = - HttpJsonOperationsStub.create(clientContext, callableFactory, typeRegistry); - - HttpJsonCallSettings createBuildTransportSettings = - HttpJsonCallSettings.newBuilder() - .setMethodDescriptor(createBuildMethodDescriptor) - .setTypeRegistry(typeRegistry) - .build(); - HttpJsonCallSettings getBuildTransportSettings = - HttpJsonCallSettings.newBuilder() - .setMethodDescriptor(getBuildMethodDescriptor) - .setTypeRegistry(typeRegistry) - .build(); - HttpJsonCallSettings listBuildsTransportSettings = - HttpJsonCallSettings.newBuilder() - .setMethodDescriptor(listBuildsMethodDescriptor) - .setTypeRegistry(typeRegistry) - .build(); - HttpJsonCallSettings cancelBuildTransportSettings = - HttpJsonCallSettings.newBuilder() - .setMethodDescriptor(cancelBuildMethodDescriptor) - .setTypeRegistry(typeRegistry) - .build(); - HttpJsonCallSettings retryBuildTransportSettings = - HttpJsonCallSettings.newBuilder() - .setMethodDescriptor(retryBuildMethodDescriptor) - .setTypeRegistry(typeRegistry) - .build(); - HttpJsonCallSettings approveBuildTransportSettings = - HttpJsonCallSettings.newBuilder() - .setMethodDescriptor(approveBuildMethodDescriptor) - .setTypeRegistry(typeRegistry) - .build(); - HttpJsonCallSettings - createBuildTriggerTransportSettings = - HttpJsonCallSettings.newBuilder() - .setMethodDescriptor(createBuildTriggerMethodDescriptor) - .setTypeRegistry(typeRegistry) - .build(); - HttpJsonCallSettings getBuildTriggerTransportSettings = - HttpJsonCallSettings.newBuilder() - .setMethodDescriptor(getBuildTriggerMethodDescriptor) - .setTypeRegistry(typeRegistry) - .build(); - HttpJsonCallSettings - listBuildTriggersTransportSettings = - HttpJsonCallSettings.newBuilder() - .setMethodDescriptor(listBuildTriggersMethodDescriptor) - .setTypeRegistry(typeRegistry) - .build(); - HttpJsonCallSettings deleteBuildTriggerTransportSettings = - HttpJsonCallSettings.newBuilder() - .setMethodDescriptor(deleteBuildTriggerMethodDescriptor) - .setTypeRegistry(typeRegistry) - .build(); - HttpJsonCallSettings - updateBuildTriggerTransportSettings = - HttpJsonCallSettings.newBuilder() - .setMethodDescriptor(updateBuildTriggerMethodDescriptor) - .setTypeRegistry(typeRegistry) - .build(); - HttpJsonCallSettings runBuildTriggerTransportSettings = - HttpJsonCallSettings.newBuilder() - .setMethodDescriptor(runBuildTriggerMethodDescriptor) - .setTypeRegistry(typeRegistry) - .build(); - HttpJsonCallSettings - receiveTriggerWebhookTransportSettings = - HttpJsonCallSettings - .newBuilder() - .setMethodDescriptor(receiveTriggerWebhookMethodDescriptor) - .setTypeRegistry(typeRegistry) - .build(); - HttpJsonCallSettings createWorkerPoolTransportSettings = - HttpJsonCallSettings.newBuilder() - .setMethodDescriptor(createWorkerPoolMethodDescriptor) - .setTypeRegistry(typeRegistry) - .build(); - HttpJsonCallSettings getWorkerPoolTransportSettings = - HttpJsonCallSettings.newBuilder() - .setMethodDescriptor(getWorkerPoolMethodDescriptor) - .setTypeRegistry(typeRegistry) - .build(); - HttpJsonCallSettings deleteWorkerPoolTransportSettings = - HttpJsonCallSettings.newBuilder() - .setMethodDescriptor(deleteWorkerPoolMethodDescriptor) - .setTypeRegistry(typeRegistry) - .build(); - HttpJsonCallSettings updateWorkerPoolTransportSettings = - HttpJsonCallSettings.newBuilder() - .setMethodDescriptor(updateWorkerPoolMethodDescriptor) - .setTypeRegistry(typeRegistry) - .build(); - HttpJsonCallSettings - listWorkerPoolsTransportSettings = - HttpJsonCallSettings.newBuilder() - .setMethodDescriptor(listWorkerPoolsMethodDescriptor) - .setTypeRegistry(typeRegistry) - .build(); - - this.createBuildCallable = - callableFactory.createUnaryCallable( - createBuildTransportSettings, settings.createBuildSettings(), clientContext); - this.createBuildOperationCallable = - callableFactory.createOperationCallable( - createBuildTransportSettings, - settings.createBuildOperationSettings(), - clientContext, - httpJsonOperationsStub); - this.getBuildCallable = - callableFactory.createUnaryCallable( - getBuildTransportSettings, settings.getBuildSettings(), clientContext); - this.listBuildsCallable = - callableFactory.createUnaryCallable( - listBuildsTransportSettings, settings.listBuildsSettings(), clientContext); - this.listBuildsPagedCallable = - callableFactory.createPagedCallable( - listBuildsTransportSettings, settings.listBuildsSettings(), clientContext); - this.cancelBuildCallable = - callableFactory.createUnaryCallable( - cancelBuildTransportSettings, settings.cancelBuildSettings(), clientContext); - this.retryBuildCallable = - callableFactory.createUnaryCallable( - retryBuildTransportSettings, settings.retryBuildSettings(), clientContext); - this.retryBuildOperationCallable = - callableFactory.createOperationCallable( - retryBuildTransportSettings, - settings.retryBuildOperationSettings(), - clientContext, - httpJsonOperationsStub); - this.approveBuildCallable = - callableFactory.createUnaryCallable( - approveBuildTransportSettings, settings.approveBuildSettings(), clientContext); - this.approveBuildOperationCallable = - callableFactory.createOperationCallable( - approveBuildTransportSettings, - settings.approveBuildOperationSettings(), - clientContext, - httpJsonOperationsStub); - this.createBuildTriggerCallable = - callableFactory.createUnaryCallable( - createBuildTriggerTransportSettings, - settings.createBuildTriggerSettings(), - clientContext); - this.getBuildTriggerCallable = - callableFactory.createUnaryCallable( - getBuildTriggerTransportSettings, settings.getBuildTriggerSettings(), clientContext); - this.listBuildTriggersCallable = - callableFactory.createUnaryCallable( - listBuildTriggersTransportSettings, - settings.listBuildTriggersSettings(), - clientContext); - this.listBuildTriggersPagedCallable = - callableFactory.createPagedCallable( - listBuildTriggersTransportSettings, - settings.listBuildTriggersSettings(), - clientContext); - this.deleteBuildTriggerCallable = - callableFactory.createUnaryCallable( - deleteBuildTriggerTransportSettings, - settings.deleteBuildTriggerSettings(), - clientContext); - this.updateBuildTriggerCallable = - callableFactory.createUnaryCallable( - updateBuildTriggerTransportSettings, - settings.updateBuildTriggerSettings(), - clientContext); - this.runBuildTriggerCallable = - callableFactory.createUnaryCallable( - runBuildTriggerTransportSettings, settings.runBuildTriggerSettings(), clientContext); - this.runBuildTriggerOperationCallable = - callableFactory.createOperationCallable( - runBuildTriggerTransportSettings, - settings.runBuildTriggerOperationSettings(), - clientContext, - httpJsonOperationsStub); - this.receiveTriggerWebhookCallable = - callableFactory.createUnaryCallable( - receiveTriggerWebhookTransportSettings, - settings.receiveTriggerWebhookSettings(), - clientContext); - this.createWorkerPoolCallable = - callableFactory.createUnaryCallable( - createWorkerPoolTransportSettings, settings.createWorkerPoolSettings(), clientContext); - this.createWorkerPoolOperationCallable = - callableFactory.createOperationCallable( - createWorkerPoolTransportSettings, - settings.createWorkerPoolOperationSettings(), - clientContext, - httpJsonOperationsStub); - this.getWorkerPoolCallable = - callableFactory.createUnaryCallable( - getWorkerPoolTransportSettings, settings.getWorkerPoolSettings(), clientContext); - this.deleteWorkerPoolCallable = - callableFactory.createUnaryCallable( - deleteWorkerPoolTransportSettings, settings.deleteWorkerPoolSettings(), clientContext); - this.deleteWorkerPoolOperationCallable = - callableFactory.createOperationCallable( - deleteWorkerPoolTransportSettings, - settings.deleteWorkerPoolOperationSettings(), - clientContext, - httpJsonOperationsStub); - this.updateWorkerPoolCallable = - callableFactory.createUnaryCallable( - updateWorkerPoolTransportSettings, settings.updateWorkerPoolSettings(), clientContext); - this.updateWorkerPoolOperationCallable = - callableFactory.createOperationCallable( - updateWorkerPoolTransportSettings, - settings.updateWorkerPoolOperationSettings(), - clientContext, - httpJsonOperationsStub); - this.listWorkerPoolsCallable = - callableFactory.createUnaryCallable( - listWorkerPoolsTransportSettings, settings.listWorkerPoolsSettings(), clientContext); - this.listWorkerPoolsPagedCallable = - callableFactory.createPagedCallable( - listWorkerPoolsTransportSettings, settings.listWorkerPoolsSettings(), clientContext); - - this.backgroundResources = - new BackgroundResourceAggregation(clientContext.getBackgroundResources()); - } - - @InternalApi - public static List getMethodDescriptors() { - List methodDescriptors = new ArrayList<>(); - methodDescriptors.add(createBuildMethodDescriptor); - methodDescriptors.add(getBuildMethodDescriptor); - methodDescriptors.add(listBuildsMethodDescriptor); - methodDescriptors.add(cancelBuildMethodDescriptor); - methodDescriptors.add(retryBuildMethodDescriptor); - methodDescriptors.add(approveBuildMethodDescriptor); - methodDescriptors.add(createBuildTriggerMethodDescriptor); - methodDescriptors.add(getBuildTriggerMethodDescriptor); - methodDescriptors.add(listBuildTriggersMethodDescriptor); - methodDescriptors.add(deleteBuildTriggerMethodDescriptor); - methodDescriptors.add(updateBuildTriggerMethodDescriptor); - methodDescriptors.add(runBuildTriggerMethodDescriptor); - methodDescriptors.add(receiveTriggerWebhookMethodDescriptor); - methodDescriptors.add(createWorkerPoolMethodDescriptor); - methodDescriptors.add(getWorkerPoolMethodDescriptor); - methodDescriptors.add(deleteWorkerPoolMethodDescriptor); - methodDescriptors.add(updateWorkerPoolMethodDescriptor); - methodDescriptors.add(listWorkerPoolsMethodDescriptor); - return methodDescriptors; - } - - public HttpJsonOperationsStub getHttpJsonOperationsStub() { - return httpJsonOperationsStub; - } - - @Override - public UnaryCallable createBuildCallable() { - return createBuildCallable; - } - - @Override - public OperationCallable - createBuildOperationCallable() { - return createBuildOperationCallable; - } - - @Override - public UnaryCallable getBuildCallable() { - return getBuildCallable; - } - - @Override - public UnaryCallable listBuildsCallable() { - return listBuildsCallable; - } - - @Override - public UnaryCallable listBuildsPagedCallable() { - return listBuildsPagedCallable; - } - - @Override - public UnaryCallable cancelBuildCallable() { - return cancelBuildCallable; - } - - @Override - public UnaryCallable retryBuildCallable() { - return retryBuildCallable; - } - - @Override - public OperationCallable - retryBuildOperationCallable() { - return retryBuildOperationCallable; - } - - @Override - public UnaryCallable approveBuildCallable() { - return approveBuildCallable; - } - - @Override - public OperationCallable - approveBuildOperationCallable() { - return approveBuildOperationCallable; - } - - @Override - public UnaryCallable createBuildTriggerCallable() { - return createBuildTriggerCallable; - } - - @Override - public UnaryCallable getBuildTriggerCallable() { - return getBuildTriggerCallable; - } - - @Override - public UnaryCallable - listBuildTriggersCallable() { - return listBuildTriggersCallable; - } - - @Override - public UnaryCallable - listBuildTriggersPagedCallable() { - return listBuildTriggersPagedCallable; - } - - @Override - public UnaryCallable deleteBuildTriggerCallable() { - return deleteBuildTriggerCallable; - } - - @Override - public UnaryCallable updateBuildTriggerCallable() { - return updateBuildTriggerCallable; - } - - @Override - public UnaryCallable runBuildTriggerCallable() { - return runBuildTriggerCallable; - } - - @Override - public OperationCallable - runBuildTriggerOperationCallable() { - return runBuildTriggerOperationCallable; - } - - @Override - public UnaryCallable - receiveTriggerWebhookCallable() { - return receiveTriggerWebhookCallable; - } - - @Override - public UnaryCallable createWorkerPoolCallable() { - return createWorkerPoolCallable; - } - - @Override - public OperationCallable - createWorkerPoolOperationCallable() { - return createWorkerPoolOperationCallable; - } - - @Override - public UnaryCallable getWorkerPoolCallable() { - return getWorkerPoolCallable; - } - - @Override - public UnaryCallable deleteWorkerPoolCallable() { - return deleteWorkerPoolCallable; - } - - @Override - public OperationCallable - deleteWorkerPoolOperationCallable() { - return deleteWorkerPoolOperationCallable; - } - - @Override - public UnaryCallable updateWorkerPoolCallable() { - return updateWorkerPoolCallable; - } - - @Override - public OperationCallable - updateWorkerPoolOperationCallable() { - return updateWorkerPoolOperationCallable; - } - - @Override - public UnaryCallable listWorkerPoolsCallable() { - return listWorkerPoolsCallable; - } - - @Override - public UnaryCallable - listWorkerPoolsPagedCallable() { - return listWorkerPoolsPagedCallable; - } - - @Override - public final void close() { - try { - backgroundResources.close(); - } catch (RuntimeException e) { - throw e; - } catch (Exception e) { - throw new IllegalStateException("Failed to close resource", e); - } - } - - @Override - public void shutdown() { - backgroundResources.shutdown(); - } - - @Override - public boolean isShutdown() { - return backgroundResources.isShutdown(); - } - - @Override - public boolean isTerminated() { - return backgroundResources.isTerminated(); - } - - @Override - public void shutdownNow() { - backgroundResources.shutdownNow(); - } - - @Override - public boolean awaitTermination(long duration, TimeUnit unit) throws InterruptedException { - return backgroundResources.awaitTermination(duration, unit); - } -} diff --git a/google-cloud-build/src/test/java/com/google/cloud/devtools/cloudbuild/v1/CloudBuildClientHttpJsonTest.java b/google-cloud-build/src/test/java/com/google/cloud/devtools/cloudbuild/v1/CloudBuildClientHttpJsonTest.java deleted file mode 100644 index 099d164c..00000000 --- a/google-cloud-build/src/test/java/com/google/cloud/devtools/cloudbuild/v1/CloudBuildClientHttpJsonTest.java +++ /dev/null @@ -1,1488 +0,0 @@ -/* - * Copyright 2022 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package com.google.cloud.devtools.cloudbuild.v1; - -import static com.google.cloud.devtools.cloudbuild.v1.CloudBuildClient.ListBuildTriggersPagedResponse; -import static com.google.cloud.devtools.cloudbuild.v1.CloudBuildClient.ListBuildsPagedResponse; -import static com.google.cloud.devtools.cloudbuild.v1.CloudBuildClient.ListWorkerPoolsPagedResponse; - -import com.google.api.HttpBody; -import com.google.api.gax.core.NoCredentialsProvider; -import com.google.api.gax.httpjson.GaxHttpJsonProperties; -import com.google.api.gax.httpjson.testing.MockHttpService; -import com.google.api.gax.rpc.ApiClientHeaderProvider; -import com.google.api.gax.rpc.ApiException; -import com.google.api.gax.rpc.ApiExceptionFactory; -import com.google.api.gax.rpc.InvalidArgumentException; -import com.google.api.gax.rpc.StatusCode; -import com.google.api.gax.rpc.testing.FakeStatusCode; -import com.google.cloud.devtools.cloudbuild.v1.stub.HttpJsonCloudBuildStub; -import com.google.cloudbuild.v1.ApprovalResult; -import com.google.cloudbuild.v1.Artifacts; -import com.google.cloudbuild.v1.Build; -import com.google.cloudbuild.v1.BuildApproval; -import com.google.cloudbuild.v1.BuildName; -import com.google.cloudbuild.v1.BuildOptions; -import com.google.cloudbuild.v1.BuildStep; -import com.google.cloudbuild.v1.BuildTrigger; -import com.google.cloudbuild.v1.BuildTriggerName; -import com.google.cloudbuild.v1.GitHubEventsConfig; -import com.google.cloudbuild.v1.ListBuildTriggersResponse; -import com.google.cloudbuild.v1.ListBuildsResponse; -import com.google.cloudbuild.v1.ListWorkerPoolsResponse; -import com.google.cloudbuild.v1.LocationName; -import com.google.cloudbuild.v1.PubsubConfig; -import com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest; -import com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse; -import com.google.cloudbuild.v1.RepoSource; -import com.google.cloudbuild.v1.Results; -import com.google.cloudbuild.v1.Secret; -import com.google.cloudbuild.v1.Secrets; -import com.google.cloudbuild.v1.Source; -import com.google.cloudbuild.v1.SourceProvenance; -import com.google.cloudbuild.v1.TimeSpan; -import com.google.cloudbuild.v1.WebhookConfig; -import com.google.cloudbuild.v1.WorkerPool; -import com.google.cloudbuild.v1.WorkerPoolName; -import com.google.common.collect.Lists; -import com.google.longrunning.Operation; -import com.google.protobuf.Any; -import com.google.protobuf.Duration; -import com.google.protobuf.Empty; -import com.google.protobuf.FieldMask; -import com.google.protobuf.Timestamp; -import java.io.IOException; -import java.util.ArrayList; -import java.util.Arrays; -import java.util.HashMap; -import java.util.List; -import java.util.concurrent.ExecutionException; -import javax.annotation.Generated; -import org.junit.After; -import org.junit.AfterClass; -import org.junit.Assert; -import org.junit.Before; -import org.junit.BeforeClass; -import org.junit.Test; - -@Generated("by gapic-generator-java") -public class CloudBuildClientHttpJsonTest { - private static MockHttpService mockService; - private static CloudBuildClient client; - - @BeforeClass - public static void startStaticServer() throws IOException { - mockService = - new MockHttpService( - HttpJsonCloudBuildStub.getMethodDescriptors(), CloudBuildSettings.getDefaultEndpoint()); - CloudBuildSettings settings = - CloudBuildSettings.newHttpJsonBuilder() - .setTransportChannelProvider( - CloudBuildSettings.defaultHttpJsonTransportProviderBuilder() - .setHttpTransport(mockService) - .build()) - .setCredentialsProvider(NoCredentialsProvider.create()) - .build(); - client = CloudBuildClient.create(settings); - } - - @AfterClass - public static void stopServer() { - client.close(); - } - - @Before - public void setUp() {} - - @After - public void tearDown() throws Exception { - mockService.reset(); - } - - @Test - public void createBuildTest() throws Exception { - Build expectedResponse = - Build.newBuilder() - .setName(BuildName.ofProjectBuildName("[PROJECT]", "[BUILD]").toString()) - .setId("id3355") - .setProjectId("projectId-894832108") - .setStatusDetail("statusDetail1651087075") - .setSource(Source.newBuilder().build()) - .addAllSteps(new ArrayList()) - .setResults(Results.newBuilder().build()) - .setCreateTime(Timestamp.newBuilder().build()) - .setStartTime(Timestamp.newBuilder().build()) - .setFinishTime(Timestamp.newBuilder().build()) - .setTimeout(Duration.newBuilder().build()) - .addAllImages(new ArrayList()) - .setQueueTtl(Duration.newBuilder().build()) - .setArtifacts(Artifacts.newBuilder().build()) - .setLogsBucket("logsBucket1592573049") - .setSourceProvenance(SourceProvenance.newBuilder().build()) - .setBuildTriggerId("buildTriggerId781747749") - .setOptions(BuildOptions.newBuilder().build()) - .setLogUrl("logUrl-1097354357") - .putAllSubstitutions(new HashMap()) - .addAllTags(new ArrayList()) - .addAllSecrets(new ArrayList()) - .putAllTiming(new HashMap()) - .setApproval(BuildApproval.newBuilder().build()) - .setServiceAccount("serviceAccount1079137720") - .setAvailableSecrets(Secrets.newBuilder().build()) - .addAllWarnings(new ArrayList()) - .setFailureInfo(Build.FailureInfo.newBuilder().build()) - .build(); - Operation resultOperation = - Operation.newBuilder() - .setName("createBuildTest") - .setDone(true) - .setResponse(Any.pack(expectedResponse)) - .build(); - mockService.addResponse(resultOperation); - - String projectId = "projectId-1530"; - Build build = Build.newBuilder().build(); - - Build actualResponse = client.createBuildAsync(projectId, build).get(); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockService.getRequestPaths(); - Assert.assertEquals(1, actualRequests.size()); - - String apiClientHeaderKey = - mockService - .getRequestHeaders() - .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) - .iterator() - .next(); - Assert.assertTrue( - GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() - .matcher(apiClientHeaderKey) - .matches()); - } - - @Test - public void createBuildExceptionTest() throws Exception { - ApiException exception = - ApiExceptionFactory.createException( - new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); - mockService.addException(exception); - - try { - String projectId = "projectId-1530"; - Build build = Build.newBuilder().build(); - client.createBuildAsync(projectId, build).get(); - Assert.fail("No exception raised"); - } catch (ExecutionException e) { - } - } - - @Test - public void getBuildTest() throws Exception { - Build expectedResponse = - Build.newBuilder() - .setName(BuildName.ofProjectBuildName("[PROJECT]", "[BUILD]").toString()) - .setId("id3355") - .setProjectId("projectId-894832108") - .setStatusDetail("statusDetail1651087075") - .setSource(Source.newBuilder().build()) - .addAllSteps(new ArrayList()) - .setResults(Results.newBuilder().build()) - .setCreateTime(Timestamp.newBuilder().build()) - .setStartTime(Timestamp.newBuilder().build()) - .setFinishTime(Timestamp.newBuilder().build()) - .setTimeout(Duration.newBuilder().build()) - .addAllImages(new ArrayList()) - .setQueueTtl(Duration.newBuilder().build()) - .setArtifacts(Artifacts.newBuilder().build()) - .setLogsBucket("logsBucket1592573049") - .setSourceProvenance(SourceProvenance.newBuilder().build()) - .setBuildTriggerId("buildTriggerId781747749") - .setOptions(BuildOptions.newBuilder().build()) - .setLogUrl("logUrl-1097354357") - .putAllSubstitutions(new HashMap()) - .addAllTags(new ArrayList()) - .addAllSecrets(new ArrayList()) - .putAllTiming(new HashMap()) - .setApproval(BuildApproval.newBuilder().build()) - .setServiceAccount("serviceAccount1079137720") - .setAvailableSecrets(Secrets.newBuilder().build()) - .addAllWarnings(new ArrayList()) - .setFailureInfo(Build.FailureInfo.newBuilder().build()) - .build(); - mockService.addResponse(expectedResponse); - - String projectId = "projectId-1530"; - String id = "id-4047"; - - Build actualResponse = client.getBuild(projectId, id); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockService.getRequestPaths(); - Assert.assertEquals(1, actualRequests.size()); - - String apiClientHeaderKey = - mockService - .getRequestHeaders() - .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) - .iterator() - .next(); - Assert.assertTrue( - GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() - .matcher(apiClientHeaderKey) - .matches()); - } - - @Test - public void getBuildExceptionTest() throws Exception { - ApiException exception = - ApiExceptionFactory.createException( - new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); - mockService.addException(exception); - - try { - String projectId = "projectId-1530"; - String id = "id-4047"; - client.getBuild(projectId, id); - Assert.fail("No exception raised"); - } catch (InvalidArgumentException e) { - // Expected exception. - } - } - - @Test - public void listBuildsTest() throws Exception { - Build responsesElement = Build.newBuilder().build(); - ListBuildsResponse expectedResponse = - ListBuildsResponse.newBuilder() - .setNextPageToken("") - .addAllBuilds(Arrays.asList(responsesElement)) - .build(); - mockService.addResponse(expectedResponse); - - String projectId = "projectId-1530"; - String filter = "filter-1274492040"; - - ListBuildsPagedResponse pagedListResponse = client.listBuilds(projectId, filter); - - List resources = Lists.newArrayList(pagedListResponse.iterateAll()); - - Assert.assertEquals(1, resources.size()); - Assert.assertEquals(expectedResponse.getBuildsList().get(0), resources.get(0)); - - List actualRequests = mockService.getRequestPaths(); - Assert.assertEquals(1, actualRequests.size()); - - String apiClientHeaderKey = - mockService - .getRequestHeaders() - .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) - .iterator() - .next(); - Assert.assertTrue( - GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() - .matcher(apiClientHeaderKey) - .matches()); - } - - @Test - public void listBuildsExceptionTest() throws Exception { - ApiException exception = - ApiExceptionFactory.createException( - new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); - mockService.addException(exception); - - try { - String projectId = "projectId-1530"; - String filter = "filter-1274492040"; - client.listBuilds(projectId, filter); - Assert.fail("No exception raised"); - } catch (InvalidArgumentException e) { - // Expected exception. - } - } - - @Test - public void cancelBuildTest() throws Exception { - Build expectedResponse = - Build.newBuilder() - .setName(BuildName.ofProjectBuildName("[PROJECT]", "[BUILD]").toString()) - .setId("id3355") - .setProjectId("projectId-894832108") - .setStatusDetail("statusDetail1651087075") - .setSource(Source.newBuilder().build()) - .addAllSteps(new ArrayList()) - .setResults(Results.newBuilder().build()) - .setCreateTime(Timestamp.newBuilder().build()) - .setStartTime(Timestamp.newBuilder().build()) - .setFinishTime(Timestamp.newBuilder().build()) - .setTimeout(Duration.newBuilder().build()) - .addAllImages(new ArrayList()) - .setQueueTtl(Duration.newBuilder().build()) - .setArtifacts(Artifacts.newBuilder().build()) - .setLogsBucket("logsBucket1592573049") - .setSourceProvenance(SourceProvenance.newBuilder().build()) - .setBuildTriggerId("buildTriggerId781747749") - .setOptions(BuildOptions.newBuilder().build()) - .setLogUrl("logUrl-1097354357") - .putAllSubstitutions(new HashMap()) - .addAllTags(new ArrayList()) - .addAllSecrets(new ArrayList()) - .putAllTiming(new HashMap()) - .setApproval(BuildApproval.newBuilder().build()) - .setServiceAccount("serviceAccount1079137720") - .setAvailableSecrets(Secrets.newBuilder().build()) - .addAllWarnings(new ArrayList()) - .setFailureInfo(Build.FailureInfo.newBuilder().build()) - .build(); - mockService.addResponse(expectedResponse); - - String projectId = "projectId-1530"; - String id = "id-4047"; - - Build actualResponse = client.cancelBuild(projectId, id); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockService.getRequestPaths(); - Assert.assertEquals(1, actualRequests.size()); - - String apiClientHeaderKey = - mockService - .getRequestHeaders() - .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) - .iterator() - .next(); - Assert.assertTrue( - GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() - .matcher(apiClientHeaderKey) - .matches()); - } - - @Test - public void cancelBuildExceptionTest() throws Exception { - ApiException exception = - ApiExceptionFactory.createException( - new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); - mockService.addException(exception); - - try { - String projectId = "projectId-1530"; - String id = "id-4047"; - client.cancelBuild(projectId, id); - Assert.fail("No exception raised"); - } catch (InvalidArgumentException e) { - // Expected exception. - } - } - - @Test - public void retryBuildTest() throws Exception { - Build expectedResponse = - Build.newBuilder() - .setName(BuildName.ofProjectBuildName("[PROJECT]", "[BUILD]").toString()) - .setId("id3355") - .setProjectId("projectId-894832108") - .setStatusDetail("statusDetail1651087075") - .setSource(Source.newBuilder().build()) - .addAllSteps(new ArrayList()) - .setResults(Results.newBuilder().build()) - .setCreateTime(Timestamp.newBuilder().build()) - .setStartTime(Timestamp.newBuilder().build()) - .setFinishTime(Timestamp.newBuilder().build()) - .setTimeout(Duration.newBuilder().build()) - .addAllImages(new ArrayList()) - .setQueueTtl(Duration.newBuilder().build()) - .setArtifacts(Artifacts.newBuilder().build()) - .setLogsBucket("logsBucket1592573049") - .setSourceProvenance(SourceProvenance.newBuilder().build()) - .setBuildTriggerId("buildTriggerId781747749") - .setOptions(BuildOptions.newBuilder().build()) - .setLogUrl("logUrl-1097354357") - .putAllSubstitutions(new HashMap()) - .addAllTags(new ArrayList()) - .addAllSecrets(new ArrayList()) - .putAllTiming(new HashMap()) - .setApproval(BuildApproval.newBuilder().build()) - .setServiceAccount("serviceAccount1079137720") - .setAvailableSecrets(Secrets.newBuilder().build()) - .addAllWarnings(new ArrayList()) - .setFailureInfo(Build.FailureInfo.newBuilder().build()) - .build(); - Operation resultOperation = - Operation.newBuilder() - .setName("retryBuildTest") - .setDone(true) - .setResponse(Any.pack(expectedResponse)) - .build(); - mockService.addResponse(resultOperation); - - String projectId = "projectId-1530"; - String id = "id-4047"; - - Build actualResponse = client.retryBuildAsync(projectId, id).get(); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockService.getRequestPaths(); - Assert.assertEquals(1, actualRequests.size()); - - String apiClientHeaderKey = - mockService - .getRequestHeaders() - .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) - .iterator() - .next(); - Assert.assertTrue( - GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() - .matcher(apiClientHeaderKey) - .matches()); - } - - @Test - public void retryBuildExceptionTest() throws Exception { - ApiException exception = - ApiExceptionFactory.createException( - new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); - mockService.addException(exception); - - try { - String projectId = "projectId-1530"; - String id = "id-4047"; - client.retryBuildAsync(projectId, id).get(); - Assert.fail("No exception raised"); - } catch (ExecutionException e) { - } - } - - @Test - public void approveBuildTest() throws Exception { - Build expectedResponse = - Build.newBuilder() - .setName(BuildName.ofProjectBuildName("[PROJECT]", "[BUILD]").toString()) - .setId("id3355") - .setProjectId("projectId-894832108") - .setStatusDetail("statusDetail1651087075") - .setSource(Source.newBuilder().build()) - .addAllSteps(new ArrayList()) - .setResults(Results.newBuilder().build()) - .setCreateTime(Timestamp.newBuilder().build()) - .setStartTime(Timestamp.newBuilder().build()) - .setFinishTime(Timestamp.newBuilder().build()) - .setTimeout(Duration.newBuilder().build()) - .addAllImages(new ArrayList()) - .setQueueTtl(Duration.newBuilder().build()) - .setArtifacts(Artifacts.newBuilder().build()) - .setLogsBucket("logsBucket1592573049") - .setSourceProvenance(SourceProvenance.newBuilder().build()) - .setBuildTriggerId("buildTriggerId781747749") - .setOptions(BuildOptions.newBuilder().build()) - .setLogUrl("logUrl-1097354357") - .putAllSubstitutions(new HashMap()) - .addAllTags(new ArrayList()) - .addAllSecrets(new ArrayList()) - .putAllTiming(new HashMap()) - .setApproval(BuildApproval.newBuilder().build()) - .setServiceAccount("serviceAccount1079137720") - .setAvailableSecrets(Secrets.newBuilder().build()) - .addAllWarnings(new ArrayList()) - .setFailureInfo(Build.FailureInfo.newBuilder().build()) - .build(); - Operation resultOperation = - Operation.newBuilder() - .setName("approveBuildTest") - .setDone(true) - .setResponse(Any.pack(expectedResponse)) - .build(); - mockService.addResponse(resultOperation); - - String name = "projects/project-3679/builds/build-3679"; - ApprovalResult approvalResult = ApprovalResult.newBuilder().build(); - - Build actualResponse = client.approveBuildAsync(name, approvalResult).get(); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockService.getRequestPaths(); - Assert.assertEquals(1, actualRequests.size()); - - String apiClientHeaderKey = - mockService - .getRequestHeaders() - .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) - .iterator() - .next(); - Assert.assertTrue( - GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() - .matcher(apiClientHeaderKey) - .matches()); - } - - @Test - public void approveBuildExceptionTest() throws Exception { - ApiException exception = - ApiExceptionFactory.createException( - new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); - mockService.addException(exception); - - try { - String name = "projects/project-3679/builds/build-3679"; - ApprovalResult approvalResult = ApprovalResult.newBuilder().build(); - client.approveBuildAsync(name, approvalResult).get(); - Assert.fail("No exception raised"); - } catch (ExecutionException e) { - } - } - - @Test - public void createBuildTriggerTest() throws Exception { - BuildTrigger expectedResponse = - BuildTrigger.newBuilder() - .setResourceName("resourceName-384566343") - .setId("id3355") - .setDescription("description-1724546052") - .setName(BuildTriggerName.ofProjectTriggerName("[PROJECT]", "[TRIGGER]").toString()) - .addAllTags(new ArrayList()) - .setTriggerTemplate(RepoSource.newBuilder().build()) - .setGithub(GitHubEventsConfig.newBuilder().build()) - .setPubsubConfig(PubsubConfig.newBuilder().build()) - .setWebhookConfig(WebhookConfig.newBuilder().build()) - .setCreateTime(Timestamp.newBuilder().build()) - .setDisabled(true) - .putAllSubstitutions(new HashMap()) - .addAllIgnoredFiles(new ArrayList()) - .addAllIncludedFiles(new ArrayList()) - .setFilter("filter-1274492040") - .setServiceAccount("serviceAccount1079137720") - .build(); - mockService.addResponse(expectedResponse); - - String projectId = "projectId-1530"; - BuildTrigger trigger = BuildTrigger.newBuilder().build(); - - BuildTrigger actualResponse = client.createBuildTrigger(projectId, trigger); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockService.getRequestPaths(); - Assert.assertEquals(1, actualRequests.size()); - - String apiClientHeaderKey = - mockService - .getRequestHeaders() - .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) - .iterator() - .next(); - Assert.assertTrue( - GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() - .matcher(apiClientHeaderKey) - .matches()); - } - - @Test - public void createBuildTriggerExceptionTest() throws Exception { - ApiException exception = - ApiExceptionFactory.createException( - new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); - mockService.addException(exception); - - try { - String projectId = "projectId-1530"; - BuildTrigger trigger = BuildTrigger.newBuilder().build(); - client.createBuildTrigger(projectId, trigger); - Assert.fail("No exception raised"); - } catch (InvalidArgumentException e) { - // Expected exception. - } - } - - @Test - public void getBuildTriggerTest() throws Exception { - BuildTrigger expectedResponse = - BuildTrigger.newBuilder() - .setResourceName("resourceName-384566343") - .setId("id3355") - .setDescription("description-1724546052") - .setName(BuildTriggerName.ofProjectTriggerName("[PROJECT]", "[TRIGGER]").toString()) - .addAllTags(new ArrayList()) - .setTriggerTemplate(RepoSource.newBuilder().build()) - .setGithub(GitHubEventsConfig.newBuilder().build()) - .setPubsubConfig(PubsubConfig.newBuilder().build()) - .setWebhookConfig(WebhookConfig.newBuilder().build()) - .setCreateTime(Timestamp.newBuilder().build()) - .setDisabled(true) - .putAllSubstitutions(new HashMap()) - .addAllIgnoredFiles(new ArrayList()) - .addAllIncludedFiles(new ArrayList()) - .setFilter("filter-1274492040") - .setServiceAccount("serviceAccount1079137720") - .build(); - mockService.addResponse(expectedResponse); - - String projectId = "projectId-1530"; - String triggerId = "triggerId-6343"; - - BuildTrigger actualResponse = client.getBuildTrigger(projectId, triggerId); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockService.getRequestPaths(); - Assert.assertEquals(1, actualRequests.size()); - - String apiClientHeaderKey = - mockService - .getRequestHeaders() - .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) - .iterator() - .next(); - Assert.assertTrue( - GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() - .matcher(apiClientHeaderKey) - .matches()); - } - - @Test - public void getBuildTriggerExceptionTest() throws Exception { - ApiException exception = - ApiExceptionFactory.createException( - new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); - mockService.addException(exception); - - try { - String projectId = "projectId-1530"; - String triggerId = "triggerId-6343"; - client.getBuildTrigger(projectId, triggerId); - Assert.fail("No exception raised"); - } catch (InvalidArgumentException e) { - // Expected exception. - } - } - - @Test - public void listBuildTriggersTest() throws Exception { - BuildTrigger responsesElement = BuildTrigger.newBuilder().build(); - ListBuildTriggersResponse expectedResponse = - ListBuildTriggersResponse.newBuilder() - .setNextPageToken("") - .addAllTriggers(Arrays.asList(responsesElement)) - .build(); - mockService.addResponse(expectedResponse); - - String projectId = "projectId-1530"; - - ListBuildTriggersPagedResponse pagedListResponse = client.listBuildTriggers(projectId); - - List resources = Lists.newArrayList(pagedListResponse.iterateAll()); - - Assert.assertEquals(1, resources.size()); - Assert.assertEquals(expectedResponse.getTriggersList().get(0), resources.get(0)); - - List actualRequests = mockService.getRequestPaths(); - Assert.assertEquals(1, actualRequests.size()); - - String apiClientHeaderKey = - mockService - .getRequestHeaders() - .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) - .iterator() - .next(); - Assert.assertTrue( - GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() - .matcher(apiClientHeaderKey) - .matches()); - } - - @Test - public void listBuildTriggersExceptionTest() throws Exception { - ApiException exception = - ApiExceptionFactory.createException( - new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); - mockService.addException(exception); - - try { - String projectId = "projectId-1530"; - client.listBuildTriggers(projectId); - Assert.fail("No exception raised"); - } catch (InvalidArgumentException e) { - // Expected exception. - } - } - - @Test - public void deleteBuildTriggerTest() throws Exception { - Empty expectedResponse = Empty.newBuilder().build(); - mockService.addResponse(expectedResponse); - - String projectId = "projectId-1530"; - String triggerId = "triggerId-6343"; - - client.deleteBuildTrigger(projectId, triggerId); - - List actualRequests = mockService.getRequestPaths(); - Assert.assertEquals(1, actualRequests.size()); - - String apiClientHeaderKey = - mockService - .getRequestHeaders() - .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) - .iterator() - .next(); - Assert.assertTrue( - GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() - .matcher(apiClientHeaderKey) - .matches()); - } - - @Test - public void deleteBuildTriggerExceptionTest() throws Exception { - ApiException exception = - ApiExceptionFactory.createException( - new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); - mockService.addException(exception); - - try { - String projectId = "projectId-1530"; - String triggerId = "triggerId-6343"; - client.deleteBuildTrigger(projectId, triggerId); - Assert.fail("No exception raised"); - } catch (InvalidArgumentException e) { - // Expected exception. - } - } - - @Test - public void updateBuildTriggerTest() throws Exception { - BuildTrigger expectedResponse = - BuildTrigger.newBuilder() - .setResourceName("resourceName-384566343") - .setId("id3355") - .setDescription("description-1724546052") - .setName(BuildTriggerName.ofProjectTriggerName("[PROJECT]", "[TRIGGER]").toString()) - .addAllTags(new ArrayList()) - .setTriggerTemplate(RepoSource.newBuilder().build()) - .setGithub(GitHubEventsConfig.newBuilder().build()) - .setPubsubConfig(PubsubConfig.newBuilder().build()) - .setWebhookConfig(WebhookConfig.newBuilder().build()) - .setCreateTime(Timestamp.newBuilder().build()) - .setDisabled(true) - .putAllSubstitutions(new HashMap()) - .addAllIgnoredFiles(new ArrayList()) - .addAllIncludedFiles(new ArrayList()) - .setFilter("filter-1274492040") - .setServiceAccount("serviceAccount1079137720") - .build(); - mockService.addResponse(expectedResponse); - - String projectId = "projectId-1530"; - String triggerId = "triggerId-6343"; - BuildTrigger trigger = - BuildTrigger.newBuilder() - .setResourceName("resourceName-384566343") - .setId("id3355") - .setDescription("description-1724546052") - .setName(BuildTriggerName.ofProjectTriggerName("[PROJECT]", "[TRIGGER]").toString()) - .addAllTags(new ArrayList()) - .setTriggerTemplate(RepoSource.newBuilder().build()) - .setGithub(GitHubEventsConfig.newBuilder().build()) - .setPubsubConfig(PubsubConfig.newBuilder().build()) - .setWebhookConfig(WebhookConfig.newBuilder().build()) - .setCreateTime(Timestamp.newBuilder().build()) - .setDisabled(true) - .putAllSubstitutions(new HashMap()) - .addAllIgnoredFiles(new ArrayList()) - .addAllIncludedFiles(new ArrayList()) - .setFilter("filter-1274492040") - .setServiceAccount("serviceAccount1079137720") - .build(); - - BuildTrigger actualResponse = client.updateBuildTrigger(projectId, triggerId, trigger); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockService.getRequestPaths(); - Assert.assertEquals(1, actualRequests.size()); - - String apiClientHeaderKey = - mockService - .getRequestHeaders() - .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) - .iterator() - .next(); - Assert.assertTrue( - GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() - .matcher(apiClientHeaderKey) - .matches()); - } - - @Test - public void updateBuildTriggerExceptionTest() throws Exception { - ApiException exception = - ApiExceptionFactory.createException( - new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); - mockService.addException(exception); - - try { - String projectId = "projectId-1530"; - String triggerId = "triggerId-6343"; - BuildTrigger trigger = - BuildTrigger.newBuilder() - .setResourceName("resourceName-384566343") - .setId("id3355") - .setDescription("description-1724546052") - .setName(BuildTriggerName.ofProjectTriggerName("[PROJECT]", "[TRIGGER]").toString()) - .addAllTags(new ArrayList()) - .setTriggerTemplate(RepoSource.newBuilder().build()) - .setGithub(GitHubEventsConfig.newBuilder().build()) - .setPubsubConfig(PubsubConfig.newBuilder().build()) - .setWebhookConfig(WebhookConfig.newBuilder().build()) - .setCreateTime(Timestamp.newBuilder().build()) - .setDisabled(true) - .putAllSubstitutions(new HashMap()) - .addAllIgnoredFiles(new ArrayList()) - .addAllIncludedFiles(new ArrayList()) - .setFilter("filter-1274492040") - .setServiceAccount("serviceAccount1079137720") - .build(); - client.updateBuildTrigger(projectId, triggerId, trigger); - Assert.fail("No exception raised"); - } catch (InvalidArgumentException e) { - // Expected exception. - } - } - - @Test - public void runBuildTriggerTest() throws Exception { - Build expectedResponse = - Build.newBuilder() - .setName(BuildName.ofProjectBuildName("[PROJECT]", "[BUILD]").toString()) - .setId("id3355") - .setProjectId("projectId-894832108") - .setStatusDetail("statusDetail1651087075") - .setSource(Source.newBuilder().build()) - .addAllSteps(new ArrayList()) - .setResults(Results.newBuilder().build()) - .setCreateTime(Timestamp.newBuilder().build()) - .setStartTime(Timestamp.newBuilder().build()) - .setFinishTime(Timestamp.newBuilder().build()) - .setTimeout(Duration.newBuilder().build()) - .addAllImages(new ArrayList()) - .setQueueTtl(Duration.newBuilder().build()) - .setArtifacts(Artifacts.newBuilder().build()) - .setLogsBucket("logsBucket1592573049") - .setSourceProvenance(SourceProvenance.newBuilder().build()) - .setBuildTriggerId("buildTriggerId781747749") - .setOptions(BuildOptions.newBuilder().build()) - .setLogUrl("logUrl-1097354357") - .putAllSubstitutions(new HashMap()) - .addAllTags(new ArrayList()) - .addAllSecrets(new ArrayList()) - .putAllTiming(new HashMap()) - .setApproval(BuildApproval.newBuilder().build()) - .setServiceAccount("serviceAccount1079137720") - .setAvailableSecrets(Secrets.newBuilder().build()) - .addAllWarnings(new ArrayList()) - .setFailureInfo(Build.FailureInfo.newBuilder().build()) - .build(); - Operation resultOperation = - Operation.newBuilder() - .setName("runBuildTriggerTest") - .setDone(true) - .setResponse(Any.pack(expectedResponse)) - .build(); - mockService.addResponse(resultOperation); - - String projectId = "projectId-1530"; - String triggerId = "triggerId-6343"; - RepoSource source = RepoSource.newBuilder().build(); - - Build actualResponse = client.runBuildTriggerAsync(projectId, triggerId, source).get(); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockService.getRequestPaths(); - Assert.assertEquals(1, actualRequests.size()); - - String apiClientHeaderKey = - mockService - .getRequestHeaders() - .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) - .iterator() - .next(); - Assert.assertTrue( - GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() - .matcher(apiClientHeaderKey) - .matches()); - } - - @Test - public void runBuildTriggerExceptionTest() throws Exception { - ApiException exception = - ApiExceptionFactory.createException( - new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); - mockService.addException(exception); - - try { - String projectId = "projectId-1530"; - String triggerId = "triggerId-6343"; - RepoSource source = RepoSource.newBuilder().build(); - client.runBuildTriggerAsync(projectId, triggerId, source).get(); - Assert.fail("No exception raised"); - } catch (ExecutionException e) { - } - } - - @Test - public void receiveTriggerWebhookTest() throws Exception { - ReceiveTriggerWebhookResponse expectedResponse = - ReceiveTriggerWebhookResponse.newBuilder().build(); - mockService.addResponse(expectedResponse); - - ReceiveTriggerWebhookRequest request = - ReceiveTriggerWebhookRequest.newBuilder() - .setName("name3373707") - .setBody(HttpBody.newBuilder().build()) - .setProjectId("projectId-1530") - .setTrigger("trigger-3106") - .setSecret("secret-906277200") - .build(); - - ReceiveTriggerWebhookResponse actualResponse = client.receiveTriggerWebhook(request); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockService.getRequestPaths(); - Assert.assertEquals(1, actualRequests.size()); - - String apiClientHeaderKey = - mockService - .getRequestHeaders() - .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) - .iterator() - .next(); - Assert.assertTrue( - GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() - .matcher(apiClientHeaderKey) - .matches()); - } - - @Test - public void receiveTriggerWebhookExceptionTest() throws Exception { - ApiException exception = - ApiExceptionFactory.createException( - new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); - mockService.addException(exception); - - try { - ReceiveTriggerWebhookRequest request = - ReceiveTriggerWebhookRequest.newBuilder() - .setName("name3373707") - .setBody(HttpBody.newBuilder().build()) - .setProjectId("projectId-1530") - .setTrigger("trigger-3106") - .setSecret("secret-906277200") - .build(); - client.receiveTriggerWebhook(request); - Assert.fail("No exception raised"); - } catch (InvalidArgumentException e) { - // Expected exception. - } - } - - @Test - public void createWorkerPoolTest() throws Exception { - WorkerPool expectedResponse = - WorkerPool.newBuilder() - .setName(WorkerPoolName.of("[PROJECT]", "[LOCATION]", "[WORKER_POOL]").toString()) - .setDisplayName("displayName1714148973") - .setUid("uid115792") - .putAllAnnotations(new HashMap()) - .setCreateTime(Timestamp.newBuilder().build()) - .setUpdateTime(Timestamp.newBuilder().build()) - .setDeleteTime(Timestamp.newBuilder().build()) - .setEtag("etag3123477") - .build(); - Operation resultOperation = - Operation.newBuilder() - .setName("createWorkerPoolTest") - .setDone(true) - .setResponse(Any.pack(expectedResponse)) - .build(); - mockService.addResponse(resultOperation); - - LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); - WorkerPool workerPool = WorkerPool.newBuilder().build(); - String workerPoolId = "workerPoolId-46320779"; - - WorkerPool actualResponse = - client.createWorkerPoolAsync(parent, workerPool, workerPoolId).get(); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockService.getRequestPaths(); - Assert.assertEquals(1, actualRequests.size()); - - String apiClientHeaderKey = - mockService - .getRequestHeaders() - .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) - .iterator() - .next(); - Assert.assertTrue( - GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() - .matcher(apiClientHeaderKey) - .matches()); - } - - @Test - public void createWorkerPoolExceptionTest() throws Exception { - ApiException exception = - ApiExceptionFactory.createException( - new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); - mockService.addException(exception); - - try { - LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); - WorkerPool workerPool = WorkerPool.newBuilder().build(); - String workerPoolId = "workerPoolId-46320779"; - client.createWorkerPoolAsync(parent, workerPool, workerPoolId).get(); - Assert.fail("No exception raised"); - } catch (ExecutionException e) { - } - } - - @Test - public void createWorkerPoolTest2() throws Exception { - WorkerPool expectedResponse = - WorkerPool.newBuilder() - .setName(WorkerPoolName.of("[PROJECT]", "[LOCATION]", "[WORKER_POOL]").toString()) - .setDisplayName("displayName1714148973") - .setUid("uid115792") - .putAllAnnotations(new HashMap()) - .setCreateTime(Timestamp.newBuilder().build()) - .setUpdateTime(Timestamp.newBuilder().build()) - .setDeleteTime(Timestamp.newBuilder().build()) - .setEtag("etag3123477") - .build(); - Operation resultOperation = - Operation.newBuilder() - .setName("createWorkerPoolTest") - .setDone(true) - .setResponse(Any.pack(expectedResponse)) - .build(); - mockService.addResponse(resultOperation); - - String parent = "projects/project-5833/locations/location-5833"; - WorkerPool workerPool = WorkerPool.newBuilder().build(); - String workerPoolId = "workerPoolId-46320779"; - - WorkerPool actualResponse = - client.createWorkerPoolAsync(parent, workerPool, workerPoolId).get(); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockService.getRequestPaths(); - Assert.assertEquals(1, actualRequests.size()); - - String apiClientHeaderKey = - mockService - .getRequestHeaders() - .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) - .iterator() - .next(); - Assert.assertTrue( - GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() - .matcher(apiClientHeaderKey) - .matches()); - } - - @Test - public void createWorkerPoolExceptionTest2() throws Exception { - ApiException exception = - ApiExceptionFactory.createException( - new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); - mockService.addException(exception); - - try { - String parent = "projects/project-5833/locations/location-5833"; - WorkerPool workerPool = WorkerPool.newBuilder().build(); - String workerPoolId = "workerPoolId-46320779"; - client.createWorkerPoolAsync(parent, workerPool, workerPoolId).get(); - Assert.fail("No exception raised"); - } catch (ExecutionException e) { - } - } - - @Test - public void getWorkerPoolTest() throws Exception { - WorkerPool expectedResponse = - WorkerPool.newBuilder() - .setName(WorkerPoolName.of("[PROJECT]", "[LOCATION]", "[WORKER_POOL]").toString()) - .setDisplayName("displayName1714148973") - .setUid("uid115792") - .putAllAnnotations(new HashMap()) - .setCreateTime(Timestamp.newBuilder().build()) - .setUpdateTime(Timestamp.newBuilder().build()) - .setDeleteTime(Timestamp.newBuilder().build()) - .setEtag("etag3123477") - .build(); - mockService.addResponse(expectedResponse); - - WorkerPoolName name = WorkerPoolName.of("[PROJECT]", "[LOCATION]", "[WORKER_POOL]"); - - WorkerPool actualResponse = client.getWorkerPool(name); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockService.getRequestPaths(); - Assert.assertEquals(1, actualRequests.size()); - - String apiClientHeaderKey = - mockService - .getRequestHeaders() - .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) - .iterator() - .next(); - Assert.assertTrue( - GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() - .matcher(apiClientHeaderKey) - .matches()); - } - - @Test - public void getWorkerPoolExceptionTest() throws Exception { - ApiException exception = - ApiExceptionFactory.createException( - new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); - mockService.addException(exception); - - try { - WorkerPoolName name = WorkerPoolName.of("[PROJECT]", "[LOCATION]", "[WORKER_POOL]"); - client.getWorkerPool(name); - Assert.fail("No exception raised"); - } catch (InvalidArgumentException e) { - // Expected exception. - } - } - - @Test - public void getWorkerPoolTest2() throws Exception { - WorkerPool expectedResponse = - WorkerPool.newBuilder() - .setName(WorkerPoolName.of("[PROJECT]", "[LOCATION]", "[WORKER_POOL]").toString()) - .setDisplayName("displayName1714148973") - .setUid("uid115792") - .putAllAnnotations(new HashMap()) - .setCreateTime(Timestamp.newBuilder().build()) - .setUpdateTime(Timestamp.newBuilder().build()) - .setDeleteTime(Timestamp.newBuilder().build()) - .setEtag("etag3123477") - .build(); - mockService.addResponse(expectedResponse); - - String name = "projects/project-9807/locations/location-9807/workerPools/workerPool-9807"; - - WorkerPool actualResponse = client.getWorkerPool(name); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockService.getRequestPaths(); - Assert.assertEquals(1, actualRequests.size()); - - String apiClientHeaderKey = - mockService - .getRequestHeaders() - .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) - .iterator() - .next(); - Assert.assertTrue( - GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() - .matcher(apiClientHeaderKey) - .matches()); - } - - @Test - public void getWorkerPoolExceptionTest2() throws Exception { - ApiException exception = - ApiExceptionFactory.createException( - new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); - mockService.addException(exception); - - try { - String name = "projects/project-9807/locations/location-9807/workerPools/workerPool-9807"; - client.getWorkerPool(name); - Assert.fail("No exception raised"); - } catch (InvalidArgumentException e) { - // Expected exception. - } - } - - @Test - public void deleteWorkerPoolTest() throws Exception { - Empty expectedResponse = Empty.newBuilder().build(); - Operation resultOperation = - Operation.newBuilder() - .setName("deleteWorkerPoolTest") - .setDone(true) - .setResponse(Any.pack(expectedResponse)) - .build(); - mockService.addResponse(resultOperation); - - WorkerPoolName name = WorkerPoolName.of("[PROJECT]", "[LOCATION]", "[WORKER_POOL]"); - - client.deleteWorkerPoolAsync(name).get(); - - List actualRequests = mockService.getRequestPaths(); - Assert.assertEquals(1, actualRequests.size()); - - String apiClientHeaderKey = - mockService - .getRequestHeaders() - .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) - .iterator() - .next(); - Assert.assertTrue( - GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() - .matcher(apiClientHeaderKey) - .matches()); - } - - @Test - public void deleteWorkerPoolExceptionTest() throws Exception { - ApiException exception = - ApiExceptionFactory.createException( - new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); - mockService.addException(exception); - - try { - WorkerPoolName name = WorkerPoolName.of("[PROJECT]", "[LOCATION]", "[WORKER_POOL]"); - client.deleteWorkerPoolAsync(name).get(); - Assert.fail("No exception raised"); - } catch (ExecutionException e) { - } - } - - @Test - public void deleteWorkerPoolTest2() throws Exception { - Empty expectedResponse = Empty.newBuilder().build(); - Operation resultOperation = - Operation.newBuilder() - .setName("deleteWorkerPoolTest") - .setDone(true) - .setResponse(Any.pack(expectedResponse)) - .build(); - mockService.addResponse(resultOperation); - - String name = "projects/project-9807/locations/location-9807/workerPools/workerPool-9807"; - - client.deleteWorkerPoolAsync(name).get(); - - List actualRequests = mockService.getRequestPaths(); - Assert.assertEquals(1, actualRequests.size()); - - String apiClientHeaderKey = - mockService - .getRequestHeaders() - .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) - .iterator() - .next(); - Assert.assertTrue( - GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() - .matcher(apiClientHeaderKey) - .matches()); - } - - @Test - public void deleteWorkerPoolExceptionTest2() throws Exception { - ApiException exception = - ApiExceptionFactory.createException( - new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); - mockService.addException(exception); - - try { - String name = "projects/project-9807/locations/location-9807/workerPools/workerPool-9807"; - client.deleteWorkerPoolAsync(name).get(); - Assert.fail("No exception raised"); - } catch (ExecutionException e) { - } - } - - @Test - public void updateWorkerPoolTest() throws Exception { - WorkerPool expectedResponse = - WorkerPool.newBuilder() - .setName(WorkerPoolName.of("[PROJECT]", "[LOCATION]", "[WORKER_POOL]").toString()) - .setDisplayName("displayName1714148973") - .setUid("uid115792") - .putAllAnnotations(new HashMap()) - .setCreateTime(Timestamp.newBuilder().build()) - .setUpdateTime(Timestamp.newBuilder().build()) - .setDeleteTime(Timestamp.newBuilder().build()) - .setEtag("etag3123477") - .build(); - Operation resultOperation = - Operation.newBuilder() - .setName("updateWorkerPoolTest") - .setDone(true) - .setResponse(Any.pack(expectedResponse)) - .build(); - mockService.addResponse(resultOperation); - - WorkerPool workerPool = - WorkerPool.newBuilder() - .setName(WorkerPoolName.of("[PROJECT]", "[LOCATION]", "[WORKER_POOL]").toString()) - .setDisplayName("displayName1714148973") - .setUid("uid115792") - .putAllAnnotations(new HashMap()) - .setCreateTime(Timestamp.newBuilder().build()) - .setUpdateTime(Timestamp.newBuilder().build()) - .setDeleteTime(Timestamp.newBuilder().build()) - .setEtag("etag3123477") - .build(); - FieldMask updateMask = FieldMask.newBuilder().build(); - - WorkerPool actualResponse = client.updateWorkerPoolAsync(workerPool, updateMask).get(); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockService.getRequestPaths(); - Assert.assertEquals(1, actualRequests.size()); - - String apiClientHeaderKey = - mockService - .getRequestHeaders() - .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) - .iterator() - .next(); - Assert.assertTrue( - GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() - .matcher(apiClientHeaderKey) - .matches()); - } - - @Test - public void updateWorkerPoolExceptionTest() throws Exception { - ApiException exception = - ApiExceptionFactory.createException( - new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); - mockService.addException(exception); - - try { - WorkerPool workerPool = - WorkerPool.newBuilder() - .setName(WorkerPoolName.of("[PROJECT]", "[LOCATION]", "[WORKER_POOL]").toString()) - .setDisplayName("displayName1714148973") - .setUid("uid115792") - .putAllAnnotations(new HashMap()) - .setCreateTime(Timestamp.newBuilder().build()) - .setUpdateTime(Timestamp.newBuilder().build()) - .setDeleteTime(Timestamp.newBuilder().build()) - .setEtag("etag3123477") - .build(); - FieldMask updateMask = FieldMask.newBuilder().build(); - client.updateWorkerPoolAsync(workerPool, updateMask).get(); - Assert.fail("No exception raised"); - } catch (ExecutionException e) { - } - } - - @Test - public void listWorkerPoolsTest() throws Exception { - WorkerPool responsesElement = WorkerPool.newBuilder().build(); - ListWorkerPoolsResponse expectedResponse = - ListWorkerPoolsResponse.newBuilder() - .setNextPageToken("") - .addAllWorkerPools(Arrays.asList(responsesElement)) - .build(); - mockService.addResponse(expectedResponse); - - LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); - - ListWorkerPoolsPagedResponse pagedListResponse = client.listWorkerPools(parent); - - List resources = Lists.newArrayList(pagedListResponse.iterateAll()); - - Assert.assertEquals(1, resources.size()); - Assert.assertEquals(expectedResponse.getWorkerPoolsList().get(0), resources.get(0)); - - List actualRequests = mockService.getRequestPaths(); - Assert.assertEquals(1, actualRequests.size()); - - String apiClientHeaderKey = - mockService - .getRequestHeaders() - .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) - .iterator() - .next(); - Assert.assertTrue( - GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() - .matcher(apiClientHeaderKey) - .matches()); - } - - @Test - public void listWorkerPoolsExceptionTest() throws Exception { - ApiException exception = - ApiExceptionFactory.createException( - new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); - mockService.addException(exception); - - try { - LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); - client.listWorkerPools(parent); - Assert.fail("No exception raised"); - } catch (InvalidArgumentException e) { - // Expected exception. - } - } - - @Test - public void listWorkerPoolsTest2() throws Exception { - WorkerPool responsesElement = WorkerPool.newBuilder().build(); - ListWorkerPoolsResponse expectedResponse = - ListWorkerPoolsResponse.newBuilder() - .setNextPageToken("") - .addAllWorkerPools(Arrays.asList(responsesElement)) - .build(); - mockService.addResponse(expectedResponse); - - String parent = "projects/project-5833/locations/location-5833"; - - ListWorkerPoolsPagedResponse pagedListResponse = client.listWorkerPools(parent); - - List resources = Lists.newArrayList(pagedListResponse.iterateAll()); - - Assert.assertEquals(1, resources.size()); - Assert.assertEquals(expectedResponse.getWorkerPoolsList().get(0), resources.get(0)); - - List actualRequests = mockService.getRequestPaths(); - Assert.assertEquals(1, actualRequests.size()); - - String apiClientHeaderKey = - mockService - .getRequestHeaders() - .get(ApiClientHeaderProvider.getDefaultApiClientHeaderKey()) - .iterator() - .next(); - Assert.assertTrue( - GaxHttpJsonProperties.getDefaultApiClientHeaderPattern() - .matcher(apiClientHeaderKey) - .matches()); - } - - @Test - public void listWorkerPoolsExceptionTest2() throws Exception { - ApiException exception = - ApiExceptionFactory.createException( - new Exception(), FakeStatusCode.of(StatusCode.Code.INVALID_ARGUMENT), false); - mockService.addException(exception); - - try { - String parent = "projects/project-5833/locations/location-5833"; - client.listWorkerPools(parent); - Assert.fail("No exception raised"); - } catch (InvalidArgumentException e) { - // Expected exception. - } - } -} diff --git a/google-cloud-build/src/test/java/com/google/cloud/devtools/cloudbuild/v1/CloudBuildClientTest.java b/google-cloud-build/src/test/java/com/google/cloud/devtools/cloudbuild/v1/CloudBuildClientTest.java deleted file mode 100644 index e9337378..00000000 --- a/google-cloud-build/src/test/java/com/google/cloud/devtools/cloudbuild/v1/CloudBuildClientTest.java +++ /dev/null @@ -1,1372 +0,0 @@ -/* - * Copyright 2022 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package com.google.cloud.devtools.cloudbuild.v1; - -import static com.google.cloud.devtools.cloudbuild.v1.CloudBuildClient.ListBuildTriggersPagedResponse; -import static com.google.cloud.devtools.cloudbuild.v1.CloudBuildClient.ListBuildsPagedResponse; -import static com.google.cloud.devtools.cloudbuild.v1.CloudBuildClient.ListWorkerPoolsPagedResponse; - -import com.google.api.HttpBody; -import com.google.api.gax.core.NoCredentialsProvider; -import com.google.api.gax.grpc.GaxGrpcProperties; -import com.google.api.gax.grpc.testing.LocalChannelProvider; -import com.google.api.gax.grpc.testing.MockGrpcService; -import com.google.api.gax.grpc.testing.MockServiceHelper; -import com.google.api.gax.rpc.ApiClientHeaderProvider; -import com.google.api.gax.rpc.InvalidArgumentException; -import com.google.api.gax.rpc.StatusCode; -import com.google.cloudbuild.v1.ApprovalResult; -import com.google.cloudbuild.v1.ApproveBuildRequest; -import com.google.cloudbuild.v1.Artifacts; -import com.google.cloudbuild.v1.Build; -import com.google.cloudbuild.v1.BuildApproval; -import com.google.cloudbuild.v1.BuildName; -import com.google.cloudbuild.v1.BuildOptions; -import com.google.cloudbuild.v1.BuildStep; -import com.google.cloudbuild.v1.BuildTrigger; -import com.google.cloudbuild.v1.BuildTriggerName; -import com.google.cloudbuild.v1.CancelBuildRequest; -import com.google.cloudbuild.v1.CreateBuildRequest; -import com.google.cloudbuild.v1.CreateBuildTriggerRequest; -import com.google.cloudbuild.v1.CreateWorkerPoolRequest; -import com.google.cloudbuild.v1.DeleteBuildTriggerRequest; -import com.google.cloudbuild.v1.DeleteWorkerPoolRequest; -import com.google.cloudbuild.v1.GetBuildRequest; -import com.google.cloudbuild.v1.GetBuildTriggerRequest; -import com.google.cloudbuild.v1.GetWorkerPoolRequest; -import com.google.cloudbuild.v1.GitHubEventsConfig; -import com.google.cloudbuild.v1.ListBuildTriggersRequest; -import com.google.cloudbuild.v1.ListBuildTriggersResponse; -import com.google.cloudbuild.v1.ListBuildsRequest; -import com.google.cloudbuild.v1.ListBuildsResponse; -import com.google.cloudbuild.v1.ListWorkerPoolsRequest; -import com.google.cloudbuild.v1.ListWorkerPoolsResponse; -import com.google.cloudbuild.v1.LocationName; -import com.google.cloudbuild.v1.PubsubConfig; -import com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest; -import com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse; -import com.google.cloudbuild.v1.RepoSource; -import com.google.cloudbuild.v1.Results; -import com.google.cloudbuild.v1.RetryBuildRequest; -import com.google.cloudbuild.v1.RunBuildTriggerRequest; -import com.google.cloudbuild.v1.Secret; -import com.google.cloudbuild.v1.Secrets; -import com.google.cloudbuild.v1.Source; -import com.google.cloudbuild.v1.SourceProvenance; -import com.google.cloudbuild.v1.TimeSpan; -import com.google.cloudbuild.v1.UpdateBuildTriggerRequest; -import com.google.cloudbuild.v1.UpdateWorkerPoolRequest; -import com.google.cloudbuild.v1.WebhookConfig; -import com.google.cloudbuild.v1.WorkerPool; -import com.google.cloudbuild.v1.WorkerPoolName; -import com.google.common.collect.Lists; -import com.google.longrunning.Operation; -import com.google.protobuf.AbstractMessage; -import com.google.protobuf.Any; -import com.google.protobuf.Duration; -import com.google.protobuf.Empty; -import com.google.protobuf.FieldMask; -import com.google.protobuf.Timestamp; -import io.grpc.StatusRuntimeException; -import java.io.IOException; -import java.util.ArrayList; -import java.util.Arrays; -import java.util.HashMap; -import java.util.List; -import java.util.UUID; -import java.util.concurrent.ExecutionException; -import javax.annotation.Generated; -import org.junit.After; -import org.junit.AfterClass; -import org.junit.Assert; -import org.junit.Before; -import org.junit.BeforeClass; -import org.junit.Test; - -@Generated("by gapic-generator-java") -public class CloudBuildClientTest { - private static MockCloudBuild mockCloudBuild; - private static MockServiceHelper mockServiceHelper; - private LocalChannelProvider channelProvider; - private CloudBuildClient client; - - @BeforeClass - public static void startStaticServer() { - mockCloudBuild = new MockCloudBuild(); - mockServiceHelper = - new MockServiceHelper( - UUID.randomUUID().toString(), Arrays.asList(mockCloudBuild)); - mockServiceHelper.start(); - } - - @AfterClass - public static void stopServer() { - mockServiceHelper.stop(); - } - - @Before - public void setUp() throws IOException { - mockServiceHelper.reset(); - channelProvider = mockServiceHelper.createChannelProvider(); - CloudBuildSettings settings = - CloudBuildSettings.newBuilder() - .setTransportChannelProvider(channelProvider) - .setCredentialsProvider(NoCredentialsProvider.create()) - .build(); - client = CloudBuildClient.create(settings); - } - - @After - public void tearDown() throws Exception { - client.close(); - } - - @Test - public void createBuildTest() throws Exception { - Build expectedResponse = - Build.newBuilder() - .setName(BuildName.ofProjectBuildName("[PROJECT]", "[BUILD]").toString()) - .setId("id3355") - .setProjectId("projectId-894832108") - .setStatusDetail("statusDetail1651087075") - .setSource(Source.newBuilder().build()) - .addAllSteps(new ArrayList()) - .setResults(Results.newBuilder().build()) - .setCreateTime(Timestamp.newBuilder().build()) - .setStartTime(Timestamp.newBuilder().build()) - .setFinishTime(Timestamp.newBuilder().build()) - .setTimeout(Duration.newBuilder().build()) - .addAllImages(new ArrayList()) - .setQueueTtl(Duration.newBuilder().build()) - .setArtifacts(Artifacts.newBuilder().build()) - .setLogsBucket("logsBucket1592573049") - .setSourceProvenance(SourceProvenance.newBuilder().build()) - .setBuildTriggerId("buildTriggerId781747749") - .setOptions(BuildOptions.newBuilder().build()) - .setLogUrl("logUrl-1097354357") - .putAllSubstitutions(new HashMap()) - .addAllTags(new ArrayList()) - .addAllSecrets(new ArrayList()) - .putAllTiming(new HashMap()) - .setApproval(BuildApproval.newBuilder().build()) - .setServiceAccount("serviceAccount1079137720") - .setAvailableSecrets(Secrets.newBuilder().build()) - .addAllWarnings(new ArrayList()) - .setFailureInfo(Build.FailureInfo.newBuilder().build()) - .build(); - Operation resultOperation = - Operation.newBuilder() - .setName("createBuildTest") - .setDone(true) - .setResponse(Any.pack(expectedResponse)) - .build(); - mockCloudBuild.addResponse(resultOperation); - - String projectId = "projectId-894832108"; - Build build = Build.newBuilder().build(); - - Build actualResponse = client.createBuildAsync(projectId, build).get(); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockCloudBuild.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - CreateBuildRequest actualRequest = ((CreateBuildRequest) actualRequests.get(0)); - - Assert.assertEquals(projectId, actualRequest.getProjectId()); - Assert.assertEquals(build, actualRequest.getBuild()); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - public void createBuildExceptionTest() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); - mockCloudBuild.addException(exception); - - try { - String projectId = "projectId-894832108"; - Build build = Build.newBuilder().build(); - client.createBuildAsync(projectId, build).get(); - Assert.fail("No exception raised"); - } catch (ExecutionException e) { - Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); - InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); - Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); - } - } - - @Test - public void getBuildTest() throws Exception { - Build expectedResponse = - Build.newBuilder() - .setName(BuildName.ofProjectBuildName("[PROJECT]", "[BUILD]").toString()) - .setId("id3355") - .setProjectId("projectId-894832108") - .setStatusDetail("statusDetail1651087075") - .setSource(Source.newBuilder().build()) - .addAllSteps(new ArrayList()) - .setResults(Results.newBuilder().build()) - .setCreateTime(Timestamp.newBuilder().build()) - .setStartTime(Timestamp.newBuilder().build()) - .setFinishTime(Timestamp.newBuilder().build()) - .setTimeout(Duration.newBuilder().build()) - .addAllImages(new ArrayList()) - .setQueueTtl(Duration.newBuilder().build()) - .setArtifacts(Artifacts.newBuilder().build()) - .setLogsBucket("logsBucket1592573049") - .setSourceProvenance(SourceProvenance.newBuilder().build()) - .setBuildTriggerId("buildTriggerId781747749") - .setOptions(BuildOptions.newBuilder().build()) - .setLogUrl("logUrl-1097354357") - .putAllSubstitutions(new HashMap()) - .addAllTags(new ArrayList()) - .addAllSecrets(new ArrayList()) - .putAllTiming(new HashMap()) - .setApproval(BuildApproval.newBuilder().build()) - .setServiceAccount("serviceAccount1079137720") - .setAvailableSecrets(Secrets.newBuilder().build()) - .addAllWarnings(new ArrayList()) - .setFailureInfo(Build.FailureInfo.newBuilder().build()) - .build(); - mockCloudBuild.addResponse(expectedResponse); - - String projectId = "projectId-894832108"; - String id = "id3355"; - - Build actualResponse = client.getBuild(projectId, id); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockCloudBuild.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - GetBuildRequest actualRequest = ((GetBuildRequest) actualRequests.get(0)); - - Assert.assertEquals(projectId, actualRequest.getProjectId()); - Assert.assertEquals(id, actualRequest.getId()); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - public void getBuildExceptionTest() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); - mockCloudBuild.addException(exception); - - try { - String projectId = "projectId-894832108"; - String id = "id3355"; - client.getBuild(projectId, id); - Assert.fail("No exception raised"); - } catch (InvalidArgumentException e) { - // Expected exception. - } - } - - @Test - public void listBuildsTest() throws Exception { - Build responsesElement = Build.newBuilder().build(); - ListBuildsResponse expectedResponse = - ListBuildsResponse.newBuilder() - .setNextPageToken("") - .addAllBuilds(Arrays.asList(responsesElement)) - .build(); - mockCloudBuild.addResponse(expectedResponse); - - String projectId = "projectId-894832108"; - String filter = "filter-1274492040"; - - ListBuildsPagedResponse pagedListResponse = client.listBuilds(projectId, filter); - - List resources = Lists.newArrayList(pagedListResponse.iterateAll()); - - Assert.assertEquals(1, resources.size()); - Assert.assertEquals(expectedResponse.getBuildsList().get(0), resources.get(0)); - - List actualRequests = mockCloudBuild.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - ListBuildsRequest actualRequest = ((ListBuildsRequest) actualRequests.get(0)); - - Assert.assertEquals(projectId, actualRequest.getProjectId()); - Assert.assertEquals(filter, actualRequest.getFilter()); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - public void listBuildsExceptionTest() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); - mockCloudBuild.addException(exception); - - try { - String projectId = "projectId-894832108"; - String filter = "filter-1274492040"; - client.listBuilds(projectId, filter); - Assert.fail("No exception raised"); - } catch (InvalidArgumentException e) { - // Expected exception. - } - } - - @Test - public void cancelBuildTest() throws Exception { - Build expectedResponse = - Build.newBuilder() - .setName(BuildName.ofProjectBuildName("[PROJECT]", "[BUILD]").toString()) - .setId("id3355") - .setProjectId("projectId-894832108") - .setStatusDetail("statusDetail1651087075") - .setSource(Source.newBuilder().build()) - .addAllSteps(new ArrayList()) - .setResults(Results.newBuilder().build()) - .setCreateTime(Timestamp.newBuilder().build()) - .setStartTime(Timestamp.newBuilder().build()) - .setFinishTime(Timestamp.newBuilder().build()) - .setTimeout(Duration.newBuilder().build()) - .addAllImages(new ArrayList()) - .setQueueTtl(Duration.newBuilder().build()) - .setArtifacts(Artifacts.newBuilder().build()) - .setLogsBucket("logsBucket1592573049") - .setSourceProvenance(SourceProvenance.newBuilder().build()) - .setBuildTriggerId("buildTriggerId781747749") - .setOptions(BuildOptions.newBuilder().build()) - .setLogUrl("logUrl-1097354357") - .putAllSubstitutions(new HashMap()) - .addAllTags(new ArrayList()) - .addAllSecrets(new ArrayList()) - .putAllTiming(new HashMap()) - .setApproval(BuildApproval.newBuilder().build()) - .setServiceAccount("serviceAccount1079137720") - .setAvailableSecrets(Secrets.newBuilder().build()) - .addAllWarnings(new ArrayList()) - .setFailureInfo(Build.FailureInfo.newBuilder().build()) - .build(); - mockCloudBuild.addResponse(expectedResponse); - - String projectId = "projectId-894832108"; - String id = "id3355"; - - Build actualResponse = client.cancelBuild(projectId, id); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockCloudBuild.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - CancelBuildRequest actualRequest = ((CancelBuildRequest) actualRequests.get(0)); - - Assert.assertEquals(projectId, actualRequest.getProjectId()); - Assert.assertEquals(id, actualRequest.getId()); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - public void cancelBuildExceptionTest() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); - mockCloudBuild.addException(exception); - - try { - String projectId = "projectId-894832108"; - String id = "id3355"; - client.cancelBuild(projectId, id); - Assert.fail("No exception raised"); - } catch (InvalidArgumentException e) { - // Expected exception. - } - } - - @Test - public void retryBuildTest() throws Exception { - Build expectedResponse = - Build.newBuilder() - .setName(BuildName.ofProjectBuildName("[PROJECT]", "[BUILD]").toString()) - .setId("id3355") - .setProjectId("projectId-894832108") - .setStatusDetail("statusDetail1651087075") - .setSource(Source.newBuilder().build()) - .addAllSteps(new ArrayList()) - .setResults(Results.newBuilder().build()) - .setCreateTime(Timestamp.newBuilder().build()) - .setStartTime(Timestamp.newBuilder().build()) - .setFinishTime(Timestamp.newBuilder().build()) - .setTimeout(Duration.newBuilder().build()) - .addAllImages(new ArrayList()) - .setQueueTtl(Duration.newBuilder().build()) - .setArtifacts(Artifacts.newBuilder().build()) - .setLogsBucket("logsBucket1592573049") - .setSourceProvenance(SourceProvenance.newBuilder().build()) - .setBuildTriggerId("buildTriggerId781747749") - .setOptions(BuildOptions.newBuilder().build()) - .setLogUrl("logUrl-1097354357") - .putAllSubstitutions(new HashMap()) - .addAllTags(new ArrayList()) - .addAllSecrets(new ArrayList()) - .putAllTiming(new HashMap()) - .setApproval(BuildApproval.newBuilder().build()) - .setServiceAccount("serviceAccount1079137720") - .setAvailableSecrets(Secrets.newBuilder().build()) - .addAllWarnings(new ArrayList()) - .setFailureInfo(Build.FailureInfo.newBuilder().build()) - .build(); - Operation resultOperation = - Operation.newBuilder() - .setName("retryBuildTest") - .setDone(true) - .setResponse(Any.pack(expectedResponse)) - .build(); - mockCloudBuild.addResponse(resultOperation); - - String projectId = "projectId-894832108"; - String id = "id3355"; - - Build actualResponse = client.retryBuildAsync(projectId, id).get(); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockCloudBuild.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - RetryBuildRequest actualRequest = ((RetryBuildRequest) actualRequests.get(0)); - - Assert.assertEquals(projectId, actualRequest.getProjectId()); - Assert.assertEquals(id, actualRequest.getId()); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - public void retryBuildExceptionTest() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); - mockCloudBuild.addException(exception); - - try { - String projectId = "projectId-894832108"; - String id = "id3355"; - client.retryBuildAsync(projectId, id).get(); - Assert.fail("No exception raised"); - } catch (ExecutionException e) { - Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); - InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); - Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); - } - } - - @Test - public void approveBuildTest() throws Exception { - Build expectedResponse = - Build.newBuilder() - .setName(BuildName.ofProjectBuildName("[PROJECT]", "[BUILD]").toString()) - .setId("id3355") - .setProjectId("projectId-894832108") - .setStatusDetail("statusDetail1651087075") - .setSource(Source.newBuilder().build()) - .addAllSteps(new ArrayList()) - .setResults(Results.newBuilder().build()) - .setCreateTime(Timestamp.newBuilder().build()) - .setStartTime(Timestamp.newBuilder().build()) - .setFinishTime(Timestamp.newBuilder().build()) - .setTimeout(Duration.newBuilder().build()) - .addAllImages(new ArrayList()) - .setQueueTtl(Duration.newBuilder().build()) - .setArtifacts(Artifacts.newBuilder().build()) - .setLogsBucket("logsBucket1592573049") - .setSourceProvenance(SourceProvenance.newBuilder().build()) - .setBuildTriggerId("buildTriggerId781747749") - .setOptions(BuildOptions.newBuilder().build()) - .setLogUrl("logUrl-1097354357") - .putAllSubstitutions(new HashMap()) - .addAllTags(new ArrayList()) - .addAllSecrets(new ArrayList()) - .putAllTiming(new HashMap()) - .setApproval(BuildApproval.newBuilder().build()) - .setServiceAccount("serviceAccount1079137720") - .setAvailableSecrets(Secrets.newBuilder().build()) - .addAllWarnings(new ArrayList()) - .setFailureInfo(Build.FailureInfo.newBuilder().build()) - .build(); - Operation resultOperation = - Operation.newBuilder() - .setName("approveBuildTest") - .setDone(true) - .setResponse(Any.pack(expectedResponse)) - .build(); - mockCloudBuild.addResponse(resultOperation); - - String name = "name3373707"; - ApprovalResult approvalResult = ApprovalResult.newBuilder().build(); - - Build actualResponse = client.approveBuildAsync(name, approvalResult).get(); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockCloudBuild.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - ApproveBuildRequest actualRequest = ((ApproveBuildRequest) actualRequests.get(0)); - - Assert.assertEquals(name, actualRequest.getName()); - Assert.assertEquals(approvalResult, actualRequest.getApprovalResult()); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - public void approveBuildExceptionTest() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); - mockCloudBuild.addException(exception); - - try { - String name = "name3373707"; - ApprovalResult approvalResult = ApprovalResult.newBuilder().build(); - client.approveBuildAsync(name, approvalResult).get(); - Assert.fail("No exception raised"); - } catch (ExecutionException e) { - Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); - InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); - Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); - } - } - - @Test - public void createBuildTriggerTest() throws Exception { - BuildTrigger expectedResponse = - BuildTrigger.newBuilder() - .setResourceName("resourceName-384566343") - .setId("id3355") - .setDescription("description-1724546052") - .setName(BuildTriggerName.ofProjectTriggerName("[PROJECT]", "[TRIGGER]").toString()) - .addAllTags(new ArrayList()) - .setTriggerTemplate(RepoSource.newBuilder().build()) - .setGithub(GitHubEventsConfig.newBuilder().build()) - .setPubsubConfig(PubsubConfig.newBuilder().build()) - .setWebhookConfig(WebhookConfig.newBuilder().build()) - .setCreateTime(Timestamp.newBuilder().build()) - .setDisabled(true) - .putAllSubstitutions(new HashMap()) - .addAllIgnoredFiles(new ArrayList()) - .addAllIncludedFiles(new ArrayList()) - .setFilter("filter-1274492040") - .setServiceAccount("serviceAccount1079137720") - .build(); - mockCloudBuild.addResponse(expectedResponse); - - String projectId = "projectId-894832108"; - BuildTrigger trigger = BuildTrigger.newBuilder().build(); - - BuildTrigger actualResponse = client.createBuildTrigger(projectId, trigger); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockCloudBuild.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - CreateBuildTriggerRequest actualRequest = ((CreateBuildTriggerRequest) actualRequests.get(0)); - - Assert.assertEquals(projectId, actualRequest.getProjectId()); - Assert.assertEquals(trigger, actualRequest.getTrigger()); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - public void createBuildTriggerExceptionTest() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); - mockCloudBuild.addException(exception); - - try { - String projectId = "projectId-894832108"; - BuildTrigger trigger = BuildTrigger.newBuilder().build(); - client.createBuildTrigger(projectId, trigger); - Assert.fail("No exception raised"); - } catch (InvalidArgumentException e) { - // Expected exception. - } - } - - @Test - public void getBuildTriggerTest() throws Exception { - BuildTrigger expectedResponse = - BuildTrigger.newBuilder() - .setResourceName("resourceName-384566343") - .setId("id3355") - .setDescription("description-1724546052") - .setName(BuildTriggerName.ofProjectTriggerName("[PROJECT]", "[TRIGGER]").toString()) - .addAllTags(new ArrayList()) - .setTriggerTemplate(RepoSource.newBuilder().build()) - .setGithub(GitHubEventsConfig.newBuilder().build()) - .setPubsubConfig(PubsubConfig.newBuilder().build()) - .setWebhookConfig(WebhookConfig.newBuilder().build()) - .setCreateTime(Timestamp.newBuilder().build()) - .setDisabled(true) - .putAllSubstitutions(new HashMap()) - .addAllIgnoredFiles(new ArrayList()) - .addAllIncludedFiles(new ArrayList()) - .setFilter("filter-1274492040") - .setServiceAccount("serviceAccount1079137720") - .build(); - mockCloudBuild.addResponse(expectedResponse); - - String projectId = "projectId-894832108"; - String triggerId = "triggerId-648752909"; - - BuildTrigger actualResponse = client.getBuildTrigger(projectId, triggerId); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockCloudBuild.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - GetBuildTriggerRequest actualRequest = ((GetBuildTriggerRequest) actualRequests.get(0)); - - Assert.assertEquals(projectId, actualRequest.getProjectId()); - Assert.assertEquals(triggerId, actualRequest.getTriggerId()); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - public void getBuildTriggerExceptionTest() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); - mockCloudBuild.addException(exception); - - try { - String projectId = "projectId-894832108"; - String triggerId = "triggerId-648752909"; - client.getBuildTrigger(projectId, triggerId); - Assert.fail("No exception raised"); - } catch (InvalidArgumentException e) { - // Expected exception. - } - } - - @Test - public void listBuildTriggersTest() throws Exception { - BuildTrigger responsesElement = BuildTrigger.newBuilder().build(); - ListBuildTriggersResponse expectedResponse = - ListBuildTriggersResponse.newBuilder() - .setNextPageToken("") - .addAllTriggers(Arrays.asList(responsesElement)) - .build(); - mockCloudBuild.addResponse(expectedResponse); - - String projectId = "projectId-894832108"; - - ListBuildTriggersPagedResponse pagedListResponse = client.listBuildTriggers(projectId); - - List resources = Lists.newArrayList(pagedListResponse.iterateAll()); - - Assert.assertEquals(1, resources.size()); - Assert.assertEquals(expectedResponse.getTriggersList().get(0), resources.get(0)); - - List actualRequests = mockCloudBuild.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - ListBuildTriggersRequest actualRequest = ((ListBuildTriggersRequest) actualRequests.get(0)); - - Assert.assertEquals(projectId, actualRequest.getProjectId()); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - public void listBuildTriggersExceptionTest() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); - mockCloudBuild.addException(exception); - - try { - String projectId = "projectId-894832108"; - client.listBuildTriggers(projectId); - Assert.fail("No exception raised"); - } catch (InvalidArgumentException e) { - // Expected exception. - } - } - - @Test - public void deleteBuildTriggerTest() throws Exception { - Empty expectedResponse = Empty.newBuilder().build(); - mockCloudBuild.addResponse(expectedResponse); - - String projectId = "projectId-894832108"; - String triggerId = "triggerId-648752909"; - - client.deleteBuildTrigger(projectId, triggerId); - - List actualRequests = mockCloudBuild.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - DeleteBuildTriggerRequest actualRequest = ((DeleteBuildTriggerRequest) actualRequests.get(0)); - - Assert.assertEquals(projectId, actualRequest.getProjectId()); - Assert.assertEquals(triggerId, actualRequest.getTriggerId()); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - public void deleteBuildTriggerExceptionTest() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); - mockCloudBuild.addException(exception); - - try { - String projectId = "projectId-894832108"; - String triggerId = "triggerId-648752909"; - client.deleteBuildTrigger(projectId, triggerId); - Assert.fail("No exception raised"); - } catch (InvalidArgumentException e) { - // Expected exception. - } - } - - @Test - public void updateBuildTriggerTest() throws Exception { - BuildTrigger expectedResponse = - BuildTrigger.newBuilder() - .setResourceName("resourceName-384566343") - .setId("id3355") - .setDescription("description-1724546052") - .setName(BuildTriggerName.ofProjectTriggerName("[PROJECT]", "[TRIGGER]").toString()) - .addAllTags(new ArrayList()) - .setTriggerTemplate(RepoSource.newBuilder().build()) - .setGithub(GitHubEventsConfig.newBuilder().build()) - .setPubsubConfig(PubsubConfig.newBuilder().build()) - .setWebhookConfig(WebhookConfig.newBuilder().build()) - .setCreateTime(Timestamp.newBuilder().build()) - .setDisabled(true) - .putAllSubstitutions(new HashMap()) - .addAllIgnoredFiles(new ArrayList()) - .addAllIncludedFiles(new ArrayList()) - .setFilter("filter-1274492040") - .setServiceAccount("serviceAccount1079137720") - .build(); - mockCloudBuild.addResponse(expectedResponse); - - String projectId = "projectId-894832108"; - String triggerId = "triggerId-648752909"; - BuildTrigger trigger = BuildTrigger.newBuilder().build(); - - BuildTrigger actualResponse = client.updateBuildTrigger(projectId, triggerId, trigger); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockCloudBuild.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - UpdateBuildTriggerRequest actualRequest = ((UpdateBuildTriggerRequest) actualRequests.get(0)); - - Assert.assertEquals(projectId, actualRequest.getProjectId()); - Assert.assertEquals(triggerId, actualRequest.getTriggerId()); - Assert.assertEquals(trigger, actualRequest.getTrigger()); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - public void updateBuildTriggerExceptionTest() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); - mockCloudBuild.addException(exception); - - try { - String projectId = "projectId-894832108"; - String triggerId = "triggerId-648752909"; - BuildTrigger trigger = BuildTrigger.newBuilder().build(); - client.updateBuildTrigger(projectId, triggerId, trigger); - Assert.fail("No exception raised"); - } catch (InvalidArgumentException e) { - // Expected exception. - } - } - - @Test - public void runBuildTriggerTest() throws Exception { - Build expectedResponse = - Build.newBuilder() - .setName(BuildName.ofProjectBuildName("[PROJECT]", "[BUILD]").toString()) - .setId("id3355") - .setProjectId("projectId-894832108") - .setStatusDetail("statusDetail1651087075") - .setSource(Source.newBuilder().build()) - .addAllSteps(new ArrayList()) - .setResults(Results.newBuilder().build()) - .setCreateTime(Timestamp.newBuilder().build()) - .setStartTime(Timestamp.newBuilder().build()) - .setFinishTime(Timestamp.newBuilder().build()) - .setTimeout(Duration.newBuilder().build()) - .addAllImages(new ArrayList()) - .setQueueTtl(Duration.newBuilder().build()) - .setArtifacts(Artifacts.newBuilder().build()) - .setLogsBucket("logsBucket1592573049") - .setSourceProvenance(SourceProvenance.newBuilder().build()) - .setBuildTriggerId("buildTriggerId781747749") - .setOptions(BuildOptions.newBuilder().build()) - .setLogUrl("logUrl-1097354357") - .putAllSubstitutions(new HashMap()) - .addAllTags(new ArrayList()) - .addAllSecrets(new ArrayList()) - .putAllTiming(new HashMap()) - .setApproval(BuildApproval.newBuilder().build()) - .setServiceAccount("serviceAccount1079137720") - .setAvailableSecrets(Secrets.newBuilder().build()) - .addAllWarnings(new ArrayList()) - .setFailureInfo(Build.FailureInfo.newBuilder().build()) - .build(); - Operation resultOperation = - Operation.newBuilder() - .setName("runBuildTriggerTest") - .setDone(true) - .setResponse(Any.pack(expectedResponse)) - .build(); - mockCloudBuild.addResponse(resultOperation); - - String projectId = "projectId-894832108"; - String triggerId = "triggerId-648752909"; - RepoSource source = RepoSource.newBuilder().build(); - - Build actualResponse = client.runBuildTriggerAsync(projectId, triggerId, source).get(); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockCloudBuild.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - RunBuildTriggerRequest actualRequest = ((RunBuildTriggerRequest) actualRequests.get(0)); - - Assert.assertEquals(projectId, actualRequest.getProjectId()); - Assert.assertEquals(triggerId, actualRequest.getTriggerId()); - Assert.assertEquals(source, actualRequest.getSource()); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - public void runBuildTriggerExceptionTest() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); - mockCloudBuild.addException(exception); - - try { - String projectId = "projectId-894832108"; - String triggerId = "triggerId-648752909"; - RepoSource source = RepoSource.newBuilder().build(); - client.runBuildTriggerAsync(projectId, triggerId, source).get(); - Assert.fail("No exception raised"); - } catch (ExecutionException e) { - Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); - InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); - Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); - } - } - - @Test - public void receiveTriggerWebhookTest() throws Exception { - ReceiveTriggerWebhookResponse expectedResponse = - ReceiveTriggerWebhookResponse.newBuilder().build(); - mockCloudBuild.addResponse(expectedResponse); - - ReceiveTriggerWebhookRequest request = - ReceiveTriggerWebhookRequest.newBuilder() - .setName("name3373707") - .setBody(HttpBody.newBuilder().build()) - .setProjectId("projectId-894832108") - .setTrigger("trigger-1059891784") - .setSecret("secret-906277200") - .build(); - - ReceiveTriggerWebhookResponse actualResponse = client.receiveTriggerWebhook(request); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockCloudBuild.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - ReceiveTriggerWebhookRequest actualRequest = - ((ReceiveTriggerWebhookRequest) actualRequests.get(0)); - - Assert.assertEquals(request.getName(), actualRequest.getName()); - Assert.assertEquals(request.getBody(), actualRequest.getBody()); - Assert.assertEquals(request.getProjectId(), actualRequest.getProjectId()); - Assert.assertEquals(request.getTrigger(), actualRequest.getTrigger()); - Assert.assertEquals(request.getSecret(), actualRequest.getSecret()); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - public void receiveTriggerWebhookExceptionTest() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); - mockCloudBuild.addException(exception); - - try { - ReceiveTriggerWebhookRequest request = - ReceiveTriggerWebhookRequest.newBuilder() - .setName("name3373707") - .setBody(HttpBody.newBuilder().build()) - .setProjectId("projectId-894832108") - .setTrigger("trigger-1059891784") - .setSecret("secret-906277200") - .build(); - client.receiveTriggerWebhook(request); - Assert.fail("No exception raised"); - } catch (InvalidArgumentException e) { - // Expected exception. - } - } - - @Test - public void createWorkerPoolTest() throws Exception { - WorkerPool expectedResponse = - WorkerPool.newBuilder() - .setName(WorkerPoolName.of("[PROJECT]", "[LOCATION]", "[WORKER_POOL]").toString()) - .setDisplayName("displayName1714148973") - .setUid("uid115792") - .putAllAnnotations(new HashMap()) - .setCreateTime(Timestamp.newBuilder().build()) - .setUpdateTime(Timestamp.newBuilder().build()) - .setDeleteTime(Timestamp.newBuilder().build()) - .setEtag("etag3123477") - .build(); - Operation resultOperation = - Operation.newBuilder() - .setName("createWorkerPoolTest") - .setDone(true) - .setResponse(Any.pack(expectedResponse)) - .build(); - mockCloudBuild.addResponse(resultOperation); - - LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); - WorkerPool workerPool = WorkerPool.newBuilder().build(); - String workerPoolId = "workerPoolId-46320779"; - - WorkerPool actualResponse = - client.createWorkerPoolAsync(parent, workerPool, workerPoolId).get(); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockCloudBuild.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - CreateWorkerPoolRequest actualRequest = ((CreateWorkerPoolRequest) actualRequests.get(0)); - - Assert.assertEquals(parent.toString(), actualRequest.getParent()); - Assert.assertEquals(workerPool, actualRequest.getWorkerPool()); - Assert.assertEquals(workerPoolId, actualRequest.getWorkerPoolId()); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - public void createWorkerPoolExceptionTest() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); - mockCloudBuild.addException(exception); - - try { - LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); - WorkerPool workerPool = WorkerPool.newBuilder().build(); - String workerPoolId = "workerPoolId-46320779"; - client.createWorkerPoolAsync(parent, workerPool, workerPoolId).get(); - Assert.fail("No exception raised"); - } catch (ExecutionException e) { - Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); - InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); - Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); - } - } - - @Test - public void createWorkerPoolTest2() throws Exception { - WorkerPool expectedResponse = - WorkerPool.newBuilder() - .setName(WorkerPoolName.of("[PROJECT]", "[LOCATION]", "[WORKER_POOL]").toString()) - .setDisplayName("displayName1714148973") - .setUid("uid115792") - .putAllAnnotations(new HashMap()) - .setCreateTime(Timestamp.newBuilder().build()) - .setUpdateTime(Timestamp.newBuilder().build()) - .setDeleteTime(Timestamp.newBuilder().build()) - .setEtag("etag3123477") - .build(); - Operation resultOperation = - Operation.newBuilder() - .setName("createWorkerPoolTest") - .setDone(true) - .setResponse(Any.pack(expectedResponse)) - .build(); - mockCloudBuild.addResponse(resultOperation); - - String parent = "parent-995424086"; - WorkerPool workerPool = WorkerPool.newBuilder().build(); - String workerPoolId = "workerPoolId-46320779"; - - WorkerPool actualResponse = - client.createWorkerPoolAsync(parent, workerPool, workerPoolId).get(); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockCloudBuild.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - CreateWorkerPoolRequest actualRequest = ((CreateWorkerPoolRequest) actualRequests.get(0)); - - Assert.assertEquals(parent, actualRequest.getParent()); - Assert.assertEquals(workerPool, actualRequest.getWorkerPool()); - Assert.assertEquals(workerPoolId, actualRequest.getWorkerPoolId()); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - public void createWorkerPoolExceptionTest2() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); - mockCloudBuild.addException(exception); - - try { - String parent = "parent-995424086"; - WorkerPool workerPool = WorkerPool.newBuilder().build(); - String workerPoolId = "workerPoolId-46320779"; - client.createWorkerPoolAsync(parent, workerPool, workerPoolId).get(); - Assert.fail("No exception raised"); - } catch (ExecutionException e) { - Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); - InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); - Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); - } - } - - @Test - public void getWorkerPoolTest() throws Exception { - WorkerPool expectedResponse = - WorkerPool.newBuilder() - .setName(WorkerPoolName.of("[PROJECT]", "[LOCATION]", "[WORKER_POOL]").toString()) - .setDisplayName("displayName1714148973") - .setUid("uid115792") - .putAllAnnotations(new HashMap()) - .setCreateTime(Timestamp.newBuilder().build()) - .setUpdateTime(Timestamp.newBuilder().build()) - .setDeleteTime(Timestamp.newBuilder().build()) - .setEtag("etag3123477") - .build(); - mockCloudBuild.addResponse(expectedResponse); - - WorkerPoolName name = WorkerPoolName.of("[PROJECT]", "[LOCATION]", "[WORKER_POOL]"); - - WorkerPool actualResponse = client.getWorkerPool(name); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockCloudBuild.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - GetWorkerPoolRequest actualRequest = ((GetWorkerPoolRequest) actualRequests.get(0)); - - Assert.assertEquals(name.toString(), actualRequest.getName()); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - public void getWorkerPoolExceptionTest() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); - mockCloudBuild.addException(exception); - - try { - WorkerPoolName name = WorkerPoolName.of("[PROJECT]", "[LOCATION]", "[WORKER_POOL]"); - client.getWorkerPool(name); - Assert.fail("No exception raised"); - } catch (InvalidArgumentException e) { - // Expected exception. - } - } - - @Test - public void getWorkerPoolTest2() throws Exception { - WorkerPool expectedResponse = - WorkerPool.newBuilder() - .setName(WorkerPoolName.of("[PROJECT]", "[LOCATION]", "[WORKER_POOL]").toString()) - .setDisplayName("displayName1714148973") - .setUid("uid115792") - .putAllAnnotations(new HashMap()) - .setCreateTime(Timestamp.newBuilder().build()) - .setUpdateTime(Timestamp.newBuilder().build()) - .setDeleteTime(Timestamp.newBuilder().build()) - .setEtag("etag3123477") - .build(); - mockCloudBuild.addResponse(expectedResponse); - - String name = "name3373707"; - - WorkerPool actualResponse = client.getWorkerPool(name); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockCloudBuild.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - GetWorkerPoolRequest actualRequest = ((GetWorkerPoolRequest) actualRequests.get(0)); - - Assert.assertEquals(name, actualRequest.getName()); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - public void getWorkerPoolExceptionTest2() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); - mockCloudBuild.addException(exception); - - try { - String name = "name3373707"; - client.getWorkerPool(name); - Assert.fail("No exception raised"); - } catch (InvalidArgumentException e) { - // Expected exception. - } - } - - @Test - public void deleteWorkerPoolTest() throws Exception { - Empty expectedResponse = Empty.newBuilder().build(); - Operation resultOperation = - Operation.newBuilder() - .setName("deleteWorkerPoolTest") - .setDone(true) - .setResponse(Any.pack(expectedResponse)) - .build(); - mockCloudBuild.addResponse(resultOperation); - - WorkerPoolName name = WorkerPoolName.of("[PROJECT]", "[LOCATION]", "[WORKER_POOL]"); - - client.deleteWorkerPoolAsync(name).get(); - - List actualRequests = mockCloudBuild.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - DeleteWorkerPoolRequest actualRequest = ((DeleteWorkerPoolRequest) actualRequests.get(0)); - - Assert.assertEquals(name.toString(), actualRequest.getName()); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - public void deleteWorkerPoolExceptionTest() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); - mockCloudBuild.addException(exception); - - try { - WorkerPoolName name = WorkerPoolName.of("[PROJECT]", "[LOCATION]", "[WORKER_POOL]"); - client.deleteWorkerPoolAsync(name).get(); - Assert.fail("No exception raised"); - } catch (ExecutionException e) { - Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); - InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); - Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); - } - } - - @Test - public void deleteWorkerPoolTest2() throws Exception { - Empty expectedResponse = Empty.newBuilder().build(); - Operation resultOperation = - Operation.newBuilder() - .setName("deleteWorkerPoolTest") - .setDone(true) - .setResponse(Any.pack(expectedResponse)) - .build(); - mockCloudBuild.addResponse(resultOperation); - - String name = "name3373707"; - - client.deleteWorkerPoolAsync(name).get(); - - List actualRequests = mockCloudBuild.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - DeleteWorkerPoolRequest actualRequest = ((DeleteWorkerPoolRequest) actualRequests.get(0)); - - Assert.assertEquals(name, actualRequest.getName()); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - public void deleteWorkerPoolExceptionTest2() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); - mockCloudBuild.addException(exception); - - try { - String name = "name3373707"; - client.deleteWorkerPoolAsync(name).get(); - Assert.fail("No exception raised"); - } catch (ExecutionException e) { - Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); - InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); - Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); - } - } - - @Test - public void updateWorkerPoolTest() throws Exception { - WorkerPool expectedResponse = - WorkerPool.newBuilder() - .setName(WorkerPoolName.of("[PROJECT]", "[LOCATION]", "[WORKER_POOL]").toString()) - .setDisplayName("displayName1714148973") - .setUid("uid115792") - .putAllAnnotations(new HashMap()) - .setCreateTime(Timestamp.newBuilder().build()) - .setUpdateTime(Timestamp.newBuilder().build()) - .setDeleteTime(Timestamp.newBuilder().build()) - .setEtag("etag3123477") - .build(); - Operation resultOperation = - Operation.newBuilder() - .setName("updateWorkerPoolTest") - .setDone(true) - .setResponse(Any.pack(expectedResponse)) - .build(); - mockCloudBuild.addResponse(resultOperation); - - WorkerPool workerPool = WorkerPool.newBuilder().build(); - FieldMask updateMask = FieldMask.newBuilder().build(); - - WorkerPool actualResponse = client.updateWorkerPoolAsync(workerPool, updateMask).get(); - Assert.assertEquals(expectedResponse, actualResponse); - - List actualRequests = mockCloudBuild.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - UpdateWorkerPoolRequest actualRequest = ((UpdateWorkerPoolRequest) actualRequests.get(0)); - - Assert.assertEquals(workerPool, actualRequest.getWorkerPool()); - Assert.assertEquals(updateMask, actualRequest.getUpdateMask()); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - public void updateWorkerPoolExceptionTest() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); - mockCloudBuild.addException(exception); - - try { - WorkerPool workerPool = WorkerPool.newBuilder().build(); - FieldMask updateMask = FieldMask.newBuilder().build(); - client.updateWorkerPoolAsync(workerPool, updateMask).get(); - Assert.fail("No exception raised"); - } catch (ExecutionException e) { - Assert.assertEquals(InvalidArgumentException.class, e.getCause().getClass()); - InvalidArgumentException apiException = ((InvalidArgumentException) e.getCause()); - Assert.assertEquals(StatusCode.Code.INVALID_ARGUMENT, apiException.getStatusCode().getCode()); - } - } - - @Test - public void listWorkerPoolsTest() throws Exception { - WorkerPool responsesElement = WorkerPool.newBuilder().build(); - ListWorkerPoolsResponse expectedResponse = - ListWorkerPoolsResponse.newBuilder() - .setNextPageToken("") - .addAllWorkerPools(Arrays.asList(responsesElement)) - .build(); - mockCloudBuild.addResponse(expectedResponse); - - LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); - - ListWorkerPoolsPagedResponse pagedListResponse = client.listWorkerPools(parent); - - List resources = Lists.newArrayList(pagedListResponse.iterateAll()); - - Assert.assertEquals(1, resources.size()); - Assert.assertEquals(expectedResponse.getWorkerPoolsList().get(0), resources.get(0)); - - List actualRequests = mockCloudBuild.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - ListWorkerPoolsRequest actualRequest = ((ListWorkerPoolsRequest) actualRequests.get(0)); - - Assert.assertEquals(parent.toString(), actualRequest.getParent()); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - public void listWorkerPoolsExceptionTest() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); - mockCloudBuild.addException(exception); - - try { - LocationName parent = LocationName.of("[PROJECT]", "[LOCATION]"); - client.listWorkerPools(parent); - Assert.fail("No exception raised"); - } catch (InvalidArgumentException e) { - // Expected exception. - } - } - - @Test - public void listWorkerPoolsTest2() throws Exception { - WorkerPool responsesElement = WorkerPool.newBuilder().build(); - ListWorkerPoolsResponse expectedResponse = - ListWorkerPoolsResponse.newBuilder() - .setNextPageToken("") - .addAllWorkerPools(Arrays.asList(responsesElement)) - .build(); - mockCloudBuild.addResponse(expectedResponse); - - String parent = "parent-995424086"; - - ListWorkerPoolsPagedResponse pagedListResponse = client.listWorkerPools(parent); - - List resources = Lists.newArrayList(pagedListResponse.iterateAll()); - - Assert.assertEquals(1, resources.size()); - Assert.assertEquals(expectedResponse.getWorkerPoolsList().get(0), resources.get(0)); - - List actualRequests = mockCloudBuild.getRequests(); - Assert.assertEquals(1, actualRequests.size()); - ListWorkerPoolsRequest actualRequest = ((ListWorkerPoolsRequest) actualRequests.get(0)); - - Assert.assertEquals(parent, actualRequest.getParent()); - Assert.assertTrue( - channelProvider.isHeaderSent( - ApiClientHeaderProvider.getDefaultApiClientHeaderKey(), - GaxGrpcProperties.getDefaultApiClientHeaderPattern())); - } - - @Test - public void listWorkerPoolsExceptionTest2() throws Exception { - StatusRuntimeException exception = new StatusRuntimeException(io.grpc.Status.INVALID_ARGUMENT); - mockCloudBuild.addException(exception); - - try { - String parent = "parent-995424086"; - client.listWorkerPools(parent); - Assert.fail("No exception raised"); - } catch (InvalidArgumentException e) { - // Expected exception. - } - } -} diff --git a/google-cloud-build/src/test/java/com/google/cloud/devtools/cloudbuild/v1/MockCloudBuild.java b/google-cloud-build/src/test/java/com/google/cloud/devtools/cloudbuild/v1/MockCloudBuild.java deleted file mode 100644 index 54860a0f..00000000 --- a/google-cloud-build/src/test/java/com/google/cloud/devtools/cloudbuild/v1/MockCloudBuild.java +++ /dev/null @@ -1,59 +0,0 @@ -/* - * Copyright 2022 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package com.google.cloud.devtools.cloudbuild.v1; - -import com.google.api.core.BetaApi; -import com.google.api.gax.grpc.testing.MockGrpcService; -import com.google.protobuf.AbstractMessage; -import io.grpc.ServerServiceDefinition; -import java.util.List; -import javax.annotation.Generated; - -@BetaApi -@Generated("by gapic-generator-java") -public class MockCloudBuild implements MockGrpcService { - private final MockCloudBuildImpl serviceImpl; - - public MockCloudBuild() { - serviceImpl = new MockCloudBuildImpl(); - } - - @Override - public List getRequests() { - return serviceImpl.getRequests(); - } - - @Override - public void addResponse(AbstractMessage response) { - serviceImpl.addResponse(response); - } - - @Override - public void addException(Exception exception) { - serviceImpl.addException(exception); - } - - @Override - public ServerServiceDefinition getServiceDefinition() { - return serviceImpl.bindService(); - } - - @Override - public void reset() { - serviceImpl.reset(); - } -} diff --git a/google-cloud-build/src/test/java/com/google/cloud/devtools/cloudbuild/v1/MockCloudBuildImpl.java b/google-cloud-build/src/test/java/com/google/cloud/devtools/cloudbuild/v1/MockCloudBuildImpl.java deleted file mode 100644 index 439a2b89..00000000 --- a/google-cloud-build/src/test/java/com/google/cloud/devtools/cloudbuild/v1/MockCloudBuildImpl.java +++ /dev/null @@ -1,463 +0,0 @@ -/* - * Copyright 2022 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package com.google.cloud.devtools.cloudbuild.v1; - -import com.google.api.core.BetaApi; -import com.google.cloudbuild.v1.ApproveBuildRequest; -import com.google.cloudbuild.v1.Build; -import com.google.cloudbuild.v1.BuildTrigger; -import com.google.cloudbuild.v1.CancelBuildRequest; -import com.google.cloudbuild.v1.CloudBuildGrpc.CloudBuildImplBase; -import com.google.cloudbuild.v1.CreateBuildRequest; -import com.google.cloudbuild.v1.CreateBuildTriggerRequest; -import com.google.cloudbuild.v1.CreateWorkerPoolRequest; -import com.google.cloudbuild.v1.DeleteBuildTriggerRequest; -import com.google.cloudbuild.v1.DeleteWorkerPoolRequest; -import com.google.cloudbuild.v1.GetBuildRequest; -import com.google.cloudbuild.v1.GetBuildTriggerRequest; -import com.google.cloudbuild.v1.GetWorkerPoolRequest; -import com.google.cloudbuild.v1.ListBuildTriggersRequest; -import com.google.cloudbuild.v1.ListBuildTriggersResponse; -import com.google.cloudbuild.v1.ListBuildsRequest; -import com.google.cloudbuild.v1.ListBuildsResponse; -import com.google.cloudbuild.v1.ListWorkerPoolsRequest; -import com.google.cloudbuild.v1.ListWorkerPoolsResponse; -import com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest; -import com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse; -import com.google.cloudbuild.v1.RetryBuildRequest; -import com.google.cloudbuild.v1.RunBuildTriggerRequest; -import com.google.cloudbuild.v1.UpdateBuildTriggerRequest; -import com.google.cloudbuild.v1.UpdateWorkerPoolRequest; -import com.google.cloudbuild.v1.WorkerPool; -import com.google.longrunning.Operation; -import com.google.protobuf.AbstractMessage; -import com.google.protobuf.Empty; -import io.grpc.stub.StreamObserver; -import java.util.ArrayList; -import java.util.LinkedList; -import java.util.List; -import java.util.Queue; -import javax.annotation.Generated; - -@BetaApi -@Generated("by gapic-generator-java") -public class MockCloudBuildImpl extends CloudBuildImplBase { - private List requests; - private Queue responses; - - public MockCloudBuildImpl() { - requests = new ArrayList<>(); - responses = new LinkedList<>(); - } - - public List getRequests() { - return requests; - } - - public void addResponse(AbstractMessage response) { - responses.add(response); - } - - public void setResponses(List responses) { - this.responses = new LinkedList(responses); - } - - public void addException(Exception exception) { - responses.add(exception); - } - - public void reset() { - requests = new ArrayList<>(); - responses = new LinkedList<>(); - } - - @Override - public void createBuild(CreateBuildRequest request, StreamObserver responseObserver) { - Object response = responses.poll(); - if (response instanceof Operation) { - requests.add(request); - responseObserver.onNext(((Operation) response)); - responseObserver.onCompleted(); - } else if (response instanceof Exception) { - responseObserver.onError(((Exception) response)); - } else { - responseObserver.onError( - new IllegalArgumentException( - String.format( - "Unrecognized response type %s for method CreateBuild, expected %s or %s", - response == null ? "null" : response.getClass().getName(), - Operation.class.getName(), - Exception.class.getName()))); - } - } - - @Override - public void getBuild(GetBuildRequest request, StreamObserver responseObserver) { - Object response = responses.poll(); - if (response instanceof Build) { - requests.add(request); - responseObserver.onNext(((Build) response)); - responseObserver.onCompleted(); - } else if (response instanceof Exception) { - responseObserver.onError(((Exception) response)); - } else { - responseObserver.onError( - new IllegalArgumentException( - String.format( - "Unrecognized response type %s for method GetBuild, expected %s or %s", - response == null ? "null" : response.getClass().getName(), - Build.class.getName(), - Exception.class.getName()))); - } - } - - @Override - public void listBuilds( - ListBuildsRequest request, StreamObserver responseObserver) { - Object response = responses.poll(); - if (response instanceof ListBuildsResponse) { - requests.add(request); - responseObserver.onNext(((ListBuildsResponse) response)); - responseObserver.onCompleted(); - } else if (response instanceof Exception) { - responseObserver.onError(((Exception) response)); - } else { - responseObserver.onError( - new IllegalArgumentException( - String.format( - "Unrecognized response type %s for method ListBuilds, expected %s or %s", - response == null ? "null" : response.getClass().getName(), - ListBuildsResponse.class.getName(), - Exception.class.getName()))); - } - } - - @Override - public void cancelBuild(CancelBuildRequest request, StreamObserver responseObserver) { - Object response = responses.poll(); - if (response instanceof Build) { - requests.add(request); - responseObserver.onNext(((Build) response)); - responseObserver.onCompleted(); - } else if (response instanceof Exception) { - responseObserver.onError(((Exception) response)); - } else { - responseObserver.onError( - new IllegalArgumentException( - String.format( - "Unrecognized response type %s for method CancelBuild, expected %s or %s", - response == null ? "null" : response.getClass().getName(), - Build.class.getName(), - Exception.class.getName()))); - } - } - - @Override - public void retryBuild(RetryBuildRequest request, StreamObserver responseObserver) { - Object response = responses.poll(); - if (response instanceof Operation) { - requests.add(request); - responseObserver.onNext(((Operation) response)); - responseObserver.onCompleted(); - } else if (response instanceof Exception) { - responseObserver.onError(((Exception) response)); - } else { - responseObserver.onError( - new IllegalArgumentException( - String.format( - "Unrecognized response type %s for method RetryBuild, expected %s or %s", - response == null ? "null" : response.getClass().getName(), - Operation.class.getName(), - Exception.class.getName()))); - } - } - - @Override - public void approveBuild( - ApproveBuildRequest request, StreamObserver responseObserver) { - Object response = responses.poll(); - if (response instanceof Operation) { - requests.add(request); - responseObserver.onNext(((Operation) response)); - responseObserver.onCompleted(); - } else if (response instanceof Exception) { - responseObserver.onError(((Exception) response)); - } else { - responseObserver.onError( - new IllegalArgumentException( - String.format( - "Unrecognized response type %s for method ApproveBuild, expected %s or %s", - response == null ? "null" : response.getClass().getName(), - Operation.class.getName(), - Exception.class.getName()))); - } - } - - @Override - public void createBuildTrigger( - CreateBuildTriggerRequest request, StreamObserver responseObserver) { - Object response = responses.poll(); - if (response instanceof BuildTrigger) { - requests.add(request); - responseObserver.onNext(((BuildTrigger) response)); - responseObserver.onCompleted(); - } else if (response instanceof Exception) { - responseObserver.onError(((Exception) response)); - } else { - responseObserver.onError( - new IllegalArgumentException( - String.format( - "Unrecognized response type %s for method CreateBuildTrigger, expected %s or %s", - response == null ? "null" : response.getClass().getName(), - BuildTrigger.class.getName(), - Exception.class.getName()))); - } - } - - @Override - public void getBuildTrigger( - GetBuildTriggerRequest request, StreamObserver responseObserver) { - Object response = responses.poll(); - if (response instanceof BuildTrigger) { - requests.add(request); - responseObserver.onNext(((BuildTrigger) response)); - responseObserver.onCompleted(); - } else if (response instanceof Exception) { - responseObserver.onError(((Exception) response)); - } else { - responseObserver.onError( - new IllegalArgumentException( - String.format( - "Unrecognized response type %s for method GetBuildTrigger, expected %s or %s", - response == null ? "null" : response.getClass().getName(), - BuildTrigger.class.getName(), - Exception.class.getName()))); - } - } - - @Override - public void listBuildTriggers( - ListBuildTriggersRequest request, - StreamObserver responseObserver) { - Object response = responses.poll(); - if (response instanceof ListBuildTriggersResponse) { - requests.add(request); - responseObserver.onNext(((ListBuildTriggersResponse) response)); - responseObserver.onCompleted(); - } else if (response instanceof Exception) { - responseObserver.onError(((Exception) response)); - } else { - responseObserver.onError( - new IllegalArgumentException( - String.format( - "Unrecognized response type %s for method ListBuildTriggers, expected %s or %s", - response == null ? "null" : response.getClass().getName(), - ListBuildTriggersResponse.class.getName(), - Exception.class.getName()))); - } - } - - @Override - public void deleteBuildTrigger( - DeleteBuildTriggerRequest request, StreamObserver responseObserver) { - Object response = responses.poll(); - if (response instanceof Empty) { - requests.add(request); - responseObserver.onNext(((Empty) response)); - responseObserver.onCompleted(); - } else if (response instanceof Exception) { - responseObserver.onError(((Exception) response)); - } else { - responseObserver.onError( - new IllegalArgumentException( - String.format( - "Unrecognized response type %s for method DeleteBuildTrigger, expected %s or %s", - response == null ? "null" : response.getClass().getName(), - Empty.class.getName(), - Exception.class.getName()))); - } - } - - @Override - public void updateBuildTrigger( - UpdateBuildTriggerRequest request, StreamObserver responseObserver) { - Object response = responses.poll(); - if (response instanceof BuildTrigger) { - requests.add(request); - responseObserver.onNext(((BuildTrigger) response)); - responseObserver.onCompleted(); - } else if (response instanceof Exception) { - responseObserver.onError(((Exception) response)); - } else { - responseObserver.onError( - new IllegalArgumentException( - String.format( - "Unrecognized response type %s for method UpdateBuildTrigger, expected %s or %s", - response == null ? "null" : response.getClass().getName(), - BuildTrigger.class.getName(), - Exception.class.getName()))); - } - } - - @Override - public void runBuildTrigger( - RunBuildTriggerRequest request, StreamObserver responseObserver) { - Object response = responses.poll(); - if (response instanceof Operation) { - requests.add(request); - responseObserver.onNext(((Operation) response)); - responseObserver.onCompleted(); - } else if (response instanceof Exception) { - responseObserver.onError(((Exception) response)); - } else { - responseObserver.onError( - new IllegalArgumentException( - String.format( - "Unrecognized response type %s for method RunBuildTrigger, expected %s or %s", - response == null ? "null" : response.getClass().getName(), - Operation.class.getName(), - Exception.class.getName()))); - } - } - - @Override - public void receiveTriggerWebhook( - ReceiveTriggerWebhookRequest request, - StreamObserver responseObserver) { - Object response = responses.poll(); - if (response instanceof ReceiveTriggerWebhookResponse) { - requests.add(request); - responseObserver.onNext(((ReceiveTriggerWebhookResponse) response)); - responseObserver.onCompleted(); - } else if (response instanceof Exception) { - responseObserver.onError(((Exception) response)); - } else { - responseObserver.onError( - new IllegalArgumentException( - String.format( - "Unrecognized response type %s for method ReceiveTriggerWebhook, expected %s or %s", - response == null ? "null" : response.getClass().getName(), - ReceiveTriggerWebhookResponse.class.getName(), - Exception.class.getName()))); - } - } - - @Override - public void createWorkerPool( - CreateWorkerPoolRequest request, StreamObserver responseObserver) { - Object response = responses.poll(); - if (response instanceof Operation) { - requests.add(request); - responseObserver.onNext(((Operation) response)); - responseObserver.onCompleted(); - } else if (response instanceof Exception) { - responseObserver.onError(((Exception) response)); - } else { - responseObserver.onError( - new IllegalArgumentException( - String.format( - "Unrecognized response type %s for method CreateWorkerPool, expected %s or %s", - response == null ? "null" : response.getClass().getName(), - Operation.class.getName(), - Exception.class.getName()))); - } - } - - @Override - public void getWorkerPool( - GetWorkerPoolRequest request, StreamObserver responseObserver) { - Object response = responses.poll(); - if (response instanceof WorkerPool) { - requests.add(request); - responseObserver.onNext(((WorkerPool) response)); - responseObserver.onCompleted(); - } else if (response instanceof Exception) { - responseObserver.onError(((Exception) response)); - } else { - responseObserver.onError( - new IllegalArgumentException( - String.format( - "Unrecognized response type %s for method GetWorkerPool, expected %s or %s", - response == null ? "null" : response.getClass().getName(), - WorkerPool.class.getName(), - Exception.class.getName()))); - } - } - - @Override - public void deleteWorkerPool( - DeleteWorkerPoolRequest request, StreamObserver responseObserver) { - Object response = responses.poll(); - if (response instanceof Operation) { - requests.add(request); - responseObserver.onNext(((Operation) response)); - responseObserver.onCompleted(); - } else if (response instanceof Exception) { - responseObserver.onError(((Exception) response)); - } else { - responseObserver.onError( - new IllegalArgumentException( - String.format( - "Unrecognized response type %s for method DeleteWorkerPool, expected %s or %s", - response == null ? "null" : response.getClass().getName(), - Operation.class.getName(), - Exception.class.getName()))); - } - } - - @Override - public void updateWorkerPool( - UpdateWorkerPoolRequest request, StreamObserver responseObserver) { - Object response = responses.poll(); - if (response instanceof Operation) { - requests.add(request); - responseObserver.onNext(((Operation) response)); - responseObserver.onCompleted(); - } else if (response instanceof Exception) { - responseObserver.onError(((Exception) response)); - } else { - responseObserver.onError( - new IllegalArgumentException( - String.format( - "Unrecognized response type %s for method UpdateWorkerPool, expected %s or %s", - response == null ? "null" : response.getClass().getName(), - Operation.class.getName(), - Exception.class.getName()))); - } - } - - @Override - public void listWorkerPools( - ListWorkerPoolsRequest request, StreamObserver responseObserver) { - Object response = responses.poll(); - if (response instanceof ListWorkerPoolsResponse) { - requests.add(request); - responseObserver.onNext(((ListWorkerPoolsResponse) response)); - responseObserver.onCompleted(); - } else if (response instanceof Exception) { - responseObserver.onError(((Exception) response)); - } else { - responseObserver.onError( - new IllegalArgumentException( - String.format( - "Unrecognized response type %s for method ListWorkerPools, expected %s or %s", - response == null ? "null" : response.getClass().getName(), - ListWorkerPoolsResponse.class.getName(), - Exception.class.getName()))); - } - } -} diff --git a/grpc-google-cloud-build-v1/pom.xml b/grpc-google-cloud-build-v1/pom.xml deleted file mode 100644 index f58e39ac..00000000 --- a/grpc-google-cloud-build-v1/pom.xml +++ /dev/null @@ -1,69 +0,0 @@ - - 4.0.0 - com.google.api.grpc - grpc-google-cloud-build-v1 - 3.5.7-SNAPSHOT - grpc-google-cloud-build-v1 - GRPC library for grpc-google-cloud-build-v1 - - com.google.cloud - google-cloud-build-parent - 3.5.7-SNAPSHOT - - - - io.grpc - grpc-api - - - io.grpc - grpc-stub - - - io.grpc - grpc-protobuf - - - com.google.protobuf - protobuf-java - - - com.google.api.grpc - proto-google-cloud-build-v1 - - - com.google.api.grpc - proto-google-common-protos - - - com.google.guava - guava - - - - - - java9 - - [9,) - - - - javax.annotation - javax.annotation-api - - - - - - - - - org.codehaus.mojo - flatten-maven-plugin - - - - diff --git a/grpc-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CloudBuildGrpc.java b/grpc-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CloudBuildGrpc.java deleted file mode 100644 index 86b6c599..00000000 --- a/grpc-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CloudBuildGrpc.java +++ /dev/null @@ -1,2428 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -package com.google.cloudbuild.v1; - -import static io.grpc.MethodDescriptor.generateFullMethodName; - -/** - * - * - *
- * Creates and manages builds on Google Cloud Platform.
- * The main concept used by this API is a `Build`, which describes the location
- * of the source to build, how to build the source, and where to store the
- * built artifacts, if any.
- * A user can list previously-requested builds or get builds by their ID to
- * determine the status of the build.
- * 
- */ -@javax.annotation.Generated( - value = "by gRPC proto compiler", - comments = "Source: google/devtools/cloudbuild/v1/cloudbuild.proto") -@io.grpc.stub.annotations.GrpcGenerated -public final class CloudBuildGrpc { - - private CloudBuildGrpc() {} - - public static final String SERVICE_NAME = "google.devtools.cloudbuild.v1.CloudBuild"; - - // Static method descriptors that strictly reflect the proto. - private static volatile io.grpc.MethodDescriptor< - com.google.cloudbuild.v1.CreateBuildRequest, com.google.longrunning.Operation> - getCreateBuildMethod; - - @io.grpc.stub.annotations.RpcMethod( - fullMethodName = SERVICE_NAME + '/' + "CreateBuild", - requestType = com.google.cloudbuild.v1.CreateBuildRequest.class, - responseType = com.google.longrunning.Operation.class, - methodType = io.grpc.MethodDescriptor.MethodType.UNARY) - public static io.grpc.MethodDescriptor< - com.google.cloudbuild.v1.CreateBuildRequest, com.google.longrunning.Operation> - getCreateBuildMethod() { - io.grpc.MethodDescriptor< - com.google.cloudbuild.v1.CreateBuildRequest, com.google.longrunning.Operation> - getCreateBuildMethod; - if ((getCreateBuildMethod = CloudBuildGrpc.getCreateBuildMethod) == null) { - synchronized (CloudBuildGrpc.class) { - if ((getCreateBuildMethod = CloudBuildGrpc.getCreateBuildMethod) == null) { - CloudBuildGrpc.getCreateBuildMethod = - getCreateBuildMethod = - io.grpc.MethodDescriptor - . - newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName(generateFullMethodName(SERVICE_NAME, "CreateBuild")) - .setSampledToLocalTracing(true) - .setRequestMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloudbuild.v1.CreateBuildRequest.getDefaultInstance())) - .setResponseMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.longrunning.Operation.getDefaultInstance())) - .setSchemaDescriptor(new CloudBuildMethodDescriptorSupplier("CreateBuild")) - .build(); - } - } - } - return getCreateBuildMethod; - } - - private static volatile io.grpc.MethodDescriptor< - com.google.cloudbuild.v1.GetBuildRequest, com.google.cloudbuild.v1.Build> - getGetBuildMethod; - - @io.grpc.stub.annotations.RpcMethod( - fullMethodName = SERVICE_NAME + '/' + "GetBuild", - requestType = com.google.cloudbuild.v1.GetBuildRequest.class, - responseType = com.google.cloudbuild.v1.Build.class, - methodType = io.grpc.MethodDescriptor.MethodType.UNARY) - public static io.grpc.MethodDescriptor< - com.google.cloudbuild.v1.GetBuildRequest, com.google.cloudbuild.v1.Build> - getGetBuildMethod() { - io.grpc.MethodDescriptor< - com.google.cloudbuild.v1.GetBuildRequest, com.google.cloudbuild.v1.Build> - getGetBuildMethod; - if ((getGetBuildMethod = CloudBuildGrpc.getGetBuildMethod) == null) { - synchronized (CloudBuildGrpc.class) { - if ((getGetBuildMethod = CloudBuildGrpc.getGetBuildMethod) == null) { - CloudBuildGrpc.getGetBuildMethod = - getGetBuildMethod = - io.grpc.MethodDescriptor - . - newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetBuild")) - .setSampledToLocalTracing(true) - .setRequestMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloudbuild.v1.GetBuildRequest.getDefaultInstance())) - .setResponseMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloudbuild.v1.Build.getDefaultInstance())) - .setSchemaDescriptor(new CloudBuildMethodDescriptorSupplier("GetBuild")) - .build(); - } - } - } - return getGetBuildMethod; - } - - private static volatile io.grpc.MethodDescriptor< - com.google.cloudbuild.v1.ListBuildsRequest, com.google.cloudbuild.v1.ListBuildsResponse> - getListBuildsMethod; - - @io.grpc.stub.annotations.RpcMethod( - fullMethodName = SERVICE_NAME + '/' + "ListBuilds", - requestType = com.google.cloudbuild.v1.ListBuildsRequest.class, - responseType = com.google.cloudbuild.v1.ListBuildsResponse.class, - methodType = io.grpc.MethodDescriptor.MethodType.UNARY) - public static io.grpc.MethodDescriptor< - com.google.cloudbuild.v1.ListBuildsRequest, com.google.cloudbuild.v1.ListBuildsResponse> - getListBuildsMethod() { - io.grpc.MethodDescriptor< - com.google.cloudbuild.v1.ListBuildsRequest, com.google.cloudbuild.v1.ListBuildsResponse> - getListBuildsMethod; - if ((getListBuildsMethod = CloudBuildGrpc.getListBuildsMethod) == null) { - synchronized (CloudBuildGrpc.class) { - if ((getListBuildsMethod = CloudBuildGrpc.getListBuildsMethod) == null) { - CloudBuildGrpc.getListBuildsMethod = - getListBuildsMethod = - io.grpc.MethodDescriptor - . - newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName(generateFullMethodName(SERVICE_NAME, "ListBuilds")) - .setSampledToLocalTracing(true) - .setRequestMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloudbuild.v1.ListBuildsRequest.getDefaultInstance())) - .setResponseMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloudbuild.v1.ListBuildsResponse.getDefaultInstance())) - .setSchemaDescriptor(new CloudBuildMethodDescriptorSupplier("ListBuilds")) - .build(); - } - } - } - return getListBuildsMethod; - } - - private static volatile io.grpc.MethodDescriptor< - com.google.cloudbuild.v1.CancelBuildRequest, com.google.cloudbuild.v1.Build> - getCancelBuildMethod; - - @io.grpc.stub.annotations.RpcMethod( - fullMethodName = SERVICE_NAME + '/' + "CancelBuild", - requestType = com.google.cloudbuild.v1.CancelBuildRequest.class, - responseType = com.google.cloudbuild.v1.Build.class, - methodType = io.grpc.MethodDescriptor.MethodType.UNARY) - public static io.grpc.MethodDescriptor< - com.google.cloudbuild.v1.CancelBuildRequest, com.google.cloudbuild.v1.Build> - getCancelBuildMethod() { - io.grpc.MethodDescriptor< - com.google.cloudbuild.v1.CancelBuildRequest, com.google.cloudbuild.v1.Build> - getCancelBuildMethod; - if ((getCancelBuildMethod = CloudBuildGrpc.getCancelBuildMethod) == null) { - synchronized (CloudBuildGrpc.class) { - if ((getCancelBuildMethod = CloudBuildGrpc.getCancelBuildMethod) == null) { - CloudBuildGrpc.getCancelBuildMethod = - getCancelBuildMethod = - io.grpc.MethodDescriptor - . - newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName(generateFullMethodName(SERVICE_NAME, "CancelBuild")) - .setSampledToLocalTracing(true) - .setRequestMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloudbuild.v1.CancelBuildRequest.getDefaultInstance())) - .setResponseMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloudbuild.v1.Build.getDefaultInstance())) - .setSchemaDescriptor(new CloudBuildMethodDescriptorSupplier("CancelBuild")) - .build(); - } - } - } - return getCancelBuildMethod; - } - - private static volatile io.grpc.MethodDescriptor< - com.google.cloudbuild.v1.RetryBuildRequest, com.google.longrunning.Operation> - getRetryBuildMethod; - - @io.grpc.stub.annotations.RpcMethod( - fullMethodName = SERVICE_NAME + '/' + "RetryBuild", - requestType = com.google.cloudbuild.v1.RetryBuildRequest.class, - responseType = com.google.longrunning.Operation.class, - methodType = io.grpc.MethodDescriptor.MethodType.UNARY) - public static io.grpc.MethodDescriptor< - com.google.cloudbuild.v1.RetryBuildRequest, com.google.longrunning.Operation> - getRetryBuildMethod() { - io.grpc.MethodDescriptor< - com.google.cloudbuild.v1.RetryBuildRequest, com.google.longrunning.Operation> - getRetryBuildMethod; - if ((getRetryBuildMethod = CloudBuildGrpc.getRetryBuildMethod) == null) { - synchronized (CloudBuildGrpc.class) { - if ((getRetryBuildMethod = CloudBuildGrpc.getRetryBuildMethod) == null) { - CloudBuildGrpc.getRetryBuildMethod = - getRetryBuildMethod = - io.grpc.MethodDescriptor - . - newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName(generateFullMethodName(SERVICE_NAME, "RetryBuild")) - .setSampledToLocalTracing(true) - .setRequestMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloudbuild.v1.RetryBuildRequest.getDefaultInstance())) - .setResponseMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.longrunning.Operation.getDefaultInstance())) - .setSchemaDescriptor(new CloudBuildMethodDescriptorSupplier("RetryBuild")) - .build(); - } - } - } - return getRetryBuildMethod; - } - - private static volatile io.grpc.MethodDescriptor< - com.google.cloudbuild.v1.ApproveBuildRequest, com.google.longrunning.Operation> - getApproveBuildMethod; - - @io.grpc.stub.annotations.RpcMethod( - fullMethodName = SERVICE_NAME + '/' + "ApproveBuild", - requestType = com.google.cloudbuild.v1.ApproveBuildRequest.class, - responseType = com.google.longrunning.Operation.class, - methodType = io.grpc.MethodDescriptor.MethodType.UNARY) - public static io.grpc.MethodDescriptor< - com.google.cloudbuild.v1.ApproveBuildRequest, com.google.longrunning.Operation> - getApproveBuildMethod() { - io.grpc.MethodDescriptor< - com.google.cloudbuild.v1.ApproveBuildRequest, com.google.longrunning.Operation> - getApproveBuildMethod; - if ((getApproveBuildMethod = CloudBuildGrpc.getApproveBuildMethod) == null) { - synchronized (CloudBuildGrpc.class) { - if ((getApproveBuildMethod = CloudBuildGrpc.getApproveBuildMethod) == null) { - CloudBuildGrpc.getApproveBuildMethod = - getApproveBuildMethod = - io.grpc.MethodDescriptor - . - newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName(generateFullMethodName(SERVICE_NAME, "ApproveBuild")) - .setSampledToLocalTracing(true) - .setRequestMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloudbuild.v1.ApproveBuildRequest.getDefaultInstance())) - .setResponseMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.longrunning.Operation.getDefaultInstance())) - .setSchemaDescriptor(new CloudBuildMethodDescriptorSupplier("ApproveBuild")) - .build(); - } - } - } - return getApproveBuildMethod; - } - - private static volatile io.grpc.MethodDescriptor< - com.google.cloudbuild.v1.CreateBuildTriggerRequest, com.google.cloudbuild.v1.BuildTrigger> - getCreateBuildTriggerMethod; - - @io.grpc.stub.annotations.RpcMethod( - fullMethodName = SERVICE_NAME + '/' + "CreateBuildTrigger", - requestType = com.google.cloudbuild.v1.CreateBuildTriggerRequest.class, - responseType = com.google.cloudbuild.v1.BuildTrigger.class, - methodType = io.grpc.MethodDescriptor.MethodType.UNARY) - public static io.grpc.MethodDescriptor< - com.google.cloudbuild.v1.CreateBuildTriggerRequest, com.google.cloudbuild.v1.BuildTrigger> - getCreateBuildTriggerMethod() { - io.grpc.MethodDescriptor< - com.google.cloudbuild.v1.CreateBuildTriggerRequest, - com.google.cloudbuild.v1.BuildTrigger> - getCreateBuildTriggerMethod; - if ((getCreateBuildTriggerMethod = CloudBuildGrpc.getCreateBuildTriggerMethod) == null) { - synchronized (CloudBuildGrpc.class) { - if ((getCreateBuildTriggerMethod = CloudBuildGrpc.getCreateBuildTriggerMethod) == null) { - CloudBuildGrpc.getCreateBuildTriggerMethod = - getCreateBuildTriggerMethod = - io.grpc.MethodDescriptor - . - newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName(generateFullMethodName(SERVICE_NAME, "CreateBuildTrigger")) - .setSampledToLocalTracing(true) - .setRequestMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloudbuild.v1.CreateBuildTriggerRequest - .getDefaultInstance())) - .setResponseMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloudbuild.v1.BuildTrigger.getDefaultInstance())) - .setSchemaDescriptor( - new CloudBuildMethodDescriptorSupplier("CreateBuildTrigger")) - .build(); - } - } - } - return getCreateBuildTriggerMethod; - } - - private static volatile io.grpc.MethodDescriptor< - com.google.cloudbuild.v1.GetBuildTriggerRequest, com.google.cloudbuild.v1.BuildTrigger> - getGetBuildTriggerMethod; - - @io.grpc.stub.annotations.RpcMethod( - fullMethodName = SERVICE_NAME + '/' + "GetBuildTrigger", - requestType = com.google.cloudbuild.v1.GetBuildTriggerRequest.class, - responseType = com.google.cloudbuild.v1.BuildTrigger.class, - methodType = io.grpc.MethodDescriptor.MethodType.UNARY) - public static io.grpc.MethodDescriptor< - com.google.cloudbuild.v1.GetBuildTriggerRequest, com.google.cloudbuild.v1.BuildTrigger> - getGetBuildTriggerMethod() { - io.grpc.MethodDescriptor< - com.google.cloudbuild.v1.GetBuildTriggerRequest, com.google.cloudbuild.v1.BuildTrigger> - getGetBuildTriggerMethod; - if ((getGetBuildTriggerMethod = CloudBuildGrpc.getGetBuildTriggerMethod) == null) { - synchronized (CloudBuildGrpc.class) { - if ((getGetBuildTriggerMethod = CloudBuildGrpc.getGetBuildTriggerMethod) == null) { - CloudBuildGrpc.getGetBuildTriggerMethod = - getGetBuildTriggerMethod = - io.grpc.MethodDescriptor - . - newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetBuildTrigger")) - .setSampledToLocalTracing(true) - .setRequestMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloudbuild.v1.GetBuildTriggerRequest.getDefaultInstance())) - .setResponseMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloudbuild.v1.BuildTrigger.getDefaultInstance())) - .setSchemaDescriptor( - new CloudBuildMethodDescriptorSupplier("GetBuildTrigger")) - .build(); - } - } - } - return getGetBuildTriggerMethod; - } - - private static volatile io.grpc.MethodDescriptor< - com.google.cloudbuild.v1.ListBuildTriggersRequest, - com.google.cloudbuild.v1.ListBuildTriggersResponse> - getListBuildTriggersMethod; - - @io.grpc.stub.annotations.RpcMethod( - fullMethodName = SERVICE_NAME + '/' + "ListBuildTriggers", - requestType = com.google.cloudbuild.v1.ListBuildTriggersRequest.class, - responseType = com.google.cloudbuild.v1.ListBuildTriggersResponse.class, - methodType = io.grpc.MethodDescriptor.MethodType.UNARY) - public static io.grpc.MethodDescriptor< - com.google.cloudbuild.v1.ListBuildTriggersRequest, - com.google.cloudbuild.v1.ListBuildTriggersResponse> - getListBuildTriggersMethod() { - io.grpc.MethodDescriptor< - com.google.cloudbuild.v1.ListBuildTriggersRequest, - com.google.cloudbuild.v1.ListBuildTriggersResponse> - getListBuildTriggersMethod; - if ((getListBuildTriggersMethod = CloudBuildGrpc.getListBuildTriggersMethod) == null) { - synchronized (CloudBuildGrpc.class) { - if ((getListBuildTriggersMethod = CloudBuildGrpc.getListBuildTriggersMethod) == null) { - CloudBuildGrpc.getListBuildTriggersMethod = - getListBuildTriggersMethod = - io.grpc.MethodDescriptor - . - newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName(generateFullMethodName(SERVICE_NAME, "ListBuildTriggers")) - .setSampledToLocalTracing(true) - .setRequestMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloudbuild.v1.ListBuildTriggersRequest - .getDefaultInstance())) - .setResponseMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloudbuild.v1.ListBuildTriggersResponse - .getDefaultInstance())) - .setSchemaDescriptor( - new CloudBuildMethodDescriptorSupplier("ListBuildTriggers")) - .build(); - } - } - } - return getListBuildTriggersMethod; - } - - private static volatile io.grpc.MethodDescriptor< - com.google.cloudbuild.v1.DeleteBuildTriggerRequest, com.google.protobuf.Empty> - getDeleteBuildTriggerMethod; - - @io.grpc.stub.annotations.RpcMethod( - fullMethodName = SERVICE_NAME + '/' + "DeleteBuildTrigger", - requestType = com.google.cloudbuild.v1.DeleteBuildTriggerRequest.class, - responseType = com.google.protobuf.Empty.class, - methodType = io.grpc.MethodDescriptor.MethodType.UNARY) - public static io.grpc.MethodDescriptor< - com.google.cloudbuild.v1.DeleteBuildTriggerRequest, com.google.protobuf.Empty> - getDeleteBuildTriggerMethod() { - io.grpc.MethodDescriptor< - com.google.cloudbuild.v1.DeleteBuildTriggerRequest, com.google.protobuf.Empty> - getDeleteBuildTriggerMethod; - if ((getDeleteBuildTriggerMethod = CloudBuildGrpc.getDeleteBuildTriggerMethod) == null) { - synchronized (CloudBuildGrpc.class) { - if ((getDeleteBuildTriggerMethod = CloudBuildGrpc.getDeleteBuildTriggerMethod) == null) { - CloudBuildGrpc.getDeleteBuildTriggerMethod = - getDeleteBuildTriggerMethod = - io.grpc.MethodDescriptor - . - newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName(generateFullMethodName(SERVICE_NAME, "DeleteBuildTrigger")) - .setSampledToLocalTracing(true) - .setRequestMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloudbuild.v1.DeleteBuildTriggerRequest - .getDefaultInstance())) - .setResponseMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.protobuf.Empty.getDefaultInstance())) - .setSchemaDescriptor( - new CloudBuildMethodDescriptorSupplier("DeleteBuildTrigger")) - .build(); - } - } - } - return getDeleteBuildTriggerMethod; - } - - private static volatile io.grpc.MethodDescriptor< - com.google.cloudbuild.v1.UpdateBuildTriggerRequest, com.google.cloudbuild.v1.BuildTrigger> - getUpdateBuildTriggerMethod; - - @io.grpc.stub.annotations.RpcMethod( - fullMethodName = SERVICE_NAME + '/' + "UpdateBuildTrigger", - requestType = com.google.cloudbuild.v1.UpdateBuildTriggerRequest.class, - responseType = com.google.cloudbuild.v1.BuildTrigger.class, - methodType = io.grpc.MethodDescriptor.MethodType.UNARY) - public static io.grpc.MethodDescriptor< - com.google.cloudbuild.v1.UpdateBuildTriggerRequest, com.google.cloudbuild.v1.BuildTrigger> - getUpdateBuildTriggerMethod() { - io.grpc.MethodDescriptor< - com.google.cloudbuild.v1.UpdateBuildTriggerRequest, - com.google.cloudbuild.v1.BuildTrigger> - getUpdateBuildTriggerMethod; - if ((getUpdateBuildTriggerMethod = CloudBuildGrpc.getUpdateBuildTriggerMethod) == null) { - synchronized (CloudBuildGrpc.class) { - if ((getUpdateBuildTriggerMethod = CloudBuildGrpc.getUpdateBuildTriggerMethod) == null) { - CloudBuildGrpc.getUpdateBuildTriggerMethod = - getUpdateBuildTriggerMethod = - io.grpc.MethodDescriptor - . - newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName(generateFullMethodName(SERVICE_NAME, "UpdateBuildTrigger")) - .setSampledToLocalTracing(true) - .setRequestMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloudbuild.v1.UpdateBuildTriggerRequest - .getDefaultInstance())) - .setResponseMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloudbuild.v1.BuildTrigger.getDefaultInstance())) - .setSchemaDescriptor( - new CloudBuildMethodDescriptorSupplier("UpdateBuildTrigger")) - .build(); - } - } - } - return getUpdateBuildTriggerMethod; - } - - private static volatile io.grpc.MethodDescriptor< - com.google.cloudbuild.v1.RunBuildTriggerRequest, com.google.longrunning.Operation> - getRunBuildTriggerMethod; - - @io.grpc.stub.annotations.RpcMethod( - fullMethodName = SERVICE_NAME + '/' + "RunBuildTrigger", - requestType = com.google.cloudbuild.v1.RunBuildTriggerRequest.class, - responseType = com.google.longrunning.Operation.class, - methodType = io.grpc.MethodDescriptor.MethodType.UNARY) - public static io.grpc.MethodDescriptor< - com.google.cloudbuild.v1.RunBuildTriggerRequest, com.google.longrunning.Operation> - getRunBuildTriggerMethod() { - io.grpc.MethodDescriptor< - com.google.cloudbuild.v1.RunBuildTriggerRequest, com.google.longrunning.Operation> - getRunBuildTriggerMethod; - if ((getRunBuildTriggerMethod = CloudBuildGrpc.getRunBuildTriggerMethod) == null) { - synchronized (CloudBuildGrpc.class) { - if ((getRunBuildTriggerMethod = CloudBuildGrpc.getRunBuildTriggerMethod) == null) { - CloudBuildGrpc.getRunBuildTriggerMethod = - getRunBuildTriggerMethod = - io.grpc.MethodDescriptor - . - newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName(generateFullMethodName(SERVICE_NAME, "RunBuildTrigger")) - .setSampledToLocalTracing(true) - .setRequestMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloudbuild.v1.RunBuildTriggerRequest.getDefaultInstance())) - .setResponseMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.longrunning.Operation.getDefaultInstance())) - .setSchemaDescriptor( - new CloudBuildMethodDescriptorSupplier("RunBuildTrigger")) - .build(); - } - } - } - return getRunBuildTriggerMethod; - } - - private static volatile io.grpc.MethodDescriptor< - com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest, - com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse> - getReceiveTriggerWebhookMethod; - - @io.grpc.stub.annotations.RpcMethod( - fullMethodName = SERVICE_NAME + '/' + "ReceiveTriggerWebhook", - requestType = com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest.class, - responseType = com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse.class, - methodType = io.grpc.MethodDescriptor.MethodType.UNARY) - public static io.grpc.MethodDescriptor< - com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest, - com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse> - getReceiveTriggerWebhookMethod() { - io.grpc.MethodDescriptor< - com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest, - com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse> - getReceiveTriggerWebhookMethod; - if ((getReceiveTriggerWebhookMethod = CloudBuildGrpc.getReceiveTriggerWebhookMethod) == null) { - synchronized (CloudBuildGrpc.class) { - if ((getReceiveTriggerWebhookMethod = CloudBuildGrpc.getReceiveTriggerWebhookMethod) - == null) { - CloudBuildGrpc.getReceiveTriggerWebhookMethod = - getReceiveTriggerWebhookMethod = - io.grpc.MethodDescriptor - . - newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName( - generateFullMethodName(SERVICE_NAME, "ReceiveTriggerWebhook")) - .setSampledToLocalTracing(true) - .setRequestMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest - .getDefaultInstance())) - .setResponseMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse - .getDefaultInstance())) - .setSchemaDescriptor( - new CloudBuildMethodDescriptorSupplier("ReceiveTriggerWebhook")) - .build(); - } - } - } - return getReceiveTriggerWebhookMethod; - } - - private static volatile io.grpc.MethodDescriptor< - com.google.cloudbuild.v1.CreateWorkerPoolRequest, com.google.longrunning.Operation> - getCreateWorkerPoolMethod; - - @io.grpc.stub.annotations.RpcMethod( - fullMethodName = SERVICE_NAME + '/' + "CreateWorkerPool", - requestType = com.google.cloudbuild.v1.CreateWorkerPoolRequest.class, - responseType = com.google.longrunning.Operation.class, - methodType = io.grpc.MethodDescriptor.MethodType.UNARY) - public static io.grpc.MethodDescriptor< - com.google.cloudbuild.v1.CreateWorkerPoolRequest, com.google.longrunning.Operation> - getCreateWorkerPoolMethod() { - io.grpc.MethodDescriptor< - com.google.cloudbuild.v1.CreateWorkerPoolRequest, com.google.longrunning.Operation> - getCreateWorkerPoolMethod; - if ((getCreateWorkerPoolMethod = CloudBuildGrpc.getCreateWorkerPoolMethod) == null) { - synchronized (CloudBuildGrpc.class) { - if ((getCreateWorkerPoolMethod = CloudBuildGrpc.getCreateWorkerPoolMethod) == null) { - CloudBuildGrpc.getCreateWorkerPoolMethod = - getCreateWorkerPoolMethod = - io.grpc.MethodDescriptor - . - newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName(generateFullMethodName(SERVICE_NAME, "CreateWorkerPool")) - .setSampledToLocalTracing(true) - .setRequestMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloudbuild.v1.CreateWorkerPoolRequest - .getDefaultInstance())) - .setResponseMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.longrunning.Operation.getDefaultInstance())) - .setSchemaDescriptor( - new CloudBuildMethodDescriptorSupplier("CreateWorkerPool")) - .build(); - } - } - } - return getCreateWorkerPoolMethod; - } - - private static volatile io.grpc.MethodDescriptor< - com.google.cloudbuild.v1.GetWorkerPoolRequest, com.google.cloudbuild.v1.WorkerPool> - getGetWorkerPoolMethod; - - @io.grpc.stub.annotations.RpcMethod( - fullMethodName = SERVICE_NAME + '/' + "GetWorkerPool", - requestType = com.google.cloudbuild.v1.GetWorkerPoolRequest.class, - responseType = com.google.cloudbuild.v1.WorkerPool.class, - methodType = io.grpc.MethodDescriptor.MethodType.UNARY) - public static io.grpc.MethodDescriptor< - com.google.cloudbuild.v1.GetWorkerPoolRequest, com.google.cloudbuild.v1.WorkerPool> - getGetWorkerPoolMethod() { - io.grpc.MethodDescriptor< - com.google.cloudbuild.v1.GetWorkerPoolRequest, com.google.cloudbuild.v1.WorkerPool> - getGetWorkerPoolMethod; - if ((getGetWorkerPoolMethod = CloudBuildGrpc.getGetWorkerPoolMethod) == null) { - synchronized (CloudBuildGrpc.class) { - if ((getGetWorkerPoolMethod = CloudBuildGrpc.getGetWorkerPoolMethod) == null) { - CloudBuildGrpc.getGetWorkerPoolMethod = - getGetWorkerPoolMethod = - io.grpc.MethodDescriptor - . - newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetWorkerPool")) - .setSampledToLocalTracing(true) - .setRequestMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloudbuild.v1.GetWorkerPoolRequest.getDefaultInstance())) - .setResponseMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloudbuild.v1.WorkerPool.getDefaultInstance())) - .setSchemaDescriptor(new CloudBuildMethodDescriptorSupplier("GetWorkerPool")) - .build(); - } - } - } - return getGetWorkerPoolMethod; - } - - private static volatile io.grpc.MethodDescriptor< - com.google.cloudbuild.v1.DeleteWorkerPoolRequest, com.google.longrunning.Operation> - getDeleteWorkerPoolMethod; - - @io.grpc.stub.annotations.RpcMethod( - fullMethodName = SERVICE_NAME + '/' + "DeleteWorkerPool", - requestType = com.google.cloudbuild.v1.DeleteWorkerPoolRequest.class, - responseType = com.google.longrunning.Operation.class, - methodType = io.grpc.MethodDescriptor.MethodType.UNARY) - public static io.grpc.MethodDescriptor< - com.google.cloudbuild.v1.DeleteWorkerPoolRequest, com.google.longrunning.Operation> - getDeleteWorkerPoolMethod() { - io.grpc.MethodDescriptor< - com.google.cloudbuild.v1.DeleteWorkerPoolRequest, com.google.longrunning.Operation> - getDeleteWorkerPoolMethod; - if ((getDeleteWorkerPoolMethod = CloudBuildGrpc.getDeleteWorkerPoolMethod) == null) { - synchronized (CloudBuildGrpc.class) { - if ((getDeleteWorkerPoolMethod = CloudBuildGrpc.getDeleteWorkerPoolMethod) == null) { - CloudBuildGrpc.getDeleteWorkerPoolMethod = - getDeleteWorkerPoolMethod = - io.grpc.MethodDescriptor - . - newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName(generateFullMethodName(SERVICE_NAME, "DeleteWorkerPool")) - .setSampledToLocalTracing(true) - .setRequestMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloudbuild.v1.DeleteWorkerPoolRequest - .getDefaultInstance())) - .setResponseMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.longrunning.Operation.getDefaultInstance())) - .setSchemaDescriptor( - new CloudBuildMethodDescriptorSupplier("DeleteWorkerPool")) - .build(); - } - } - } - return getDeleteWorkerPoolMethod; - } - - private static volatile io.grpc.MethodDescriptor< - com.google.cloudbuild.v1.UpdateWorkerPoolRequest, com.google.longrunning.Operation> - getUpdateWorkerPoolMethod; - - @io.grpc.stub.annotations.RpcMethod( - fullMethodName = SERVICE_NAME + '/' + "UpdateWorkerPool", - requestType = com.google.cloudbuild.v1.UpdateWorkerPoolRequest.class, - responseType = com.google.longrunning.Operation.class, - methodType = io.grpc.MethodDescriptor.MethodType.UNARY) - public static io.grpc.MethodDescriptor< - com.google.cloudbuild.v1.UpdateWorkerPoolRequest, com.google.longrunning.Operation> - getUpdateWorkerPoolMethod() { - io.grpc.MethodDescriptor< - com.google.cloudbuild.v1.UpdateWorkerPoolRequest, com.google.longrunning.Operation> - getUpdateWorkerPoolMethod; - if ((getUpdateWorkerPoolMethod = CloudBuildGrpc.getUpdateWorkerPoolMethod) == null) { - synchronized (CloudBuildGrpc.class) { - if ((getUpdateWorkerPoolMethod = CloudBuildGrpc.getUpdateWorkerPoolMethod) == null) { - CloudBuildGrpc.getUpdateWorkerPoolMethod = - getUpdateWorkerPoolMethod = - io.grpc.MethodDescriptor - . - newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName(generateFullMethodName(SERVICE_NAME, "UpdateWorkerPool")) - .setSampledToLocalTracing(true) - .setRequestMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloudbuild.v1.UpdateWorkerPoolRequest - .getDefaultInstance())) - .setResponseMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.longrunning.Operation.getDefaultInstance())) - .setSchemaDescriptor( - new CloudBuildMethodDescriptorSupplier("UpdateWorkerPool")) - .build(); - } - } - } - return getUpdateWorkerPoolMethod; - } - - private static volatile io.grpc.MethodDescriptor< - com.google.cloudbuild.v1.ListWorkerPoolsRequest, - com.google.cloudbuild.v1.ListWorkerPoolsResponse> - getListWorkerPoolsMethod; - - @io.grpc.stub.annotations.RpcMethod( - fullMethodName = SERVICE_NAME + '/' + "ListWorkerPools", - requestType = com.google.cloudbuild.v1.ListWorkerPoolsRequest.class, - responseType = com.google.cloudbuild.v1.ListWorkerPoolsResponse.class, - methodType = io.grpc.MethodDescriptor.MethodType.UNARY) - public static io.grpc.MethodDescriptor< - com.google.cloudbuild.v1.ListWorkerPoolsRequest, - com.google.cloudbuild.v1.ListWorkerPoolsResponse> - getListWorkerPoolsMethod() { - io.grpc.MethodDescriptor< - com.google.cloudbuild.v1.ListWorkerPoolsRequest, - com.google.cloudbuild.v1.ListWorkerPoolsResponse> - getListWorkerPoolsMethod; - if ((getListWorkerPoolsMethod = CloudBuildGrpc.getListWorkerPoolsMethod) == null) { - synchronized (CloudBuildGrpc.class) { - if ((getListWorkerPoolsMethod = CloudBuildGrpc.getListWorkerPoolsMethod) == null) { - CloudBuildGrpc.getListWorkerPoolsMethod = - getListWorkerPoolsMethod = - io.grpc.MethodDescriptor - . - newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName(generateFullMethodName(SERVICE_NAME, "ListWorkerPools")) - .setSampledToLocalTracing(true) - .setRequestMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloudbuild.v1.ListWorkerPoolsRequest.getDefaultInstance())) - .setResponseMarshaller( - io.grpc.protobuf.ProtoUtils.marshaller( - com.google.cloudbuild.v1.ListWorkerPoolsResponse - .getDefaultInstance())) - .setSchemaDescriptor( - new CloudBuildMethodDescriptorSupplier("ListWorkerPools")) - .build(); - } - } - } - return getListWorkerPoolsMethod; - } - - /** Creates a new async stub that supports all call types for the service */ - public static CloudBuildStub newStub(io.grpc.Channel channel) { - io.grpc.stub.AbstractStub.StubFactory factory = - new io.grpc.stub.AbstractStub.StubFactory() { - @java.lang.Override - public CloudBuildStub newStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { - return new CloudBuildStub(channel, callOptions); - } - }; - return CloudBuildStub.newStub(factory, channel); - } - - /** - * Creates a new blocking-style stub that supports unary and streaming output calls on the service - */ - public static CloudBuildBlockingStub newBlockingStub(io.grpc.Channel channel) { - io.grpc.stub.AbstractStub.StubFactory factory = - new io.grpc.stub.AbstractStub.StubFactory() { - @java.lang.Override - public CloudBuildBlockingStub newStub( - io.grpc.Channel channel, io.grpc.CallOptions callOptions) { - return new CloudBuildBlockingStub(channel, callOptions); - } - }; - return CloudBuildBlockingStub.newStub(factory, channel); - } - - /** Creates a new ListenableFuture-style stub that supports unary calls on the service */ - public static CloudBuildFutureStub newFutureStub(io.grpc.Channel channel) { - io.grpc.stub.AbstractStub.StubFactory factory = - new io.grpc.stub.AbstractStub.StubFactory() { - @java.lang.Override - public CloudBuildFutureStub newStub( - io.grpc.Channel channel, io.grpc.CallOptions callOptions) { - return new CloudBuildFutureStub(channel, callOptions); - } - }; - return CloudBuildFutureStub.newStub(factory, channel); - } - - /** - * - * - *
-   * Creates and manages builds on Google Cloud Platform.
-   * The main concept used by this API is a `Build`, which describes the location
-   * of the source to build, how to build the source, and where to store the
-   * built artifacts, if any.
-   * A user can list previously-requested builds or get builds by their ID to
-   * determine the status of the build.
-   * 
- */ - public abstract static class CloudBuildImplBase implements io.grpc.BindableService { - - /** - * - * - *
-     * Starts a build with the specified configuration.
-     * This method returns a long-running `Operation`, which includes the build
-     * ID. Pass the build ID to `GetBuild` to determine the build status (such as
-     * `SUCCESS` or `FAILURE`).
-     * 
- */ - public void createBuild( - com.google.cloudbuild.v1.CreateBuildRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( - getCreateBuildMethod(), responseObserver); - } - - /** - * - * - *
-     * Returns information about a previously requested build.
-     * The `Build` that is returned includes its status (such as `SUCCESS`,
-     * `FAILURE`, or `WORKING`), and timing information.
-     * 
- */ - public void getBuild( - com.google.cloudbuild.v1.GetBuildRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getGetBuildMethod(), responseObserver); - } - - /** - * - * - *
-     * Lists previously requested builds.
-     * Previously requested builds may still be in-progress, or may have finished
-     * successfully or unsuccessfully.
-     * 
- */ - public void listBuilds( - com.google.cloudbuild.v1.ListBuildsRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getListBuildsMethod(), responseObserver); - } - - /** - * - * - *
-     * Cancels a build in progress.
-     * 
- */ - public void cancelBuild( - com.google.cloudbuild.v1.CancelBuildRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( - getCancelBuildMethod(), responseObserver); - } - - /** - * - * - *
-     * Creates a new build based on the specified build.
-     * This method creates a new build using the original build request, which may
-     * or may not result in an identical build.
-     * For triggered builds:
-     * * Triggered builds resolve to a precise revision; therefore a retry of a
-     * triggered build will result in a build that uses the same revision.
-     * For non-triggered builds that specify `RepoSource`:
-     * * If the original build built from the tip of a branch, the retried build
-     * will build from the tip of that branch, which may not be the same revision
-     * as the original build.
-     * * If the original build specified a commit sha or revision ID, the retried
-     * build will use the identical source.
-     * For builds that specify `StorageSource`:
-     * * If the original build pulled source from Google Cloud Storage without
-     * specifying the generation of the object, the new build will use the current
-     * object, which may be different from the original build source.
-     * * If the original build pulled source from Cloud Storage and specified the
-     * generation of the object, the new build will attempt to use the same
-     * object, which may or may not be available depending on the bucket's
-     * lifecycle management settings.
-     * 
- */ - public void retryBuild( - com.google.cloudbuild.v1.RetryBuildRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getRetryBuildMethod(), responseObserver); - } - - /** - * - * - *
-     * Approves or rejects a pending build.
-     * If approved, the returned LRO will be analogous to the LRO returned from
-     * a CreateBuild call.
-     * If rejected, the returned LRO will be immediately done.
-     * 
- */ - public void approveBuild( - com.google.cloudbuild.v1.ApproveBuildRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( - getApproveBuildMethod(), responseObserver); - } - - /** - * - * - *
-     * Creates a new `BuildTrigger`.
-     * This API is experimental.
-     * 
- */ - public void createBuildTrigger( - com.google.cloudbuild.v1.CreateBuildTriggerRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( - getCreateBuildTriggerMethod(), responseObserver); - } - - /** - * - * - *
-     * Returns information about a `BuildTrigger`.
-     * This API is experimental.
-     * 
- */ - public void getBuildTrigger( - com.google.cloudbuild.v1.GetBuildTriggerRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( - getGetBuildTriggerMethod(), responseObserver); - } - - /** - * - * - *
-     * Lists existing `BuildTrigger`s.
-     * This API is experimental.
-     * 
- */ - public void listBuildTriggers( - com.google.cloudbuild.v1.ListBuildTriggersRequest request, - io.grpc.stub.StreamObserver - responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( - getListBuildTriggersMethod(), responseObserver); - } - - /** - * - * - *
-     * Deletes a `BuildTrigger` by its project ID and trigger ID.
-     * This API is experimental.
-     * 
- */ - public void deleteBuildTrigger( - com.google.cloudbuild.v1.DeleteBuildTriggerRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( - getDeleteBuildTriggerMethod(), responseObserver); - } - - /** - * - * - *
-     * Updates a `BuildTrigger` by its project ID and trigger ID.
-     * This API is experimental.
-     * 
- */ - public void updateBuildTrigger( - com.google.cloudbuild.v1.UpdateBuildTriggerRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( - getUpdateBuildTriggerMethod(), responseObserver); - } - - /** - * - * - *
-     * Runs a `BuildTrigger` at a particular source revision.
-     * 
- */ - public void runBuildTrigger( - com.google.cloudbuild.v1.RunBuildTriggerRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( - getRunBuildTriggerMethod(), responseObserver); - } - - /** - * - * - *
-     * ReceiveTriggerWebhook [Experimental] is called when the API receives a
-     * webhook request targeted at a specific trigger.
-     * 
- */ - public void receiveTriggerWebhook( - com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest request, - io.grpc.stub.StreamObserver - responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( - getReceiveTriggerWebhookMethod(), responseObserver); - } - - /** - * - * - *
-     * Creates a `WorkerPool`.
-     * 
- */ - public void createWorkerPool( - com.google.cloudbuild.v1.CreateWorkerPoolRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( - getCreateWorkerPoolMethod(), responseObserver); - } - - /** - * - * - *
-     * Returns details of a `WorkerPool`.
-     * 
- */ - public void getWorkerPool( - com.google.cloudbuild.v1.GetWorkerPoolRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( - getGetWorkerPoolMethod(), responseObserver); - } - - /** - * - * - *
-     * Deletes a `WorkerPool`.
-     * 
- */ - public void deleteWorkerPool( - com.google.cloudbuild.v1.DeleteWorkerPoolRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( - getDeleteWorkerPoolMethod(), responseObserver); - } - - /** - * - * - *
-     * Updates a `WorkerPool`.
-     * 
- */ - public void updateWorkerPool( - com.google.cloudbuild.v1.UpdateWorkerPoolRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( - getUpdateWorkerPoolMethod(), responseObserver); - } - - /** - * - * - *
-     * Lists `WorkerPool`s.
-     * 
- */ - public void listWorkerPools( - com.google.cloudbuild.v1.ListWorkerPoolsRequest request, - io.grpc.stub.StreamObserver - responseObserver) { - io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall( - getListWorkerPoolsMethod(), responseObserver); - } - - @java.lang.Override - public final io.grpc.ServerServiceDefinition bindService() { - return io.grpc.ServerServiceDefinition.builder(getServiceDescriptor()) - .addMethod( - getCreateBuildMethod(), - io.grpc.stub.ServerCalls.asyncUnaryCall( - new MethodHandlers< - com.google.cloudbuild.v1.CreateBuildRequest, - com.google.longrunning.Operation>(this, METHODID_CREATE_BUILD))) - .addMethod( - getGetBuildMethod(), - io.grpc.stub.ServerCalls.asyncUnaryCall( - new MethodHandlers< - com.google.cloudbuild.v1.GetBuildRequest, com.google.cloudbuild.v1.Build>( - this, METHODID_GET_BUILD))) - .addMethod( - getListBuildsMethod(), - io.grpc.stub.ServerCalls.asyncUnaryCall( - new MethodHandlers< - com.google.cloudbuild.v1.ListBuildsRequest, - com.google.cloudbuild.v1.ListBuildsResponse>(this, METHODID_LIST_BUILDS))) - .addMethod( - getCancelBuildMethod(), - io.grpc.stub.ServerCalls.asyncUnaryCall( - new MethodHandlers< - com.google.cloudbuild.v1.CancelBuildRequest, com.google.cloudbuild.v1.Build>( - this, METHODID_CANCEL_BUILD))) - .addMethod( - getRetryBuildMethod(), - io.grpc.stub.ServerCalls.asyncUnaryCall( - new MethodHandlers< - com.google.cloudbuild.v1.RetryBuildRequest, com.google.longrunning.Operation>( - this, METHODID_RETRY_BUILD))) - .addMethod( - getApproveBuildMethod(), - io.grpc.stub.ServerCalls.asyncUnaryCall( - new MethodHandlers< - com.google.cloudbuild.v1.ApproveBuildRequest, - com.google.longrunning.Operation>(this, METHODID_APPROVE_BUILD))) - .addMethod( - getCreateBuildTriggerMethod(), - io.grpc.stub.ServerCalls.asyncUnaryCall( - new MethodHandlers< - com.google.cloudbuild.v1.CreateBuildTriggerRequest, - com.google.cloudbuild.v1.BuildTrigger>(this, METHODID_CREATE_BUILD_TRIGGER))) - .addMethod( - getGetBuildTriggerMethod(), - io.grpc.stub.ServerCalls.asyncUnaryCall( - new MethodHandlers< - com.google.cloudbuild.v1.GetBuildTriggerRequest, - com.google.cloudbuild.v1.BuildTrigger>(this, METHODID_GET_BUILD_TRIGGER))) - .addMethod( - getListBuildTriggersMethod(), - io.grpc.stub.ServerCalls.asyncUnaryCall( - new MethodHandlers< - com.google.cloudbuild.v1.ListBuildTriggersRequest, - com.google.cloudbuild.v1.ListBuildTriggersResponse>( - this, METHODID_LIST_BUILD_TRIGGERS))) - .addMethod( - getDeleteBuildTriggerMethod(), - io.grpc.stub.ServerCalls.asyncUnaryCall( - new MethodHandlers< - com.google.cloudbuild.v1.DeleteBuildTriggerRequest, - com.google.protobuf.Empty>(this, METHODID_DELETE_BUILD_TRIGGER))) - .addMethod( - getUpdateBuildTriggerMethod(), - io.grpc.stub.ServerCalls.asyncUnaryCall( - new MethodHandlers< - com.google.cloudbuild.v1.UpdateBuildTriggerRequest, - com.google.cloudbuild.v1.BuildTrigger>(this, METHODID_UPDATE_BUILD_TRIGGER))) - .addMethod( - getRunBuildTriggerMethod(), - io.grpc.stub.ServerCalls.asyncUnaryCall( - new MethodHandlers< - com.google.cloudbuild.v1.RunBuildTriggerRequest, - com.google.longrunning.Operation>(this, METHODID_RUN_BUILD_TRIGGER))) - .addMethod( - getReceiveTriggerWebhookMethod(), - io.grpc.stub.ServerCalls.asyncUnaryCall( - new MethodHandlers< - com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest, - com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse>( - this, METHODID_RECEIVE_TRIGGER_WEBHOOK))) - .addMethod( - getCreateWorkerPoolMethod(), - io.grpc.stub.ServerCalls.asyncUnaryCall( - new MethodHandlers< - com.google.cloudbuild.v1.CreateWorkerPoolRequest, - com.google.longrunning.Operation>(this, METHODID_CREATE_WORKER_POOL))) - .addMethod( - getGetWorkerPoolMethod(), - io.grpc.stub.ServerCalls.asyncUnaryCall( - new MethodHandlers< - com.google.cloudbuild.v1.GetWorkerPoolRequest, - com.google.cloudbuild.v1.WorkerPool>(this, METHODID_GET_WORKER_POOL))) - .addMethod( - getDeleteWorkerPoolMethod(), - io.grpc.stub.ServerCalls.asyncUnaryCall( - new MethodHandlers< - com.google.cloudbuild.v1.DeleteWorkerPoolRequest, - com.google.longrunning.Operation>(this, METHODID_DELETE_WORKER_POOL))) - .addMethod( - getUpdateWorkerPoolMethod(), - io.grpc.stub.ServerCalls.asyncUnaryCall( - new MethodHandlers< - com.google.cloudbuild.v1.UpdateWorkerPoolRequest, - com.google.longrunning.Operation>(this, METHODID_UPDATE_WORKER_POOL))) - .addMethod( - getListWorkerPoolsMethod(), - io.grpc.stub.ServerCalls.asyncUnaryCall( - new MethodHandlers< - com.google.cloudbuild.v1.ListWorkerPoolsRequest, - com.google.cloudbuild.v1.ListWorkerPoolsResponse>( - this, METHODID_LIST_WORKER_POOLS))) - .build(); - } - } - - /** - * - * - *
-   * Creates and manages builds on Google Cloud Platform.
-   * The main concept used by this API is a `Build`, which describes the location
-   * of the source to build, how to build the source, and where to store the
-   * built artifacts, if any.
-   * A user can list previously-requested builds or get builds by their ID to
-   * determine the status of the build.
-   * 
- */ - public static final class CloudBuildStub extends io.grpc.stub.AbstractAsyncStub { - private CloudBuildStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { - super(channel, callOptions); - } - - @java.lang.Override - protected CloudBuildStub build(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { - return new CloudBuildStub(channel, callOptions); - } - - /** - * - * - *
-     * Starts a build with the specified configuration.
-     * This method returns a long-running `Operation`, which includes the build
-     * ID. Pass the build ID to `GetBuild` to determine the build status (such as
-     * `SUCCESS` or `FAILURE`).
-     * 
- */ - public void createBuild( - com.google.cloudbuild.v1.CreateBuildRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getCreateBuildMethod(), getCallOptions()), - request, - responseObserver); - } - - /** - * - * - *
-     * Returns information about a previously requested build.
-     * The `Build` that is returned includes its status (such as `SUCCESS`,
-     * `FAILURE`, or `WORKING`), and timing information.
-     * 
- */ - public void getBuild( - com.google.cloudbuild.v1.GetBuildRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getGetBuildMethod(), getCallOptions()), request, responseObserver); - } - - /** - * - * - *
-     * Lists previously requested builds.
-     * Previously requested builds may still be in-progress, or may have finished
-     * successfully or unsuccessfully.
-     * 
- */ - public void listBuilds( - com.google.cloudbuild.v1.ListBuildsRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getListBuildsMethod(), getCallOptions()), request, responseObserver); - } - - /** - * - * - *
-     * Cancels a build in progress.
-     * 
- */ - public void cancelBuild( - com.google.cloudbuild.v1.CancelBuildRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getCancelBuildMethod(), getCallOptions()), - request, - responseObserver); - } - - /** - * - * - *
-     * Creates a new build based on the specified build.
-     * This method creates a new build using the original build request, which may
-     * or may not result in an identical build.
-     * For triggered builds:
-     * * Triggered builds resolve to a precise revision; therefore a retry of a
-     * triggered build will result in a build that uses the same revision.
-     * For non-triggered builds that specify `RepoSource`:
-     * * If the original build built from the tip of a branch, the retried build
-     * will build from the tip of that branch, which may not be the same revision
-     * as the original build.
-     * * If the original build specified a commit sha or revision ID, the retried
-     * build will use the identical source.
-     * For builds that specify `StorageSource`:
-     * * If the original build pulled source from Google Cloud Storage without
-     * specifying the generation of the object, the new build will use the current
-     * object, which may be different from the original build source.
-     * * If the original build pulled source from Cloud Storage and specified the
-     * generation of the object, the new build will attempt to use the same
-     * object, which may or may not be available depending on the bucket's
-     * lifecycle management settings.
-     * 
- */ - public void retryBuild( - com.google.cloudbuild.v1.RetryBuildRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getRetryBuildMethod(), getCallOptions()), request, responseObserver); - } - - /** - * - * - *
-     * Approves or rejects a pending build.
-     * If approved, the returned LRO will be analogous to the LRO returned from
-     * a CreateBuild call.
-     * If rejected, the returned LRO will be immediately done.
-     * 
- */ - public void approveBuild( - com.google.cloudbuild.v1.ApproveBuildRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getApproveBuildMethod(), getCallOptions()), - request, - responseObserver); - } - - /** - * - * - *
-     * Creates a new `BuildTrigger`.
-     * This API is experimental.
-     * 
- */ - public void createBuildTrigger( - com.google.cloudbuild.v1.CreateBuildTriggerRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getCreateBuildTriggerMethod(), getCallOptions()), - request, - responseObserver); - } - - /** - * - * - *
-     * Returns information about a `BuildTrigger`.
-     * This API is experimental.
-     * 
- */ - public void getBuildTrigger( - com.google.cloudbuild.v1.GetBuildTriggerRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getGetBuildTriggerMethod(), getCallOptions()), - request, - responseObserver); - } - - /** - * - * - *
-     * Lists existing `BuildTrigger`s.
-     * This API is experimental.
-     * 
- */ - public void listBuildTriggers( - com.google.cloudbuild.v1.ListBuildTriggersRequest request, - io.grpc.stub.StreamObserver - responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getListBuildTriggersMethod(), getCallOptions()), - request, - responseObserver); - } - - /** - * - * - *
-     * Deletes a `BuildTrigger` by its project ID and trigger ID.
-     * This API is experimental.
-     * 
- */ - public void deleteBuildTrigger( - com.google.cloudbuild.v1.DeleteBuildTriggerRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getDeleteBuildTriggerMethod(), getCallOptions()), - request, - responseObserver); - } - - /** - * - * - *
-     * Updates a `BuildTrigger` by its project ID and trigger ID.
-     * This API is experimental.
-     * 
- */ - public void updateBuildTrigger( - com.google.cloudbuild.v1.UpdateBuildTriggerRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getUpdateBuildTriggerMethod(), getCallOptions()), - request, - responseObserver); - } - - /** - * - * - *
-     * Runs a `BuildTrigger` at a particular source revision.
-     * 
- */ - public void runBuildTrigger( - com.google.cloudbuild.v1.RunBuildTriggerRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getRunBuildTriggerMethod(), getCallOptions()), - request, - responseObserver); - } - - /** - * - * - *
-     * ReceiveTriggerWebhook [Experimental] is called when the API receives a
-     * webhook request targeted at a specific trigger.
-     * 
- */ - public void receiveTriggerWebhook( - com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest request, - io.grpc.stub.StreamObserver - responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getReceiveTriggerWebhookMethod(), getCallOptions()), - request, - responseObserver); - } - - /** - * - * - *
-     * Creates a `WorkerPool`.
-     * 
- */ - public void createWorkerPool( - com.google.cloudbuild.v1.CreateWorkerPoolRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getCreateWorkerPoolMethod(), getCallOptions()), - request, - responseObserver); - } - - /** - * - * - *
-     * Returns details of a `WorkerPool`.
-     * 
- */ - public void getWorkerPool( - com.google.cloudbuild.v1.GetWorkerPoolRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getGetWorkerPoolMethod(), getCallOptions()), - request, - responseObserver); - } - - /** - * - * - *
-     * Deletes a `WorkerPool`.
-     * 
- */ - public void deleteWorkerPool( - com.google.cloudbuild.v1.DeleteWorkerPoolRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getDeleteWorkerPoolMethod(), getCallOptions()), - request, - responseObserver); - } - - /** - * - * - *
-     * Updates a `WorkerPool`.
-     * 
- */ - public void updateWorkerPool( - com.google.cloudbuild.v1.UpdateWorkerPoolRequest request, - io.grpc.stub.StreamObserver responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getUpdateWorkerPoolMethod(), getCallOptions()), - request, - responseObserver); - } - - /** - * - * - *
-     * Lists `WorkerPool`s.
-     * 
- */ - public void listWorkerPools( - com.google.cloudbuild.v1.ListWorkerPoolsRequest request, - io.grpc.stub.StreamObserver - responseObserver) { - io.grpc.stub.ClientCalls.asyncUnaryCall( - getChannel().newCall(getListWorkerPoolsMethod(), getCallOptions()), - request, - responseObserver); - } - } - - /** - * - * - *
-   * Creates and manages builds on Google Cloud Platform.
-   * The main concept used by this API is a `Build`, which describes the location
-   * of the source to build, how to build the source, and where to store the
-   * built artifacts, if any.
-   * A user can list previously-requested builds or get builds by their ID to
-   * determine the status of the build.
-   * 
- */ - public static final class CloudBuildBlockingStub - extends io.grpc.stub.AbstractBlockingStub { - private CloudBuildBlockingStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { - super(channel, callOptions); - } - - @java.lang.Override - protected CloudBuildBlockingStub build( - io.grpc.Channel channel, io.grpc.CallOptions callOptions) { - return new CloudBuildBlockingStub(channel, callOptions); - } - - /** - * - * - *
-     * Starts a build with the specified configuration.
-     * This method returns a long-running `Operation`, which includes the build
-     * ID. Pass the build ID to `GetBuild` to determine the build status (such as
-     * `SUCCESS` or `FAILURE`).
-     * 
- */ - public com.google.longrunning.Operation createBuild( - com.google.cloudbuild.v1.CreateBuildRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getCreateBuildMethod(), getCallOptions(), request); - } - - /** - * - * - *
-     * Returns information about a previously requested build.
-     * The `Build` that is returned includes its status (such as `SUCCESS`,
-     * `FAILURE`, or `WORKING`), and timing information.
-     * 
- */ - public com.google.cloudbuild.v1.Build getBuild( - com.google.cloudbuild.v1.GetBuildRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getGetBuildMethod(), getCallOptions(), request); - } - - /** - * - * - *
-     * Lists previously requested builds.
-     * Previously requested builds may still be in-progress, or may have finished
-     * successfully or unsuccessfully.
-     * 
- */ - public com.google.cloudbuild.v1.ListBuildsResponse listBuilds( - com.google.cloudbuild.v1.ListBuildsRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getListBuildsMethod(), getCallOptions(), request); - } - - /** - * - * - *
-     * Cancels a build in progress.
-     * 
- */ - public com.google.cloudbuild.v1.Build cancelBuild( - com.google.cloudbuild.v1.CancelBuildRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getCancelBuildMethod(), getCallOptions(), request); - } - - /** - * - * - *
-     * Creates a new build based on the specified build.
-     * This method creates a new build using the original build request, which may
-     * or may not result in an identical build.
-     * For triggered builds:
-     * * Triggered builds resolve to a precise revision; therefore a retry of a
-     * triggered build will result in a build that uses the same revision.
-     * For non-triggered builds that specify `RepoSource`:
-     * * If the original build built from the tip of a branch, the retried build
-     * will build from the tip of that branch, which may not be the same revision
-     * as the original build.
-     * * If the original build specified a commit sha or revision ID, the retried
-     * build will use the identical source.
-     * For builds that specify `StorageSource`:
-     * * If the original build pulled source from Google Cloud Storage without
-     * specifying the generation of the object, the new build will use the current
-     * object, which may be different from the original build source.
-     * * If the original build pulled source from Cloud Storage and specified the
-     * generation of the object, the new build will attempt to use the same
-     * object, which may or may not be available depending on the bucket's
-     * lifecycle management settings.
-     * 
- */ - public com.google.longrunning.Operation retryBuild( - com.google.cloudbuild.v1.RetryBuildRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getRetryBuildMethod(), getCallOptions(), request); - } - - /** - * - * - *
-     * Approves or rejects a pending build.
-     * If approved, the returned LRO will be analogous to the LRO returned from
-     * a CreateBuild call.
-     * If rejected, the returned LRO will be immediately done.
-     * 
- */ - public com.google.longrunning.Operation approveBuild( - com.google.cloudbuild.v1.ApproveBuildRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getApproveBuildMethod(), getCallOptions(), request); - } - - /** - * - * - *
-     * Creates a new `BuildTrigger`.
-     * This API is experimental.
-     * 
- */ - public com.google.cloudbuild.v1.BuildTrigger createBuildTrigger( - com.google.cloudbuild.v1.CreateBuildTriggerRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getCreateBuildTriggerMethod(), getCallOptions(), request); - } - - /** - * - * - *
-     * Returns information about a `BuildTrigger`.
-     * This API is experimental.
-     * 
- */ - public com.google.cloudbuild.v1.BuildTrigger getBuildTrigger( - com.google.cloudbuild.v1.GetBuildTriggerRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getGetBuildTriggerMethod(), getCallOptions(), request); - } - - /** - * - * - *
-     * Lists existing `BuildTrigger`s.
-     * This API is experimental.
-     * 
- */ - public com.google.cloudbuild.v1.ListBuildTriggersResponse listBuildTriggers( - com.google.cloudbuild.v1.ListBuildTriggersRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getListBuildTriggersMethod(), getCallOptions(), request); - } - - /** - * - * - *
-     * Deletes a `BuildTrigger` by its project ID and trigger ID.
-     * This API is experimental.
-     * 
- */ - public com.google.protobuf.Empty deleteBuildTrigger( - com.google.cloudbuild.v1.DeleteBuildTriggerRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getDeleteBuildTriggerMethod(), getCallOptions(), request); - } - - /** - * - * - *
-     * Updates a `BuildTrigger` by its project ID and trigger ID.
-     * This API is experimental.
-     * 
- */ - public com.google.cloudbuild.v1.BuildTrigger updateBuildTrigger( - com.google.cloudbuild.v1.UpdateBuildTriggerRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getUpdateBuildTriggerMethod(), getCallOptions(), request); - } - - /** - * - * - *
-     * Runs a `BuildTrigger` at a particular source revision.
-     * 
- */ - public com.google.longrunning.Operation runBuildTrigger( - com.google.cloudbuild.v1.RunBuildTriggerRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getRunBuildTriggerMethod(), getCallOptions(), request); - } - - /** - * - * - *
-     * ReceiveTriggerWebhook [Experimental] is called when the API receives a
-     * webhook request targeted at a specific trigger.
-     * 
- */ - public com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse receiveTriggerWebhook( - com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getReceiveTriggerWebhookMethod(), getCallOptions(), request); - } - - /** - * - * - *
-     * Creates a `WorkerPool`.
-     * 
- */ - public com.google.longrunning.Operation createWorkerPool( - com.google.cloudbuild.v1.CreateWorkerPoolRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getCreateWorkerPoolMethod(), getCallOptions(), request); - } - - /** - * - * - *
-     * Returns details of a `WorkerPool`.
-     * 
- */ - public com.google.cloudbuild.v1.WorkerPool getWorkerPool( - com.google.cloudbuild.v1.GetWorkerPoolRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getGetWorkerPoolMethod(), getCallOptions(), request); - } - - /** - * - * - *
-     * Deletes a `WorkerPool`.
-     * 
- */ - public com.google.longrunning.Operation deleteWorkerPool( - com.google.cloudbuild.v1.DeleteWorkerPoolRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getDeleteWorkerPoolMethod(), getCallOptions(), request); - } - - /** - * - * - *
-     * Updates a `WorkerPool`.
-     * 
- */ - public com.google.longrunning.Operation updateWorkerPool( - com.google.cloudbuild.v1.UpdateWorkerPoolRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getUpdateWorkerPoolMethod(), getCallOptions(), request); - } - - /** - * - * - *
-     * Lists `WorkerPool`s.
-     * 
- */ - public com.google.cloudbuild.v1.ListWorkerPoolsResponse listWorkerPools( - com.google.cloudbuild.v1.ListWorkerPoolsRequest request) { - return io.grpc.stub.ClientCalls.blockingUnaryCall( - getChannel(), getListWorkerPoolsMethod(), getCallOptions(), request); - } - } - - /** - * - * - *
-   * Creates and manages builds on Google Cloud Platform.
-   * The main concept used by this API is a `Build`, which describes the location
-   * of the source to build, how to build the source, and where to store the
-   * built artifacts, if any.
-   * A user can list previously-requested builds or get builds by their ID to
-   * determine the status of the build.
-   * 
- */ - public static final class CloudBuildFutureStub - extends io.grpc.stub.AbstractFutureStub { - private CloudBuildFutureStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { - super(channel, callOptions); - } - - @java.lang.Override - protected CloudBuildFutureStub build(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { - return new CloudBuildFutureStub(channel, callOptions); - } - - /** - * - * - *
-     * Starts a build with the specified configuration.
-     * This method returns a long-running `Operation`, which includes the build
-     * ID. Pass the build ID to `GetBuild` to determine the build status (such as
-     * `SUCCESS` or `FAILURE`).
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture - createBuild(com.google.cloudbuild.v1.CreateBuildRequest request) { - return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getCreateBuildMethod(), getCallOptions()), request); - } - - /** - * - * - *
-     * Returns information about a previously requested build.
-     * The `Build` that is returned includes its status (such as `SUCCESS`,
-     * `FAILURE`, or `WORKING`), and timing information.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture - getBuild(com.google.cloudbuild.v1.GetBuildRequest request) { - return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getGetBuildMethod(), getCallOptions()), request); - } - - /** - * - * - *
-     * Lists previously requested builds.
-     * Previously requested builds may still be in-progress, or may have finished
-     * successfully or unsuccessfully.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture< - com.google.cloudbuild.v1.ListBuildsResponse> - listBuilds(com.google.cloudbuild.v1.ListBuildsRequest request) { - return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getListBuildsMethod(), getCallOptions()), request); - } - - /** - * - * - *
-     * Cancels a build in progress.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture - cancelBuild(com.google.cloudbuild.v1.CancelBuildRequest request) { - return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getCancelBuildMethod(), getCallOptions()), request); - } - - /** - * - * - *
-     * Creates a new build based on the specified build.
-     * This method creates a new build using the original build request, which may
-     * or may not result in an identical build.
-     * For triggered builds:
-     * * Triggered builds resolve to a precise revision; therefore a retry of a
-     * triggered build will result in a build that uses the same revision.
-     * For non-triggered builds that specify `RepoSource`:
-     * * If the original build built from the tip of a branch, the retried build
-     * will build from the tip of that branch, which may not be the same revision
-     * as the original build.
-     * * If the original build specified a commit sha or revision ID, the retried
-     * build will use the identical source.
-     * For builds that specify `StorageSource`:
-     * * If the original build pulled source from Google Cloud Storage without
-     * specifying the generation of the object, the new build will use the current
-     * object, which may be different from the original build source.
-     * * If the original build pulled source from Cloud Storage and specified the
-     * generation of the object, the new build will attempt to use the same
-     * object, which may or may not be available depending on the bucket's
-     * lifecycle management settings.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture - retryBuild(com.google.cloudbuild.v1.RetryBuildRequest request) { - return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getRetryBuildMethod(), getCallOptions()), request); - } - - /** - * - * - *
-     * Approves or rejects a pending build.
-     * If approved, the returned LRO will be analogous to the LRO returned from
-     * a CreateBuild call.
-     * If rejected, the returned LRO will be immediately done.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture - approveBuild(com.google.cloudbuild.v1.ApproveBuildRequest request) { - return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getApproveBuildMethod(), getCallOptions()), request); - } - - /** - * - * - *
-     * Creates a new `BuildTrigger`.
-     * This API is experimental.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture - createBuildTrigger(com.google.cloudbuild.v1.CreateBuildTriggerRequest request) { - return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getCreateBuildTriggerMethod(), getCallOptions()), request); - } - - /** - * - * - *
-     * Returns information about a `BuildTrigger`.
-     * This API is experimental.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture - getBuildTrigger(com.google.cloudbuild.v1.GetBuildTriggerRequest request) { - return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getGetBuildTriggerMethod(), getCallOptions()), request); - } - - /** - * - * - *
-     * Lists existing `BuildTrigger`s.
-     * This API is experimental.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture< - com.google.cloudbuild.v1.ListBuildTriggersResponse> - listBuildTriggers(com.google.cloudbuild.v1.ListBuildTriggersRequest request) { - return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getListBuildTriggersMethod(), getCallOptions()), request); - } - - /** - * - * - *
-     * Deletes a `BuildTrigger` by its project ID and trigger ID.
-     * This API is experimental.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture - deleteBuildTrigger(com.google.cloudbuild.v1.DeleteBuildTriggerRequest request) { - return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getDeleteBuildTriggerMethod(), getCallOptions()), request); - } - - /** - * - * - *
-     * Updates a `BuildTrigger` by its project ID and trigger ID.
-     * This API is experimental.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture - updateBuildTrigger(com.google.cloudbuild.v1.UpdateBuildTriggerRequest request) { - return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getUpdateBuildTriggerMethod(), getCallOptions()), request); - } - - /** - * - * - *
-     * Runs a `BuildTrigger` at a particular source revision.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture - runBuildTrigger(com.google.cloudbuild.v1.RunBuildTriggerRequest request) { - return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getRunBuildTriggerMethod(), getCallOptions()), request); - } - - /** - * - * - *
-     * ReceiveTriggerWebhook [Experimental] is called when the API receives a
-     * webhook request targeted at a specific trigger.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture< - com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse> - receiveTriggerWebhook(com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest request) { - return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getReceiveTriggerWebhookMethod(), getCallOptions()), request); - } - - /** - * - * - *
-     * Creates a `WorkerPool`.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture - createWorkerPool(com.google.cloudbuild.v1.CreateWorkerPoolRequest request) { - return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getCreateWorkerPoolMethod(), getCallOptions()), request); - } - - /** - * - * - *
-     * Returns details of a `WorkerPool`.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture - getWorkerPool(com.google.cloudbuild.v1.GetWorkerPoolRequest request) { - return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getGetWorkerPoolMethod(), getCallOptions()), request); - } - - /** - * - * - *
-     * Deletes a `WorkerPool`.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture - deleteWorkerPool(com.google.cloudbuild.v1.DeleteWorkerPoolRequest request) { - return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getDeleteWorkerPoolMethod(), getCallOptions()), request); - } - - /** - * - * - *
-     * Updates a `WorkerPool`.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture - updateWorkerPool(com.google.cloudbuild.v1.UpdateWorkerPoolRequest request) { - return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getUpdateWorkerPoolMethod(), getCallOptions()), request); - } - - /** - * - * - *
-     * Lists `WorkerPool`s.
-     * 
- */ - public com.google.common.util.concurrent.ListenableFuture< - com.google.cloudbuild.v1.ListWorkerPoolsResponse> - listWorkerPools(com.google.cloudbuild.v1.ListWorkerPoolsRequest request) { - return io.grpc.stub.ClientCalls.futureUnaryCall( - getChannel().newCall(getListWorkerPoolsMethod(), getCallOptions()), request); - } - } - - private static final int METHODID_CREATE_BUILD = 0; - private static final int METHODID_GET_BUILD = 1; - private static final int METHODID_LIST_BUILDS = 2; - private static final int METHODID_CANCEL_BUILD = 3; - private static final int METHODID_RETRY_BUILD = 4; - private static final int METHODID_APPROVE_BUILD = 5; - private static final int METHODID_CREATE_BUILD_TRIGGER = 6; - private static final int METHODID_GET_BUILD_TRIGGER = 7; - private static final int METHODID_LIST_BUILD_TRIGGERS = 8; - private static final int METHODID_DELETE_BUILD_TRIGGER = 9; - private static final int METHODID_UPDATE_BUILD_TRIGGER = 10; - private static final int METHODID_RUN_BUILD_TRIGGER = 11; - private static final int METHODID_RECEIVE_TRIGGER_WEBHOOK = 12; - private static final int METHODID_CREATE_WORKER_POOL = 13; - private static final int METHODID_GET_WORKER_POOL = 14; - private static final int METHODID_DELETE_WORKER_POOL = 15; - private static final int METHODID_UPDATE_WORKER_POOL = 16; - private static final int METHODID_LIST_WORKER_POOLS = 17; - - private static final class MethodHandlers - implements io.grpc.stub.ServerCalls.UnaryMethod, - io.grpc.stub.ServerCalls.ServerStreamingMethod, - io.grpc.stub.ServerCalls.ClientStreamingMethod, - io.grpc.stub.ServerCalls.BidiStreamingMethod { - private final CloudBuildImplBase serviceImpl; - private final int methodId; - - MethodHandlers(CloudBuildImplBase serviceImpl, int methodId) { - this.serviceImpl = serviceImpl; - this.methodId = methodId; - } - - @java.lang.Override - @java.lang.SuppressWarnings("unchecked") - public void invoke(Req request, io.grpc.stub.StreamObserver responseObserver) { - switch (methodId) { - case METHODID_CREATE_BUILD: - serviceImpl.createBuild( - (com.google.cloudbuild.v1.CreateBuildRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); - break; - case METHODID_GET_BUILD: - serviceImpl.getBuild( - (com.google.cloudbuild.v1.GetBuildRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); - break; - case METHODID_LIST_BUILDS: - serviceImpl.listBuilds( - (com.google.cloudbuild.v1.ListBuildsRequest) request, - (io.grpc.stub.StreamObserver) - responseObserver); - break; - case METHODID_CANCEL_BUILD: - serviceImpl.cancelBuild( - (com.google.cloudbuild.v1.CancelBuildRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); - break; - case METHODID_RETRY_BUILD: - serviceImpl.retryBuild( - (com.google.cloudbuild.v1.RetryBuildRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); - break; - case METHODID_APPROVE_BUILD: - serviceImpl.approveBuild( - (com.google.cloudbuild.v1.ApproveBuildRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); - break; - case METHODID_CREATE_BUILD_TRIGGER: - serviceImpl.createBuildTrigger( - (com.google.cloudbuild.v1.CreateBuildTriggerRequest) request, - (io.grpc.stub.StreamObserver) - responseObserver); - break; - case METHODID_GET_BUILD_TRIGGER: - serviceImpl.getBuildTrigger( - (com.google.cloudbuild.v1.GetBuildTriggerRequest) request, - (io.grpc.stub.StreamObserver) - responseObserver); - break; - case METHODID_LIST_BUILD_TRIGGERS: - serviceImpl.listBuildTriggers( - (com.google.cloudbuild.v1.ListBuildTriggersRequest) request, - (io.grpc.stub.StreamObserver) - responseObserver); - break; - case METHODID_DELETE_BUILD_TRIGGER: - serviceImpl.deleteBuildTrigger( - (com.google.cloudbuild.v1.DeleteBuildTriggerRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); - break; - case METHODID_UPDATE_BUILD_TRIGGER: - serviceImpl.updateBuildTrigger( - (com.google.cloudbuild.v1.UpdateBuildTriggerRequest) request, - (io.grpc.stub.StreamObserver) - responseObserver); - break; - case METHODID_RUN_BUILD_TRIGGER: - serviceImpl.runBuildTrigger( - (com.google.cloudbuild.v1.RunBuildTriggerRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); - break; - case METHODID_RECEIVE_TRIGGER_WEBHOOK: - serviceImpl.receiveTriggerWebhook( - (com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest) request, - (io.grpc.stub.StreamObserver) - responseObserver); - break; - case METHODID_CREATE_WORKER_POOL: - serviceImpl.createWorkerPool( - (com.google.cloudbuild.v1.CreateWorkerPoolRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); - break; - case METHODID_GET_WORKER_POOL: - serviceImpl.getWorkerPool( - (com.google.cloudbuild.v1.GetWorkerPoolRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); - break; - case METHODID_DELETE_WORKER_POOL: - serviceImpl.deleteWorkerPool( - (com.google.cloudbuild.v1.DeleteWorkerPoolRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); - break; - case METHODID_UPDATE_WORKER_POOL: - serviceImpl.updateWorkerPool( - (com.google.cloudbuild.v1.UpdateWorkerPoolRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); - break; - case METHODID_LIST_WORKER_POOLS: - serviceImpl.listWorkerPools( - (com.google.cloudbuild.v1.ListWorkerPoolsRequest) request, - (io.grpc.stub.StreamObserver) - responseObserver); - break; - default: - throw new AssertionError(); - } - } - - @java.lang.Override - @java.lang.SuppressWarnings("unchecked") - public io.grpc.stub.StreamObserver invoke( - io.grpc.stub.StreamObserver responseObserver) { - switch (methodId) { - default: - throw new AssertionError(); - } - } - } - - private abstract static class CloudBuildBaseDescriptorSupplier - implements io.grpc.protobuf.ProtoFileDescriptorSupplier, - io.grpc.protobuf.ProtoServiceDescriptorSupplier { - CloudBuildBaseDescriptorSupplier() {} - - @java.lang.Override - public com.google.protobuf.Descriptors.FileDescriptor getFileDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild.getDescriptor(); - } - - @java.lang.Override - public com.google.protobuf.Descriptors.ServiceDescriptor getServiceDescriptor() { - return getFileDescriptor().findServiceByName("CloudBuild"); - } - } - - private static final class CloudBuildFileDescriptorSupplier - extends CloudBuildBaseDescriptorSupplier { - CloudBuildFileDescriptorSupplier() {} - } - - private static final class CloudBuildMethodDescriptorSupplier - extends CloudBuildBaseDescriptorSupplier - implements io.grpc.protobuf.ProtoMethodDescriptorSupplier { - private final String methodName; - - CloudBuildMethodDescriptorSupplier(String methodName) { - this.methodName = methodName; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.MethodDescriptor getMethodDescriptor() { - return getServiceDescriptor().findMethodByName(methodName); - } - } - - private static volatile io.grpc.ServiceDescriptor serviceDescriptor; - - public static io.grpc.ServiceDescriptor getServiceDescriptor() { - io.grpc.ServiceDescriptor result = serviceDescriptor; - if (result == null) { - synchronized (CloudBuildGrpc.class) { - result = serviceDescriptor; - if (result == null) { - serviceDescriptor = - result = - io.grpc.ServiceDescriptor.newBuilder(SERVICE_NAME) - .setSchemaDescriptor(new CloudBuildFileDescriptorSupplier()) - .addMethod(getCreateBuildMethod()) - .addMethod(getGetBuildMethod()) - .addMethod(getListBuildsMethod()) - .addMethod(getCancelBuildMethod()) - .addMethod(getRetryBuildMethod()) - .addMethod(getApproveBuildMethod()) - .addMethod(getCreateBuildTriggerMethod()) - .addMethod(getGetBuildTriggerMethod()) - .addMethod(getListBuildTriggersMethod()) - .addMethod(getDeleteBuildTriggerMethod()) - .addMethod(getUpdateBuildTriggerMethod()) - .addMethod(getRunBuildTriggerMethod()) - .addMethod(getReceiveTriggerWebhookMethod()) - .addMethod(getCreateWorkerPoolMethod()) - .addMethod(getGetWorkerPoolMethod()) - .addMethod(getDeleteWorkerPoolMethod()) - .addMethod(getUpdateWorkerPoolMethod()) - .addMethod(getListWorkerPoolsMethod()) - .build(); - } - } - } - return result; - } -} diff --git a/java.header b/java.header deleted file mode 100644 index d0970ba7..00000000 --- a/java.header +++ /dev/null @@ -1,15 +0,0 @@ -^/\*$ -^ \* Copyright \d\d\d\d,? Google (Inc\.|LLC)$ -^ \*$ -^ \* Licensed under the Apache License, Version 2\.0 \(the "License"\);$ -^ \* you may not use this file except in compliance with the License\.$ -^ \* You may obtain a copy of the License at$ -^ \*$ -^ \*[ ]+https?://www.apache.org/licenses/LICENSE-2\.0$ -^ \*$ -^ \* Unless required by applicable law or agreed to in writing, software$ -^ \* distributed under the License is distributed on an "AS IS" BASIS,$ -^ \* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied\.$ -^ \* See the License for the specific language governing permissions and$ -^ \* limitations under the License\.$ -^ \*/$ diff --git a/license-checks.xml b/license-checks.xml deleted file mode 100644 index 6597fced..00000000 --- a/license-checks.xml +++ /dev/null @@ -1,10 +0,0 @@ - - - - - - - - diff --git a/pom.xml b/pom.xml deleted file mode 100644 index a3455ff7..00000000 --- a/pom.xml +++ /dev/null @@ -1,188 +0,0 @@ - - - 4.0.0 - com.google.cloud - google-cloud-build-parent - pom - 3.5.7-SNAPSHOT - Google Cloud Build Parent - https://github.com/googleapis/java-cloudbuild - - Java idiomatic client for Google Cloud Platform services. - - - - com.google.cloud - google-cloud-shared-config - 1.5.3 - - - - - chingor - Jeff Ching - chingor@google.com - Google - - Developer - - - - - - Google LLC - - - scm:git:git@github.com:googleapis/java-cloudbuild.git - scm:git:git@github.com:googleapis/java-cloudbuild.git - https://github.com/googleapis/java-cloudbuild - HEAD - - - https://github.com/googleapis/java-cloudbuild/issues - GitHub Issues - - - - - Apache-2.0 - https://www.apache.org/licenses/LICENSE-2.0.txt - - - - - UTF-8 - UTF-8 - github - google-cloud-build-parent - - - - - - com.google.api.grpc - proto-google-cloud-build-v1 - 3.5.7-SNAPSHOT - - - com.google.cloud - google-cloud-build - 3.5.7-SNAPSHOT - - - com.google.api.grpc - grpc-google-cloud-build-v1 - 3.5.7-SNAPSHOT - - - - com.google.cloud - google-cloud-shared-dependencies - 3.0.4 - pom - import - - - - junit - junit - 4.13.2 - test - - - - - - - - - org.apache.maven.plugins - maven-dependency-plugin - - - org.objenesis:objenesis - javax.annotation:javax.annotation-api - - - - - - - - - google-cloud-build - grpc-google-cloud-build-v1 - proto-google-cloud-build-v1 - google-cloud-build-bom - - - - - - org.apache.maven.plugins - maven-project-info-reports-plugin - 3.4.1 - - - - index - dependency-info - team - ci-management - issue-management - licenses - scm - dependency-management - distribution-management - summary - modules - - - - - true - ${site.installationModule} - jar - - - - org.apache.maven.plugins - maven-javadoc-plugin - 3.4.1 - - - html - - aggregate - javadoc - - - - - none - protected - true - ${project.build.directory}/javadoc - - - Test helpers packages - com.google.cloud.testing - - - SPI packages - com.google.cloud.spi* - - - - - https://grpc.io/grpc-java/javadoc/ - https://developers.google.com/protocol-buffers/docs/reference/java/ - https://googleapis.dev/java/google-auth-library/latest/ - https://googleapis.dev/java/gax/latest/ - https://googleapis.github.io/api-common-java/ - - - - - - diff --git a/proto-google-cloud-build-v1/clirr-ignored-differences.xml b/proto-google-cloud-build-v1/clirr-ignored-differences.xml deleted file mode 100644 index c8cff9c1..00000000 --- a/proto-google-cloud-build-v1/clirr-ignored-differences.xml +++ /dev/null @@ -1,19 +0,0 @@ - - - - - 7012 - com/google/cloudbuild/v1/*OrBuilder - * get*(*) - - - 7012 - com/google/cloudbuild/v1/*OrBuilder - boolean contains*(*) - - - 7012 - com/google/cloudbuild/v1/*OrBuilder - boolean has*(*) - - diff --git a/proto-google-cloud-build-v1/pom.xml b/proto-google-cloud-build-v1/pom.xml deleted file mode 100644 index 81ea12f8..00000000 --- a/proto-google-cloud-build-v1/pom.xml +++ /dev/null @@ -1,42 +0,0 @@ - - 4.0.0 - com.google.api.grpc - proto-google-cloud-build-v1 - 3.5.7-SNAPSHOT - proto-google-cloud-build-v1 - PROTO library for proto-google-cloud-build-v1 - - com.google.cloud - google-cloud-build-parent - 3.5.7-SNAPSHOT - - - - com.google.protobuf - protobuf-java - - - com.google.api.grpc - proto-google-common-protos - - - com.google.guava - guava - - - com.google.api - api-common - - - - - - - org.codehaus.mojo - flatten-maven-plugin - - - - \ No newline at end of file diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ApprovalConfig.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ApprovalConfig.java deleted file mode 100644 index e5e49a93..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ApprovalConfig.java +++ /dev/null @@ -1,533 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * ApprovalConfig describes configuration for manual approval of a build.
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.ApprovalConfig} - */ -public final class ApprovalConfig extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.ApprovalConfig) - ApprovalConfigOrBuilder { - private static final long serialVersionUID = 0L; - // Use ApprovalConfig.newBuilder() to construct. - private ApprovalConfig(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private ApprovalConfig() {} - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new ApprovalConfig(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ApprovalConfig_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ApprovalConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.ApprovalConfig.class, - com.google.cloudbuild.v1.ApprovalConfig.Builder.class); - } - - public static final int APPROVAL_REQUIRED_FIELD_NUMBER = 1; - private boolean approvalRequired_; - /** - * - * - *
-   * Whether or not approval is needed. If this is set on a build, it will
-   * become pending when created, and will need to be explicitly approved
-   * to start.
-   * 
- * - * bool approval_required = 1; - * - * @return The approvalRequired. - */ - @java.lang.Override - public boolean getApprovalRequired() { - return approvalRequired_; - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (approvalRequired_ != false) { - output.writeBool(1, approvalRequired_); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (approvalRequired_ != false) { - size += com.google.protobuf.CodedOutputStream.computeBoolSize(1, approvalRequired_); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.ApprovalConfig)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.ApprovalConfig other = (com.google.cloudbuild.v1.ApprovalConfig) obj; - - if (getApprovalRequired() != other.getApprovalRequired()) return false; - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + APPROVAL_REQUIRED_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getApprovalRequired()); - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.ApprovalConfig parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.ApprovalConfig parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ApprovalConfig parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.ApprovalConfig parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ApprovalConfig parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.ApprovalConfig parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ApprovalConfig parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.ApprovalConfig parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ApprovalConfig parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.ApprovalConfig parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ApprovalConfig parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.ApprovalConfig parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.ApprovalConfig prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * ApprovalConfig describes configuration for manual approval of a build.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.ApprovalConfig} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.ApprovalConfig) - com.google.cloudbuild.v1.ApprovalConfigOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ApprovalConfig_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ApprovalConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.ApprovalConfig.class, - com.google.cloudbuild.v1.ApprovalConfig.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.ApprovalConfig.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - approvalRequired_ = false; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ApprovalConfig_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.ApprovalConfig getDefaultInstanceForType() { - return com.google.cloudbuild.v1.ApprovalConfig.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.ApprovalConfig build() { - com.google.cloudbuild.v1.ApprovalConfig result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.ApprovalConfig buildPartial() { - com.google.cloudbuild.v1.ApprovalConfig result = - new com.google.cloudbuild.v1.ApprovalConfig(this); - result.approvalRequired_ = approvalRequired_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.ApprovalConfig) { - return mergeFrom((com.google.cloudbuild.v1.ApprovalConfig) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.ApprovalConfig other) { - if (other == com.google.cloudbuild.v1.ApprovalConfig.getDefaultInstance()) return this; - if (other.getApprovalRequired() != false) { - setApprovalRequired(other.getApprovalRequired()); - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 8: - { - approvalRequired_ = input.readBool(); - - break; - } // case 8 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private boolean approvalRequired_; - /** - * - * - *
-     * Whether or not approval is needed. If this is set on a build, it will
-     * become pending when created, and will need to be explicitly approved
-     * to start.
-     * 
- * - * bool approval_required = 1; - * - * @return The approvalRequired. - */ - @java.lang.Override - public boolean getApprovalRequired() { - return approvalRequired_; - } - /** - * - * - *
-     * Whether or not approval is needed. If this is set on a build, it will
-     * become pending when created, and will need to be explicitly approved
-     * to start.
-     * 
- * - * bool approval_required = 1; - * - * @param value The approvalRequired to set. - * @return This builder for chaining. - */ - public Builder setApprovalRequired(boolean value) { - - approvalRequired_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Whether or not approval is needed. If this is set on a build, it will
-     * become pending when created, and will need to be explicitly approved
-     * to start.
-     * 
- * - * bool approval_required = 1; - * - * @return This builder for chaining. - */ - public Builder clearApprovalRequired() { - - approvalRequired_ = false; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.ApprovalConfig) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.ApprovalConfig) - private static final com.google.cloudbuild.v1.ApprovalConfig DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.ApprovalConfig(); - } - - public static com.google.cloudbuild.v1.ApprovalConfig getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public ApprovalConfig parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.ApprovalConfig getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ApprovalConfigOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ApprovalConfigOrBuilder.java deleted file mode 100644 index 583fddf3..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ApprovalConfigOrBuilder.java +++ /dev/null @@ -1,40 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface ApprovalConfigOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.ApprovalConfig) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * Whether or not approval is needed. If this is set on a build, it will
-   * become pending when created, and will need to be explicitly approved
-   * to start.
-   * 
- * - * bool approval_required = 1; - * - * @return The approvalRequired. - */ - boolean getApprovalRequired(); -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ApprovalResult.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ApprovalResult.java deleted file mode 100644 index a8789904..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ApprovalResult.java +++ /dev/null @@ -1,1615 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * ApprovalResult describes the decision and associated metadata of a manual
- * approval of a build.
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.ApprovalResult} - */ -public final class ApprovalResult extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.ApprovalResult) - ApprovalResultOrBuilder { - private static final long serialVersionUID = 0L; - // Use ApprovalResult.newBuilder() to construct. - private ApprovalResult(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private ApprovalResult() { - approverAccount_ = ""; - decision_ = 0; - comment_ = ""; - url_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new ApprovalResult(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ApprovalResult_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ApprovalResult_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.ApprovalResult.class, - com.google.cloudbuild.v1.ApprovalResult.Builder.class); - } - - /** - * - * - *
-   * Specifies whether or not this manual approval result is to approve
-   * or reject a build.
-   * 
- * - * Protobuf enum {@code google.devtools.cloudbuild.v1.ApprovalResult.Decision} - */ - public enum Decision implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
-     * Default enum type. This should not be used.
-     * 
- * - * DECISION_UNSPECIFIED = 0; - */ - DECISION_UNSPECIFIED(0), - /** - * - * - *
-     * Build is approved.
-     * 
- * - * APPROVED = 1; - */ - APPROVED(1), - /** - * - * - *
-     * Build is rejected.
-     * 
- * - * REJECTED = 2; - */ - REJECTED(2), - UNRECOGNIZED(-1), - ; - - /** - * - * - *
-     * Default enum type. This should not be used.
-     * 
- * - * DECISION_UNSPECIFIED = 0; - */ - public static final int DECISION_UNSPECIFIED_VALUE = 0; - /** - * - * - *
-     * Build is approved.
-     * 
- * - * APPROVED = 1; - */ - public static final int APPROVED_VALUE = 1; - /** - * - * - *
-     * Build is rejected.
-     * 
- * - * REJECTED = 2; - */ - public static final int REJECTED_VALUE = 2; - - public final int getNumber() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalArgumentException( - "Can't get the number of an unknown enum value."); - } - return value; - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static Decision valueOf(int value) { - return forNumber(value); - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - */ - public static Decision forNumber(int value) { - switch (value) { - case 0: - return DECISION_UNSPECIFIED; - case 1: - return APPROVED; - case 2: - return REJECTED; - default: - return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { - return internalValueMap; - } - - private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public Decision findValueByNumber(int number) { - return Decision.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalStateException( - "Can't get the descriptor of an unrecognized enum value."); - } - return getDescriptor().getValues().get(ordinal()); - } - - public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { - return getDescriptor(); - } - - public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return com.google.cloudbuild.v1.ApprovalResult.getDescriptor().getEnumTypes().get(0); - } - - private static final Decision[] VALUES = values(); - - public static Decision valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); - } - if (desc.getIndex() == -1) { - return UNRECOGNIZED; - } - return VALUES[desc.getIndex()]; - } - - private final int value; - - private Decision(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:google.devtools.cloudbuild.v1.ApprovalResult.Decision) - } - - public static final int APPROVER_ACCOUNT_FIELD_NUMBER = 2; - private volatile java.lang.Object approverAccount_; - /** - * - * - *
-   * Output only. Email of the user that called the ApproveBuild API to
-   * approve or reject a build at the time that the API was called.
-   * 
- * - * string approver_account = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The approverAccount. - */ - @java.lang.Override - public java.lang.String getApproverAccount() { - java.lang.Object ref = approverAccount_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - approverAccount_ = s; - return s; - } - } - /** - * - * - *
-   * Output only. Email of the user that called the ApproveBuild API to
-   * approve or reject a build at the time that the API was called.
-   * 
- * - * string approver_account = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The bytes for approverAccount. - */ - @java.lang.Override - public com.google.protobuf.ByteString getApproverAccountBytes() { - java.lang.Object ref = approverAccount_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - approverAccount_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int APPROVAL_TIME_FIELD_NUMBER = 3; - private com.google.protobuf.Timestamp approvalTime_; - /** - * - * - *
-   * Output only. The time when the approval decision was made.
-   * 
- * - * - * .google.protobuf.Timestamp approval_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return Whether the approvalTime field is set. - */ - @java.lang.Override - public boolean hasApprovalTime() { - return approvalTime_ != null; - } - /** - * - * - *
-   * Output only. The time when the approval decision was made.
-   * 
- * - * - * .google.protobuf.Timestamp approval_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The approvalTime. - */ - @java.lang.Override - public com.google.protobuf.Timestamp getApprovalTime() { - return approvalTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : approvalTime_; - } - /** - * - * - *
-   * Output only. The time when the approval decision was made.
-   * 
- * - * - * .google.protobuf.Timestamp approval_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - @java.lang.Override - public com.google.protobuf.TimestampOrBuilder getApprovalTimeOrBuilder() { - return getApprovalTime(); - } - - public static final int DECISION_FIELD_NUMBER = 4; - private int decision_; - /** - * - * - *
-   * Required. The decision of this manual approval.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.ApprovalResult.Decision decision = 4 [(.google.api.field_behavior) = REQUIRED]; - * - * - * @return The enum numeric value on the wire for decision. - */ - @java.lang.Override - public int getDecisionValue() { - return decision_; - } - /** - * - * - *
-   * Required. The decision of this manual approval.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.ApprovalResult.Decision decision = 4 [(.google.api.field_behavior) = REQUIRED]; - * - * - * @return The decision. - */ - @java.lang.Override - public com.google.cloudbuild.v1.ApprovalResult.Decision getDecision() { - @SuppressWarnings("deprecation") - com.google.cloudbuild.v1.ApprovalResult.Decision result = - com.google.cloudbuild.v1.ApprovalResult.Decision.valueOf(decision_); - return result == null ? com.google.cloudbuild.v1.ApprovalResult.Decision.UNRECOGNIZED : result; - } - - public static final int COMMENT_FIELD_NUMBER = 5; - private volatile java.lang.Object comment_; - /** - * - * - *
-   * Optional. An optional comment for this manual approval result.
-   * 
- * - * string comment = 5 [(.google.api.field_behavior) = OPTIONAL]; - * - * @return The comment. - */ - @java.lang.Override - public java.lang.String getComment() { - java.lang.Object ref = comment_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - comment_ = s; - return s; - } - } - /** - * - * - *
-   * Optional. An optional comment for this manual approval result.
-   * 
- * - * string comment = 5 [(.google.api.field_behavior) = OPTIONAL]; - * - * @return The bytes for comment. - */ - @java.lang.Override - public com.google.protobuf.ByteString getCommentBytes() { - java.lang.Object ref = comment_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - comment_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int URL_FIELD_NUMBER = 6; - private volatile java.lang.Object url_; - /** - * - * - *
-   * Optional. An optional URL tied to this manual approval result. This field
-   * is essentially the same as comment, except that it will be rendered by the
-   * UI differently. An example use case is a link to an external job that
-   * approved this Build.
-   * 
- * - * string url = 6 [(.google.api.field_behavior) = OPTIONAL]; - * - * @return The url. - */ - @java.lang.Override - public java.lang.String getUrl() { - java.lang.Object ref = url_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - url_ = s; - return s; - } - } - /** - * - * - *
-   * Optional. An optional URL tied to this manual approval result. This field
-   * is essentially the same as comment, except that it will be rendered by the
-   * UI differently. An example use case is a link to an external job that
-   * approved this Build.
-   * 
- * - * string url = 6 [(.google.api.field_behavior) = OPTIONAL]; - * - * @return The bytes for url. - */ - @java.lang.Override - public com.google.protobuf.ByteString getUrlBytes() { - java.lang.Object ref = url_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - url_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(approverAccount_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, approverAccount_); - } - if (approvalTime_ != null) { - output.writeMessage(3, getApprovalTime()); - } - if (decision_ - != com.google.cloudbuild.v1.ApprovalResult.Decision.DECISION_UNSPECIFIED.getNumber()) { - output.writeEnum(4, decision_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(comment_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 5, comment_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(url_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 6, url_); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(approverAccount_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, approverAccount_); - } - if (approvalTime_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getApprovalTime()); - } - if (decision_ - != com.google.cloudbuild.v1.ApprovalResult.Decision.DECISION_UNSPECIFIED.getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(4, decision_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(comment_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(5, comment_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(url_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(6, url_); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.ApprovalResult)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.ApprovalResult other = (com.google.cloudbuild.v1.ApprovalResult) obj; - - if (!getApproverAccount().equals(other.getApproverAccount())) return false; - if (hasApprovalTime() != other.hasApprovalTime()) return false; - if (hasApprovalTime()) { - if (!getApprovalTime().equals(other.getApprovalTime())) return false; - } - if (decision_ != other.decision_) return false; - if (!getComment().equals(other.getComment())) return false; - if (!getUrl().equals(other.getUrl())) return false; - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + APPROVER_ACCOUNT_FIELD_NUMBER; - hash = (53 * hash) + getApproverAccount().hashCode(); - if (hasApprovalTime()) { - hash = (37 * hash) + APPROVAL_TIME_FIELD_NUMBER; - hash = (53 * hash) + getApprovalTime().hashCode(); - } - hash = (37 * hash) + DECISION_FIELD_NUMBER; - hash = (53 * hash) + decision_; - hash = (37 * hash) + COMMENT_FIELD_NUMBER; - hash = (53 * hash) + getComment().hashCode(); - hash = (37 * hash) + URL_FIELD_NUMBER; - hash = (53 * hash) + getUrl().hashCode(); - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.ApprovalResult parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.ApprovalResult parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ApprovalResult parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.ApprovalResult parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ApprovalResult parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.ApprovalResult parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ApprovalResult parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.ApprovalResult parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ApprovalResult parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.ApprovalResult parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ApprovalResult parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.ApprovalResult parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.ApprovalResult prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * ApprovalResult describes the decision and associated metadata of a manual
-   * approval of a build.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.ApprovalResult} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.ApprovalResult) - com.google.cloudbuild.v1.ApprovalResultOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ApprovalResult_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ApprovalResult_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.ApprovalResult.class, - com.google.cloudbuild.v1.ApprovalResult.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.ApprovalResult.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - approverAccount_ = ""; - - if (approvalTimeBuilder_ == null) { - approvalTime_ = null; - } else { - approvalTime_ = null; - approvalTimeBuilder_ = null; - } - decision_ = 0; - - comment_ = ""; - - url_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ApprovalResult_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.ApprovalResult getDefaultInstanceForType() { - return com.google.cloudbuild.v1.ApprovalResult.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.ApprovalResult build() { - com.google.cloudbuild.v1.ApprovalResult result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.ApprovalResult buildPartial() { - com.google.cloudbuild.v1.ApprovalResult result = - new com.google.cloudbuild.v1.ApprovalResult(this); - result.approverAccount_ = approverAccount_; - if (approvalTimeBuilder_ == null) { - result.approvalTime_ = approvalTime_; - } else { - result.approvalTime_ = approvalTimeBuilder_.build(); - } - result.decision_ = decision_; - result.comment_ = comment_; - result.url_ = url_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.ApprovalResult) { - return mergeFrom((com.google.cloudbuild.v1.ApprovalResult) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.ApprovalResult other) { - if (other == com.google.cloudbuild.v1.ApprovalResult.getDefaultInstance()) return this; - if (!other.getApproverAccount().isEmpty()) { - approverAccount_ = other.approverAccount_; - onChanged(); - } - if (other.hasApprovalTime()) { - mergeApprovalTime(other.getApprovalTime()); - } - if (other.decision_ != 0) { - setDecisionValue(other.getDecisionValue()); - } - if (!other.getComment().isEmpty()) { - comment_ = other.comment_; - onChanged(); - } - if (!other.getUrl().isEmpty()) { - url_ = other.url_; - onChanged(); - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 18: - { - approverAccount_ = input.readStringRequireUtf8(); - - break; - } // case 18 - case 26: - { - input.readMessage(getApprovalTimeFieldBuilder().getBuilder(), extensionRegistry); - - break; - } // case 26 - case 32: - { - decision_ = input.readEnum(); - - break; - } // case 32 - case 42: - { - comment_ = input.readStringRequireUtf8(); - - break; - } // case 42 - case 50: - { - url_ = input.readStringRequireUtf8(); - - break; - } // case 50 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private java.lang.Object approverAccount_ = ""; - /** - * - * - *
-     * Output only. Email of the user that called the ApproveBuild API to
-     * approve or reject a build at the time that the API was called.
-     * 
- * - * string approver_account = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The approverAccount. - */ - public java.lang.String getApproverAccount() { - java.lang.Object ref = approverAccount_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - approverAccount_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Output only. Email of the user that called the ApproveBuild API to
-     * approve or reject a build at the time that the API was called.
-     * 
- * - * string approver_account = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The bytes for approverAccount. - */ - public com.google.protobuf.ByteString getApproverAccountBytes() { - java.lang.Object ref = approverAccount_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - approverAccount_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Output only. Email of the user that called the ApproveBuild API to
-     * approve or reject a build at the time that the API was called.
-     * 
- * - * string approver_account = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @param value The approverAccount to set. - * @return This builder for chaining. - */ - public Builder setApproverAccount(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - approverAccount_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. Email of the user that called the ApproveBuild API to
-     * approve or reject a build at the time that the API was called.
-     * 
- * - * string approver_account = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return This builder for chaining. - */ - public Builder clearApproverAccount() { - - approverAccount_ = getDefaultInstance().getApproverAccount(); - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. Email of the user that called the ApproveBuild API to
-     * approve or reject a build at the time that the API was called.
-     * 
- * - * string approver_account = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @param value The bytes for approverAccount to set. - * @return This builder for chaining. - */ - public Builder setApproverAccountBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - approverAccount_ = value; - onChanged(); - return this; - } - - private com.google.protobuf.Timestamp approvalTime_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - approvalTimeBuilder_; - /** - * - * - *
-     * Output only. The time when the approval decision was made.
-     * 
- * - * - * .google.protobuf.Timestamp approval_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return Whether the approvalTime field is set. - */ - public boolean hasApprovalTime() { - return approvalTimeBuilder_ != null || approvalTime_ != null; - } - /** - * - * - *
-     * Output only. The time when the approval decision was made.
-     * 
- * - * - * .google.protobuf.Timestamp approval_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The approvalTime. - */ - public com.google.protobuf.Timestamp getApprovalTime() { - if (approvalTimeBuilder_ == null) { - return approvalTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : approvalTime_; - } else { - return approvalTimeBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Output only. The time when the approval decision was made.
-     * 
- * - * - * .google.protobuf.Timestamp approval_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder setApprovalTime(com.google.protobuf.Timestamp value) { - if (approvalTimeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - approvalTime_ = value; - onChanged(); - } else { - approvalTimeBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * Output only. The time when the approval decision was made.
-     * 
- * - * - * .google.protobuf.Timestamp approval_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder setApprovalTime(com.google.protobuf.Timestamp.Builder builderForValue) { - if (approvalTimeBuilder_ == null) { - approvalTime_ = builderForValue.build(); - onChanged(); - } else { - approvalTimeBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Output only. The time when the approval decision was made.
-     * 
- * - * - * .google.protobuf.Timestamp approval_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder mergeApprovalTime(com.google.protobuf.Timestamp value) { - if (approvalTimeBuilder_ == null) { - if (approvalTime_ != null) { - approvalTime_ = - com.google.protobuf.Timestamp.newBuilder(approvalTime_) - .mergeFrom(value) - .buildPartial(); - } else { - approvalTime_ = value; - } - onChanged(); - } else { - approvalTimeBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * Output only. The time when the approval decision was made.
-     * 
- * - * - * .google.protobuf.Timestamp approval_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder clearApprovalTime() { - if (approvalTimeBuilder_ == null) { - approvalTime_ = null; - onChanged(); - } else { - approvalTime_ = null; - approvalTimeBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Output only. The time when the approval decision was made.
-     * 
- * - * - * .google.protobuf.Timestamp approval_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public com.google.protobuf.Timestamp.Builder getApprovalTimeBuilder() { - - onChanged(); - return getApprovalTimeFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Output only. The time when the approval decision was made.
-     * 
- * - * - * .google.protobuf.Timestamp approval_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public com.google.protobuf.TimestampOrBuilder getApprovalTimeOrBuilder() { - if (approvalTimeBuilder_ != null) { - return approvalTimeBuilder_.getMessageOrBuilder(); - } else { - return approvalTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : approvalTime_; - } - } - /** - * - * - *
-     * Output only. The time when the approval decision was made.
-     * 
- * - * - * .google.protobuf.Timestamp approval_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - getApprovalTimeFieldBuilder() { - if (approvalTimeBuilder_ == null) { - approvalTimeBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder>( - getApprovalTime(), getParentForChildren(), isClean()); - approvalTime_ = null; - } - return approvalTimeBuilder_; - } - - private int decision_ = 0; - /** - * - * - *
-     * Required. The decision of this manual approval.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.ApprovalResult.Decision decision = 4 [(.google.api.field_behavior) = REQUIRED]; - * - * - * @return The enum numeric value on the wire for decision. - */ - @java.lang.Override - public int getDecisionValue() { - return decision_; - } - /** - * - * - *
-     * Required. The decision of this manual approval.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.ApprovalResult.Decision decision = 4 [(.google.api.field_behavior) = REQUIRED]; - * - * - * @param value The enum numeric value on the wire for decision to set. - * @return This builder for chaining. - */ - public Builder setDecisionValue(int value) { - - decision_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Required. The decision of this manual approval.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.ApprovalResult.Decision decision = 4 [(.google.api.field_behavior) = REQUIRED]; - * - * - * @return The decision. - */ - @java.lang.Override - public com.google.cloudbuild.v1.ApprovalResult.Decision getDecision() { - @SuppressWarnings("deprecation") - com.google.cloudbuild.v1.ApprovalResult.Decision result = - com.google.cloudbuild.v1.ApprovalResult.Decision.valueOf(decision_); - return result == null - ? com.google.cloudbuild.v1.ApprovalResult.Decision.UNRECOGNIZED - : result; - } - /** - * - * - *
-     * Required. The decision of this manual approval.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.ApprovalResult.Decision decision = 4 [(.google.api.field_behavior) = REQUIRED]; - * - * - * @param value The decision to set. - * @return This builder for chaining. - */ - public Builder setDecision(com.google.cloudbuild.v1.ApprovalResult.Decision value) { - if (value == null) { - throw new NullPointerException(); - } - - decision_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-     * Required. The decision of this manual approval.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.ApprovalResult.Decision decision = 4 [(.google.api.field_behavior) = REQUIRED]; - * - * - * @return This builder for chaining. - */ - public Builder clearDecision() { - - decision_ = 0; - onChanged(); - return this; - } - - private java.lang.Object comment_ = ""; - /** - * - * - *
-     * Optional. An optional comment for this manual approval result.
-     * 
- * - * string comment = 5 [(.google.api.field_behavior) = OPTIONAL]; - * - * @return The comment. - */ - public java.lang.String getComment() { - java.lang.Object ref = comment_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - comment_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Optional. An optional comment for this manual approval result.
-     * 
- * - * string comment = 5 [(.google.api.field_behavior) = OPTIONAL]; - * - * @return The bytes for comment. - */ - public com.google.protobuf.ByteString getCommentBytes() { - java.lang.Object ref = comment_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - comment_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Optional. An optional comment for this manual approval result.
-     * 
- * - * string comment = 5 [(.google.api.field_behavior) = OPTIONAL]; - * - * @param value The comment to set. - * @return This builder for chaining. - */ - public Builder setComment(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - comment_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Optional. An optional comment for this manual approval result.
-     * 
- * - * string comment = 5 [(.google.api.field_behavior) = OPTIONAL]; - * - * @return This builder for chaining. - */ - public Builder clearComment() { - - comment_ = getDefaultInstance().getComment(); - onChanged(); - return this; - } - /** - * - * - *
-     * Optional. An optional comment for this manual approval result.
-     * 
- * - * string comment = 5 [(.google.api.field_behavior) = OPTIONAL]; - * - * @param value The bytes for comment to set. - * @return This builder for chaining. - */ - public Builder setCommentBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - comment_ = value; - onChanged(); - return this; - } - - private java.lang.Object url_ = ""; - /** - * - * - *
-     * Optional. An optional URL tied to this manual approval result. This field
-     * is essentially the same as comment, except that it will be rendered by the
-     * UI differently. An example use case is a link to an external job that
-     * approved this Build.
-     * 
- * - * string url = 6 [(.google.api.field_behavior) = OPTIONAL]; - * - * @return The url. - */ - public java.lang.String getUrl() { - java.lang.Object ref = url_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - url_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Optional. An optional URL tied to this manual approval result. This field
-     * is essentially the same as comment, except that it will be rendered by the
-     * UI differently. An example use case is a link to an external job that
-     * approved this Build.
-     * 
- * - * string url = 6 [(.google.api.field_behavior) = OPTIONAL]; - * - * @return The bytes for url. - */ - public com.google.protobuf.ByteString getUrlBytes() { - java.lang.Object ref = url_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - url_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Optional. An optional URL tied to this manual approval result. This field
-     * is essentially the same as comment, except that it will be rendered by the
-     * UI differently. An example use case is a link to an external job that
-     * approved this Build.
-     * 
- * - * string url = 6 [(.google.api.field_behavior) = OPTIONAL]; - * - * @param value The url to set. - * @return This builder for chaining. - */ - public Builder setUrl(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - url_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Optional. An optional URL tied to this manual approval result. This field
-     * is essentially the same as comment, except that it will be rendered by the
-     * UI differently. An example use case is a link to an external job that
-     * approved this Build.
-     * 
- * - * string url = 6 [(.google.api.field_behavior) = OPTIONAL]; - * - * @return This builder for chaining. - */ - public Builder clearUrl() { - - url_ = getDefaultInstance().getUrl(); - onChanged(); - return this; - } - /** - * - * - *
-     * Optional. An optional URL tied to this manual approval result. This field
-     * is essentially the same as comment, except that it will be rendered by the
-     * UI differently. An example use case is a link to an external job that
-     * approved this Build.
-     * 
- * - * string url = 6 [(.google.api.field_behavior) = OPTIONAL]; - * - * @param value The bytes for url to set. - * @return This builder for chaining. - */ - public Builder setUrlBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - url_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.ApprovalResult) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.ApprovalResult) - private static final com.google.cloudbuild.v1.ApprovalResult DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.ApprovalResult(); - } - - public static com.google.cloudbuild.v1.ApprovalResult getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public ApprovalResult parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.ApprovalResult getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ApprovalResultOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ApprovalResultOrBuilder.java deleted file mode 100644 index 0a936d8a..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ApprovalResultOrBuilder.java +++ /dev/null @@ -1,178 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface ApprovalResultOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.ApprovalResult) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * Output only. Email of the user that called the ApproveBuild API to
-   * approve or reject a build at the time that the API was called.
-   * 
- * - * string approver_account = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The approverAccount. - */ - java.lang.String getApproverAccount(); - /** - * - * - *
-   * Output only. Email of the user that called the ApproveBuild API to
-   * approve or reject a build at the time that the API was called.
-   * 
- * - * string approver_account = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The bytes for approverAccount. - */ - com.google.protobuf.ByteString getApproverAccountBytes(); - - /** - * - * - *
-   * Output only. The time when the approval decision was made.
-   * 
- * - * - * .google.protobuf.Timestamp approval_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return Whether the approvalTime field is set. - */ - boolean hasApprovalTime(); - /** - * - * - *
-   * Output only. The time when the approval decision was made.
-   * 
- * - * - * .google.protobuf.Timestamp approval_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The approvalTime. - */ - com.google.protobuf.Timestamp getApprovalTime(); - /** - * - * - *
-   * Output only. The time when the approval decision was made.
-   * 
- * - * - * .google.protobuf.Timestamp approval_time = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - com.google.protobuf.TimestampOrBuilder getApprovalTimeOrBuilder(); - - /** - * - * - *
-   * Required. The decision of this manual approval.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.ApprovalResult.Decision decision = 4 [(.google.api.field_behavior) = REQUIRED]; - * - * - * @return The enum numeric value on the wire for decision. - */ - int getDecisionValue(); - /** - * - * - *
-   * Required. The decision of this manual approval.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.ApprovalResult.Decision decision = 4 [(.google.api.field_behavior) = REQUIRED]; - * - * - * @return The decision. - */ - com.google.cloudbuild.v1.ApprovalResult.Decision getDecision(); - - /** - * - * - *
-   * Optional. An optional comment for this manual approval result.
-   * 
- * - * string comment = 5 [(.google.api.field_behavior) = OPTIONAL]; - * - * @return The comment. - */ - java.lang.String getComment(); - /** - * - * - *
-   * Optional. An optional comment for this manual approval result.
-   * 
- * - * string comment = 5 [(.google.api.field_behavior) = OPTIONAL]; - * - * @return The bytes for comment. - */ - com.google.protobuf.ByteString getCommentBytes(); - - /** - * - * - *
-   * Optional. An optional URL tied to this manual approval result. This field
-   * is essentially the same as comment, except that it will be rendered by the
-   * UI differently. An example use case is a link to an external job that
-   * approved this Build.
-   * 
- * - * string url = 6 [(.google.api.field_behavior) = OPTIONAL]; - * - * @return The url. - */ - java.lang.String getUrl(); - /** - * - * - *
-   * Optional. An optional URL tied to this manual approval result. This field
-   * is essentially the same as comment, except that it will be rendered by the
-   * UI differently. An example use case is a link to an external job that
-   * approved this Build.
-   * 
- * - * string url = 6 [(.google.api.field_behavior) = OPTIONAL]; - * - * @return The bytes for url. - */ - com.google.protobuf.ByteString getUrlBytes(); -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ApproveBuildRequest.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ApproveBuildRequest.java deleted file mode 100644 index 1bca640e..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ApproveBuildRequest.java +++ /dev/null @@ -1,889 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * Request to approve or reject a pending build.
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.ApproveBuildRequest} - */ -public final class ApproveBuildRequest extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.ApproveBuildRequest) - ApproveBuildRequestOrBuilder { - private static final long serialVersionUID = 0L; - // Use ApproveBuildRequest.newBuilder() to construct. - private ApproveBuildRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private ApproveBuildRequest() { - name_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new ApproveBuildRequest(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ApproveBuildRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ApproveBuildRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.ApproveBuildRequest.class, - com.google.cloudbuild.v1.ApproveBuildRequest.Builder.class); - } - - public static final int NAME_FIELD_NUMBER = 1; - private volatile java.lang.Object name_; - /** - * - * - *
-   * Required. Name of the target build.
-   * For example: "projects/{$project_id}/builds/{$build_id}"
-   * 
- * - * string name = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The name. - */ - @java.lang.Override - public java.lang.String getName() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - name_ = s; - return s; - } - } - /** - * - * - *
-   * Required. Name of the target build.
-   * For example: "projects/{$project_id}/builds/{$build_id}"
-   * 
- * - * string name = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for name. - */ - @java.lang.Override - public com.google.protobuf.ByteString getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int APPROVAL_RESULT_FIELD_NUMBER = 2; - private com.google.cloudbuild.v1.ApprovalResult approvalResult_; - /** - * - * - *
-   * Approval decision and metadata.
-   * 
- * - * .google.devtools.cloudbuild.v1.ApprovalResult approval_result = 2; - * - * @return Whether the approvalResult field is set. - */ - @java.lang.Override - public boolean hasApprovalResult() { - return approvalResult_ != null; - } - /** - * - * - *
-   * Approval decision and metadata.
-   * 
- * - * .google.devtools.cloudbuild.v1.ApprovalResult approval_result = 2; - * - * @return The approvalResult. - */ - @java.lang.Override - public com.google.cloudbuild.v1.ApprovalResult getApprovalResult() { - return approvalResult_ == null - ? com.google.cloudbuild.v1.ApprovalResult.getDefaultInstance() - : approvalResult_; - } - /** - * - * - *
-   * Approval decision and metadata.
-   * 
- * - * .google.devtools.cloudbuild.v1.ApprovalResult approval_result = 2; - */ - @java.lang.Override - public com.google.cloudbuild.v1.ApprovalResultOrBuilder getApprovalResultOrBuilder() { - return getApprovalResult(); - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); - } - if (approvalResult_ != null) { - output.writeMessage(2, getApprovalResult()); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); - } - if (approvalResult_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getApprovalResult()); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.ApproveBuildRequest)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.ApproveBuildRequest other = - (com.google.cloudbuild.v1.ApproveBuildRequest) obj; - - if (!getName().equals(other.getName())) return false; - if (hasApprovalResult() != other.hasApprovalResult()) return false; - if (hasApprovalResult()) { - if (!getApprovalResult().equals(other.getApprovalResult())) return false; - } - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + NAME_FIELD_NUMBER; - hash = (53 * hash) + getName().hashCode(); - if (hasApprovalResult()) { - hash = (37 * hash) + APPROVAL_RESULT_FIELD_NUMBER; - hash = (53 * hash) + getApprovalResult().hashCode(); - } - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.ApproveBuildRequest parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.ApproveBuildRequest parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ApproveBuildRequest parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.ApproveBuildRequest parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ApproveBuildRequest parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.ApproveBuildRequest parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ApproveBuildRequest parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.ApproveBuildRequest parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ApproveBuildRequest parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.ApproveBuildRequest parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ApproveBuildRequest parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.ApproveBuildRequest parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.ApproveBuildRequest prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * Request to approve or reject a pending build.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.ApproveBuildRequest} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.ApproveBuildRequest) - com.google.cloudbuild.v1.ApproveBuildRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ApproveBuildRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ApproveBuildRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.ApproveBuildRequest.class, - com.google.cloudbuild.v1.ApproveBuildRequest.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.ApproveBuildRequest.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - name_ = ""; - - if (approvalResultBuilder_ == null) { - approvalResult_ = null; - } else { - approvalResult_ = null; - approvalResultBuilder_ = null; - } - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ApproveBuildRequest_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.ApproveBuildRequest getDefaultInstanceForType() { - return com.google.cloudbuild.v1.ApproveBuildRequest.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.ApproveBuildRequest build() { - com.google.cloudbuild.v1.ApproveBuildRequest result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.ApproveBuildRequest buildPartial() { - com.google.cloudbuild.v1.ApproveBuildRequest result = - new com.google.cloudbuild.v1.ApproveBuildRequest(this); - result.name_ = name_; - if (approvalResultBuilder_ == null) { - result.approvalResult_ = approvalResult_; - } else { - result.approvalResult_ = approvalResultBuilder_.build(); - } - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.ApproveBuildRequest) { - return mergeFrom((com.google.cloudbuild.v1.ApproveBuildRequest) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.ApproveBuildRequest other) { - if (other == com.google.cloudbuild.v1.ApproveBuildRequest.getDefaultInstance()) return this; - if (!other.getName().isEmpty()) { - name_ = other.name_; - onChanged(); - } - if (other.hasApprovalResult()) { - mergeApprovalResult(other.getApprovalResult()); - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - name_ = input.readStringRequireUtf8(); - - break; - } // case 10 - case 18: - { - input.readMessage(getApprovalResultFieldBuilder().getBuilder(), extensionRegistry); - - break; - } // case 18 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private java.lang.Object name_ = ""; - /** - * - * - *
-     * Required. Name of the target build.
-     * For example: "projects/{$project_id}/builds/{$build_id}"
-     * 
- * - * string name = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The name. - */ - public java.lang.String getName() { - java.lang.Object ref = name_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - name_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Required. Name of the target build.
-     * For example: "projects/{$project_id}/builds/{$build_id}"
-     * 
- * - * string name = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for name. - */ - public com.google.protobuf.ByteString getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Required. Name of the target build.
-     * For example: "projects/{$project_id}/builds/{$build_id}"
-     * 
- * - * string name = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @param value The name to set. - * @return This builder for chaining. - */ - public Builder setName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - name_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Required. Name of the target build.
-     * For example: "projects/{$project_id}/builds/{$build_id}"
-     * 
- * - * string name = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return This builder for chaining. - */ - public Builder clearName() { - - name_ = getDefaultInstance().getName(); - onChanged(); - return this; - } - /** - * - * - *
-     * Required. Name of the target build.
-     * For example: "projects/{$project_id}/builds/{$build_id}"
-     * 
- * - * string name = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @param value The bytes for name to set. - * @return This builder for chaining. - */ - public Builder setNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - name_ = value; - onChanged(); - return this; - } - - private com.google.cloudbuild.v1.ApprovalResult approvalResult_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.ApprovalResult, - com.google.cloudbuild.v1.ApprovalResult.Builder, - com.google.cloudbuild.v1.ApprovalResultOrBuilder> - approvalResultBuilder_; - /** - * - * - *
-     * Approval decision and metadata.
-     * 
- * - * .google.devtools.cloudbuild.v1.ApprovalResult approval_result = 2; - * - * @return Whether the approvalResult field is set. - */ - public boolean hasApprovalResult() { - return approvalResultBuilder_ != null || approvalResult_ != null; - } - /** - * - * - *
-     * Approval decision and metadata.
-     * 
- * - * .google.devtools.cloudbuild.v1.ApprovalResult approval_result = 2; - * - * @return The approvalResult. - */ - public com.google.cloudbuild.v1.ApprovalResult getApprovalResult() { - if (approvalResultBuilder_ == null) { - return approvalResult_ == null - ? com.google.cloudbuild.v1.ApprovalResult.getDefaultInstance() - : approvalResult_; - } else { - return approvalResultBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Approval decision and metadata.
-     * 
- * - * .google.devtools.cloudbuild.v1.ApprovalResult approval_result = 2; - */ - public Builder setApprovalResult(com.google.cloudbuild.v1.ApprovalResult value) { - if (approvalResultBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - approvalResult_ = value; - onChanged(); - } else { - approvalResultBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * Approval decision and metadata.
-     * 
- * - * .google.devtools.cloudbuild.v1.ApprovalResult approval_result = 2; - */ - public Builder setApprovalResult( - com.google.cloudbuild.v1.ApprovalResult.Builder builderForValue) { - if (approvalResultBuilder_ == null) { - approvalResult_ = builderForValue.build(); - onChanged(); - } else { - approvalResultBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Approval decision and metadata.
-     * 
- * - * .google.devtools.cloudbuild.v1.ApprovalResult approval_result = 2; - */ - public Builder mergeApprovalResult(com.google.cloudbuild.v1.ApprovalResult value) { - if (approvalResultBuilder_ == null) { - if (approvalResult_ != null) { - approvalResult_ = - com.google.cloudbuild.v1.ApprovalResult.newBuilder(approvalResult_) - .mergeFrom(value) - .buildPartial(); - } else { - approvalResult_ = value; - } - onChanged(); - } else { - approvalResultBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * Approval decision and metadata.
-     * 
- * - * .google.devtools.cloudbuild.v1.ApprovalResult approval_result = 2; - */ - public Builder clearApprovalResult() { - if (approvalResultBuilder_ == null) { - approvalResult_ = null; - onChanged(); - } else { - approvalResult_ = null; - approvalResultBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Approval decision and metadata.
-     * 
- * - * .google.devtools.cloudbuild.v1.ApprovalResult approval_result = 2; - */ - public com.google.cloudbuild.v1.ApprovalResult.Builder getApprovalResultBuilder() { - - onChanged(); - return getApprovalResultFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Approval decision and metadata.
-     * 
- * - * .google.devtools.cloudbuild.v1.ApprovalResult approval_result = 2; - */ - public com.google.cloudbuild.v1.ApprovalResultOrBuilder getApprovalResultOrBuilder() { - if (approvalResultBuilder_ != null) { - return approvalResultBuilder_.getMessageOrBuilder(); - } else { - return approvalResult_ == null - ? com.google.cloudbuild.v1.ApprovalResult.getDefaultInstance() - : approvalResult_; - } - } - /** - * - * - *
-     * Approval decision and metadata.
-     * 
- * - * .google.devtools.cloudbuild.v1.ApprovalResult approval_result = 2; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.ApprovalResult, - com.google.cloudbuild.v1.ApprovalResult.Builder, - com.google.cloudbuild.v1.ApprovalResultOrBuilder> - getApprovalResultFieldBuilder() { - if (approvalResultBuilder_ == null) { - approvalResultBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.ApprovalResult, - com.google.cloudbuild.v1.ApprovalResult.Builder, - com.google.cloudbuild.v1.ApprovalResultOrBuilder>( - getApprovalResult(), getParentForChildren(), isClean()); - approvalResult_ = null; - } - return approvalResultBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.ApproveBuildRequest) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.ApproveBuildRequest) - private static final com.google.cloudbuild.v1.ApproveBuildRequest DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.ApproveBuildRequest(); - } - - public static com.google.cloudbuild.v1.ApproveBuildRequest getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public ApproveBuildRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.ApproveBuildRequest getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ApproveBuildRequestOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ApproveBuildRequestOrBuilder.java deleted file mode 100644 index 7aa05486..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ApproveBuildRequestOrBuilder.java +++ /dev/null @@ -1,87 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface ApproveBuildRequestOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.ApproveBuildRequest) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * Required. Name of the target build.
-   * For example: "projects/{$project_id}/builds/{$build_id}"
-   * 
- * - * string name = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The name. - */ - java.lang.String getName(); - /** - * - * - *
-   * Required. Name of the target build.
-   * For example: "projects/{$project_id}/builds/{$build_id}"
-   * 
- * - * string name = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for name. - */ - com.google.protobuf.ByteString getNameBytes(); - - /** - * - * - *
-   * Approval decision and metadata.
-   * 
- * - * .google.devtools.cloudbuild.v1.ApprovalResult approval_result = 2; - * - * @return Whether the approvalResult field is set. - */ - boolean hasApprovalResult(); - /** - * - * - *
-   * Approval decision and metadata.
-   * 
- * - * .google.devtools.cloudbuild.v1.ApprovalResult approval_result = 2; - * - * @return The approvalResult. - */ - com.google.cloudbuild.v1.ApprovalResult getApprovalResult(); - /** - * - * - *
-   * Approval decision and metadata.
-   * 
- * - * .google.devtools.cloudbuild.v1.ApprovalResult approval_result = 2; - */ - com.google.cloudbuild.v1.ApprovalResultOrBuilder getApprovalResultOrBuilder(); -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ArtifactResult.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ArtifactResult.java deleted file mode 100644 index 09cfdf56..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ArtifactResult.java +++ /dev/null @@ -1,1117 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * An artifact that was uploaded during a build. This
- * is a single record in the artifact manifest JSON file.
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.ArtifactResult} - */ -public final class ArtifactResult extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.ArtifactResult) - ArtifactResultOrBuilder { - private static final long serialVersionUID = 0L; - // Use ArtifactResult.newBuilder() to construct. - private ArtifactResult(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private ArtifactResult() { - location_ = ""; - fileHash_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new ArtifactResult(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ArtifactResult_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ArtifactResult_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.ArtifactResult.class, - com.google.cloudbuild.v1.ArtifactResult.Builder.class); - } - - public static final int LOCATION_FIELD_NUMBER = 1; - private volatile java.lang.Object location_; - /** - * - * - *
-   * The path of an artifact in a Google Cloud Storage bucket, with the
-   * generation number. For example,
-   * `gs://mybucket/path/to/output.jar#generation`.
-   * 
- * - * string location = 1; - * - * @return The location. - */ - @java.lang.Override - public java.lang.String getLocation() { - java.lang.Object ref = location_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - location_ = s; - return s; - } - } - /** - * - * - *
-   * The path of an artifact in a Google Cloud Storage bucket, with the
-   * generation number. For example,
-   * `gs://mybucket/path/to/output.jar#generation`.
-   * 
- * - * string location = 1; - * - * @return The bytes for location. - */ - @java.lang.Override - public com.google.protobuf.ByteString getLocationBytes() { - java.lang.Object ref = location_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - location_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int FILE_HASH_FIELD_NUMBER = 2; - private java.util.List fileHash_; - /** - * - * - *
-   * The file hash of the artifact.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.FileHashes file_hash = 2; - */ - @java.lang.Override - public java.util.List getFileHashList() { - return fileHash_; - } - /** - * - * - *
-   * The file hash of the artifact.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.FileHashes file_hash = 2; - */ - @java.lang.Override - public java.util.List - getFileHashOrBuilderList() { - return fileHash_; - } - /** - * - * - *
-   * The file hash of the artifact.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.FileHashes file_hash = 2; - */ - @java.lang.Override - public int getFileHashCount() { - return fileHash_.size(); - } - /** - * - * - *
-   * The file hash of the artifact.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.FileHashes file_hash = 2; - */ - @java.lang.Override - public com.google.cloudbuild.v1.FileHashes getFileHash(int index) { - return fileHash_.get(index); - } - /** - * - * - *
-   * The file hash of the artifact.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.FileHashes file_hash = 2; - */ - @java.lang.Override - public com.google.cloudbuild.v1.FileHashesOrBuilder getFileHashOrBuilder(int index) { - return fileHash_.get(index); - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(location_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, location_); - } - for (int i = 0; i < fileHash_.size(); i++) { - output.writeMessage(2, fileHash_.get(i)); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(location_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, location_); - } - for (int i = 0; i < fileHash_.size(); i++) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, fileHash_.get(i)); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.ArtifactResult)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.ArtifactResult other = (com.google.cloudbuild.v1.ArtifactResult) obj; - - if (!getLocation().equals(other.getLocation())) return false; - if (!getFileHashList().equals(other.getFileHashList())) return false; - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + LOCATION_FIELD_NUMBER; - hash = (53 * hash) + getLocation().hashCode(); - if (getFileHashCount() > 0) { - hash = (37 * hash) + FILE_HASH_FIELD_NUMBER; - hash = (53 * hash) + getFileHashList().hashCode(); - } - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.ArtifactResult parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.ArtifactResult parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ArtifactResult parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.ArtifactResult parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ArtifactResult parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.ArtifactResult parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ArtifactResult parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.ArtifactResult parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ArtifactResult parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.ArtifactResult parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ArtifactResult parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.ArtifactResult parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.ArtifactResult prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * An artifact that was uploaded during a build. This
-   * is a single record in the artifact manifest JSON file.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.ArtifactResult} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.ArtifactResult) - com.google.cloudbuild.v1.ArtifactResultOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ArtifactResult_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ArtifactResult_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.ArtifactResult.class, - com.google.cloudbuild.v1.ArtifactResult.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.ArtifactResult.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - location_ = ""; - - if (fileHashBuilder_ == null) { - fileHash_ = java.util.Collections.emptyList(); - } else { - fileHash_ = null; - fileHashBuilder_.clear(); - } - bitField0_ = (bitField0_ & ~0x00000001); - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ArtifactResult_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.ArtifactResult getDefaultInstanceForType() { - return com.google.cloudbuild.v1.ArtifactResult.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.ArtifactResult build() { - com.google.cloudbuild.v1.ArtifactResult result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.ArtifactResult buildPartial() { - com.google.cloudbuild.v1.ArtifactResult result = - new com.google.cloudbuild.v1.ArtifactResult(this); - int from_bitField0_ = bitField0_; - result.location_ = location_; - if (fileHashBuilder_ == null) { - if (((bitField0_ & 0x00000001) != 0)) { - fileHash_ = java.util.Collections.unmodifiableList(fileHash_); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.fileHash_ = fileHash_; - } else { - result.fileHash_ = fileHashBuilder_.build(); - } - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.ArtifactResult) { - return mergeFrom((com.google.cloudbuild.v1.ArtifactResult) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.ArtifactResult other) { - if (other == com.google.cloudbuild.v1.ArtifactResult.getDefaultInstance()) return this; - if (!other.getLocation().isEmpty()) { - location_ = other.location_; - onChanged(); - } - if (fileHashBuilder_ == null) { - if (!other.fileHash_.isEmpty()) { - if (fileHash_.isEmpty()) { - fileHash_ = other.fileHash_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureFileHashIsMutable(); - fileHash_.addAll(other.fileHash_); - } - onChanged(); - } - } else { - if (!other.fileHash_.isEmpty()) { - if (fileHashBuilder_.isEmpty()) { - fileHashBuilder_.dispose(); - fileHashBuilder_ = null; - fileHash_ = other.fileHash_; - bitField0_ = (bitField0_ & ~0x00000001); - fileHashBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders - ? getFileHashFieldBuilder() - : null; - } else { - fileHashBuilder_.addAllMessages(other.fileHash_); - } - } - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - location_ = input.readStringRequireUtf8(); - - break; - } // case 10 - case 18: - { - com.google.cloudbuild.v1.FileHashes m = - input.readMessage( - com.google.cloudbuild.v1.FileHashes.parser(), extensionRegistry); - if (fileHashBuilder_ == null) { - ensureFileHashIsMutable(); - fileHash_.add(m); - } else { - fileHashBuilder_.addMessage(m); - } - break; - } // case 18 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private int bitField0_; - - private java.lang.Object location_ = ""; - /** - * - * - *
-     * The path of an artifact in a Google Cloud Storage bucket, with the
-     * generation number. For example,
-     * `gs://mybucket/path/to/output.jar#generation`.
-     * 
- * - * string location = 1; - * - * @return The location. - */ - public java.lang.String getLocation() { - java.lang.Object ref = location_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - location_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * The path of an artifact in a Google Cloud Storage bucket, with the
-     * generation number. For example,
-     * `gs://mybucket/path/to/output.jar#generation`.
-     * 
- * - * string location = 1; - * - * @return The bytes for location. - */ - public com.google.protobuf.ByteString getLocationBytes() { - java.lang.Object ref = location_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - location_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * The path of an artifact in a Google Cloud Storage bucket, with the
-     * generation number. For example,
-     * `gs://mybucket/path/to/output.jar#generation`.
-     * 
- * - * string location = 1; - * - * @param value The location to set. - * @return This builder for chaining. - */ - public Builder setLocation(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - location_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The path of an artifact in a Google Cloud Storage bucket, with the
-     * generation number. For example,
-     * `gs://mybucket/path/to/output.jar#generation`.
-     * 
- * - * string location = 1; - * - * @return This builder for chaining. - */ - public Builder clearLocation() { - - location_ = getDefaultInstance().getLocation(); - onChanged(); - return this; - } - /** - * - * - *
-     * The path of an artifact in a Google Cloud Storage bucket, with the
-     * generation number. For example,
-     * `gs://mybucket/path/to/output.jar#generation`.
-     * 
- * - * string location = 1; - * - * @param value The bytes for location to set. - * @return This builder for chaining. - */ - public Builder setLocationBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - location_ = value; - onChanged(); - return this; - } - - private java.util.List fileHash_ = - java.util.Collections.emptyList(); - - private void ensureFileHashIsMutable() { - if (!((bitField0_ & 0x00000001) != 0)) { - fileHash_ = new java.util.ArrayList(fileHash_); - bitField0_ |= 0x00000001; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloudbuild.v1.FileHashes, - com.google.cloudbuild.v1.FileHashes.Builder, - com.google.cloudbuild.v1.FileHashesOrBuilder> - fileHashBuilder_; - - /** - * - * - *
-     * The file hash of the artifact.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.FileHashes file_hash = 2; - */ - public java.util.List getFileHashList() { - if (fileHashBuilder_ == null) { - return java.util.Collections.unmodifiableList(fileHash_); - } else { - return fileHashBuilder_.getMessageList(); - } - } - /** - * - * - *
-     * The file hash of the artifact.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.FileHashes file_hash = 2; - */ - public int getFileHashCount() { - if (fileHashBuilder_ == null) { - return fileHash_.size(); - } else { - return fileHashBuilder_.getCount(); - } - } - /** - * - * - *
-     * The file hash of the artifact.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.FileHashes file_hash = 2; - */ - public com.google.cloudbuild.v1.FileHashes getFileHash(int index) { - if (fileHashBuilder_ == null) { - return fileHash_.get(index); - } else { - return fileHashBuilder_.getMessage(index); - } - } - /** - * - * - *
-     * The file hash of the artifact.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.FileHashes file_hash = 2; - */ - public Builder setFileHash(int index, com.google.cloudbuild.v1.FileHashes value) { - if (fileHashBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureFileHashIsMutable(); - fileHash_.set(index, value); - onChanged(); - } else { - fileHashBuilder_.setMessage(index, value); - } - return this; - } - /** - * - * - *
-     * The file hash of the artifact.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.FileHashes file_hash = 2; - */ - public Builder setFileHash( - int index, com.google.cloudbuild.v1.FileHashes.Builder builderForValue) { - if (fileHashBuilder_ == null) { - ensureFileHashIsMutable(); - fileHash_.set(index, builderForValue.build()); - onChanged(); - } else { - fileHashBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * The file hash of the artifact.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.FileHashes file_hash = 2; - */ - public Builder addFileHash(com.google.cloudbuild.v1.FileHashes value) { - if (fileHashBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureFileHashIsMutable(); - fileHash_.add(value); - onChanged(); - } else { - fileHashBuilder_.addMessage(value); - } - return this; - } - /** - * - * - *
-     * The file hash of the artifact.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.FileHashes file_hash = 2; - */ - public Builder addFileHash(int index, com.google.cloudbuild.v1.FileHashes value) { - if (fileHashBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureFileHashIsMutable(); - fileHash_.add(index, value); - onChanged(); - } else { - fileHashBuilder_.addMessage(index, value); - } - return this; - } - /** - * - * - *
-     * The file hash of the artifact.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.FileHashes file_hash = 2; - */ - public Builder addFileHash(com.google.cloudbuild.v1.FileHashes.Builder builderForValue) { - if (fileHashBuilder_ == null) { - ensureFileHashIsMutable(); - fileHash_.add(builderForValue.build()); - onChanged(); - } else { - fileHashBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * The file hash of the artifact.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.FileHashes file_hash = 2; - */ - public Builder addFileHash( - int index, com.google.cloudbuild.v1.FileHashes.Builder builderForValue) { - if (fileHashBuilder_ == null) { - ensureFileHashIsMutable(); - fileHash_.add(index, builderForValue.build()); - onChanged(); - } else { - fileHashBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * The file hash of the artifact.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.FileHashes file_hash = 2; - */ - public Builder addAllFileHash( - java.lang.Iterable values) { - if (fileHashBuilder_ == null) { - ensureFileHashIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, fileHash_); - onChanged(); - } else { - fileHashBuilder_.addAllMessages(values); - } - return this; - } - /** - * - * - *
-     * The file hash of the artifact.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.FileHashes file_hash = 2; - */ - public Builder clearFileHash() { - if (fileHashBuilder_ == null) { - fileHash_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - } else { - fileHashBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * The file hash of the artifact.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.FileHashes file_hash = 2; - */ - public Builder removeFileHash(int index) { - if (fileHashBuilder_ == null) { - ensureFileHashIsMutable(); - fileHash_.remove(index); - onChanged(); - } else { - fileHashBuilder_.remove(index); - } - return this; - } - /** - * - * - *
-     * The file hash of the artifact.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.FileHashes file_hash = 2; - */ - public com.google.cloudbuild.v1.FileHashes.Builder getFileHashBuilder(int index) { - return getFileHashFieldBuilder().getBuilder(index); - } - /** - * - * - *
-     * The file hash of the artifact.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.FileHashes file_hash = 2; - */ - public com.google.cloudbuild.v1.FileHashesOrBuilder getFileHashOrBuilder(int index) { - if (fileHashBuilder_ == null) { - return fileHash_.get(index); - } else { - return fileHashBuilder_.getMessageOrBuilder(index); - } - } - /** - * - * - *
-     * The file hash of the artifact.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.FileHashes file_hash = 2; - */ - public java.util.List - getFileHashOrBuilderList() { - if (fileHashBuilder_ != null) { - return fileHashBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(fileHash_); - } - } - /** - * - * - *
-     * The file hash of the artifact.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.FileHashes file_hash = 2; - */ - public com.google.cloudbuild.v1.FileHashes.Builder addFileHashBuilder() { - return getFileHashFieldBuilder() - .addBuilder(com.google.cloudbuild.v1.FileHashes.getDefaultInstance()); - } - /** - * - * - *
-     * The file hash of the artifact.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.FileHashes file_hash = 2; - */ - public com.google.cloudbuild.v1.FileHashes.Builder addFileHashBuilder(int index) { - return getFileHashFieldBuilder() - .addBuilder(index, com.google.cloudbuild.v1.FileHashes.getDefaultInstance()); - } - /** - * - * - *
-     * The file hash of the artifact.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.FileHashes file_hash = 2; - */ - public java.util.List getFileHashBuilderList() { - return getFileHashFieldBuilder().getBuilderList(); - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloudbuild.v1.FileHashes, - com.google.cloudbuild.v1.FileHashes.Builder, - com.google.cloudbuild.v1.FileHashesOrBuilder> - getFileHashFieldBuilder() { - if (fileHashBuilder_ == null) { - fileHashBuilder_ = - new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloudbuild.v1.FileHashes, - com.google.cloudbuild.v1.FileHashes.Builder, - com.google.cloudbuild.v1.FileHashesOrBuilder>( - fileHash_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); - fileHash_ = null; - } - return fileHashBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.ArtifactResult) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.ArtifactResult) - private static final com.google.cloudbuild.v1.ArtifactResult DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.ArtifactResult(); - } - - public static com.google.cloudbuild.v1.ArtifactResult getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public ArtifactResult parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.ArtifactResult getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ArtifactResultOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ArtifactResultOrBuilder.java deleted file mode 100644 index 88aaf553..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ArtifactResultOrBuilder.java +++ /dev/null @@ -1,105 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface ArtifactResultOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.ArtifactResult) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The path of an artifact in a Google Cloud Storage bucket, with the
-   * generation number. For example,
-   * `gs://mybucket/path/to/output.jar#generation`.
-   * 
- * - * string location = 1; - * - * @return The location. - */ - java.lang.String getLocation(); - /** - * - * - *
-   * The path of an artifact in a Google Cloud Storage bucket, with the
-   * generation number. For example,
-   * `gs://mybucket/path/to/output.jar#generation`.
-   * 
- * - * string location = 1; - * - * @return The bytes for location. - */ - com.google.protobuf.ByteString getLocationBytes(); - - /** - * - * - *
-   * The file hash of the artifact.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.FileHashes file_hash = 2; - */ - java.util.List getFileHashList(); - /** - * - * - *
-   * The file hash of the artifact.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.FileHashes file_hash = 2; - */ - com.google.cloudbuild.v1.FileHashes getFileHash(int index); - /** - * - * - *
-   * The file hash of the artifact.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.FileHashes file_hash = 2; - */ - int getFileHashCount(); - /** - * - * - *
-   * The file hash of the artifact.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.FileHashes file_hash = 2; - */ - java.util.List getFileHashOrBuilderList(); - /** - * - * - *
-   * The file hash of the artifact.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.FileHashes file_hash = 2; - */ - com.google.cloudbuild.v1.FileHashesOrBuilder getFileHashOrBuilder(int index); -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Artifacts.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Artifacts.java deleted file mode 100644 index 3e83f049..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Artifacts.java +++ /dev/null @@ -1,2445 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * Artifacts produced by a build that should be uploaded upon
- * successful completion of all build steps.
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.Artifacts} - */ -public final class Artifacts extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.Artifacts) - ArtifactsOrBuilder { - private static final long serialVersionUID = 0L; - // Use Artifacts.newBuilder() to construct. - private Artifacts(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private Artifacts() { - images_ = com.google.protobuf.LazyStringArrayList.EMPTY; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new Artifacts(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Artifacts_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Artifacts_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.Artifacts.class, - com.google.cloudbuild.v1.Artifacts.Builder.class); - } - - public interface ArtifactObjectsOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.Artifacts.ArtifactObjects) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-     * Cloud Storage bucket and optional object path, in the form
-     * "gs://bucket/path/to/somewhere/". (see [Bucket Name
-     * Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)).
-     * Files in the workspace matching any path pattern will be uploaded to
-     * Cloud Storage with this location as a prefix.
-     * 
- * - * string location = 1; - * - * @return The location. - */ - java.lang.String getLocation(); - /** - * - * - *
-     * Cloud Storage bucket and optional object path, in the form
-     * "gs://bucket/path/to/somewhere/". (see [Bucket Name
-     * Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)).
-     * Files in the workspace matching any path pattern will be uploaded to
-     * Cloud Storage with this location as a prefix.
-     * 
- * - * string location = 1; - * - * @return The bytes for location. - */ - com.google.protobuf.ByteString getLocationBytes(); - - /** - * - * - *
-     * Path globs used to match files in the build's workspace.
-     * 
- * - * repeated string paths = 2; - * - * @return A list containing the paths. - */ - java.util.List getPathsList(); - /** - * - * - *
-     * Path globs used to match files in the build's workspace.
-     * 
- * - * repeated string paths = 2; - * - * @return The count of paths. - */ - int getPathsCount(); - /** - * - * - *
-     * Path globs used to match files in the build's workspace.
-     * 
- * - * repeated string paths = 2; - * - * @param index The index of the element to return. - * @return The paths at the given index. - */ - java.lang.String getPaths(int index); - /** - * - * - *
-     * Path globs used to match files in the build's workspace.
-     * 
- * - * repeated string paths = 2; - * - * @param index The index of the value to return. - * @return The bytes of the paths at the given index. - */ - com.google.protobuf.ByteString getPathsBytes(int index); - - /** - * - * - *
-     * Output only. Stores timing information for pushing all artifact objects.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan timing = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return Whether the timing field is set. - */ - boolean hasTiming(); - /** - * - * - *
-     * Output only. Stores timing information for pushing all artifact objects.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan timing = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The timing. - */ - com.google.cloudbuild.v1.TimeSpan getTiming(); - /** - * - * - *
-     * Output only. Stores timing information for pushing all artifact objects.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan timing = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - com.google.cloudbuild.v1.TimeSpanOrBuilder getTimingOrBuilder(); - } - /** - * - * - *
-   * Files in the workspace to upload to Cloud Storage upon successful
-   * completion of all build steps.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.Artifacts.ArtifactObjects} - */ - public static final class ArtifactObjects extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.Artifacts.ArtifactObjects) - ArtifactObjectsOrBuilder { - private static final long serialVersionUID = 0L; - // Use ArtifactObjects.newBuilder() to construct. - private ArtifactObjects(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private ArtifactObjects() { - location_ = ""; - paths_ = com.google.protobuf.LazyStringArrayList.EMPTY; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new ArtifactObjects(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Artifacts_ArtifactObjects_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Artifacts_ArtifactObjects_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.Artifacts.ArtifactObjects.class, - com.google.cloudbuild.v1.Artifacts.ArtifactObjects.Builder.class); - } - - public static final int LOCATION_FIELD_NUMBER = 1; - private volatile java.lang.Object location_; - /** - * - * - *
-     * Cloud Storage bucket and optional object path, in the form
-     * "gs://bucket/path/to/somewhere/". (see [Bucket Name
-     * Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)).
-     * Files in the workspace matching any path pattern will be uploaded to
-     * Cloud Storage with this location as a prefix.
-     * 
- * - * string location = 1; - * - * @return The location. - */ - @java.lang.Override - public java.lang.String getLocation() { - java.lang.Object ref = location_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - location_ = s; - return s; - } - } - /** - * - * - *
-     * Cloud Storage bucket and optional object path, in the form
-     * "gs://bucket/path/to/somewhere/". (see [Bucket Name
-     * Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)).
-     * Files in the workspace matching any path pattern will be uploaded to
-     * Cloud Storage with this location as a prefix.
-     * 
- * - * string location = 1; - * - * @return The bytes for location. - */ - @java.lang.Override - public com.google.protobuf.ByteString getLocationBytes() { - java.lang.Object ref = location_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - location_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int PATHS_FIELD_NUMBER = 2; - private com.google.protobuf.LazyStringList paths_; - /** - * - * - *
-     * Path globs used to match files in the build's workspace.
-     * 
- * - * repeated string paths = 2; - * - * @return A list containing the paths. - */ - public com.google.protobuf.ProtocolStringList getPathsList() { - return paths_; - } - /** - * - * - *
-     * Path globs used to match files in the build's workspace.
-     * 
- * - * repeated string paths = 2; - * - * @return The count of paths. - */ - public int getPathsCount() { - return paths_.size(); - } - /** - * - * - *
-     * Path globs used to match files in the build's workspace.
-     * 
- * - * repeated string paths = 2; - * - * @param index The index of the element to return. - * @return The paths at the given index. - */ - public java.lang.String getPaths(int index) { - return paths_.get(index); - } - /** - * - * - *
-     * Path globs used to match files in the build's workspace.
-     * 
- * - * repeated string paths = 2; - * - * @param index The index of the value to return. - * @return The bytes of the paths at the given index. - */ - public com.google.protobuf.ByteString getPathsBytes(int index) { - return paths_.getByteString(index); - } - - public static final int TIMING_FIELD_NUMBER = 3; - private com.google.cloudbuild.v1.TimeSpan timing_; - /** - * - * - *
-     * Output only. Stores timing information for pushing all artifact objects.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan timing = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return Whether the timing field is set. - */ - @java.lang.Override - public boolean hasTiming() { - return timing_ != null; - } - /** - * - * - *
-     * Output only. Stores timing information for pushing all artifact objects.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan timing = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The timing. - */ - @java.lang.Override - public com.google.cloudbuild.v1.TimeSpan getTiming() { - return timing_ == null ? com.google.cloudbuild.v1.TimeSpan.getDefaultInstance() : timing_; - } - /** - * - * - *
-     * Output only. Stores timing information for pushing all artifact objects.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan timing = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - @java.lang.Override - public com.google.cloudbuild.v1.TimeSpanOrBuilder getTimingOrBuilder() { - return getTiming(); - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(location_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, location_); - } - for (int i = 0; i < paths_.size(); i++) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, paths_.getRaw(i)); - } - if (timing_ != null) { - output.writeMessage(3, getTiming()); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(location_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, location_); - } - { - int dataSize = 0; - for (int i = 0; i < paths_.size(); i++) { - dataSize += computeStringSizeNoTag(paths_.getRaw(i)); - } - size += dataSize; - size += 1 * getPathsList().size(); - } - if (timing_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getTiming()); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.Artifacts.ArtifactObjects)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.Artifacts.ArtifactObjects other = - (com.google.cloudbuild.v1.Artifacts.ArtifactObjects) obj; - - if (!getLocation().equals(other.getLocation())) return false; - if (!getPathsList().equals(other.getPathsList())) return false; - if (hasTiming() != other.hasTiming()) return false; - if (hasTiming()) { - if (!getTiming().equals(other.getTiming())) return false; - } - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + LOCATION_FIELD_NUMBER; - hash = (53 * hash) + getLocation().hashCode(); - if (getPathsCount() > 0) { - hash = (37 * hash) + PATHS_FIELD_NUMBER; - hash = (53 * hash) + getPathsList().hashCode(); - } - if (hasTiming()) { - hash = (37 * hash) + TIMING_FIELD_NUMBER; - hash = (53 * hash) + getTiming().hashCode(); - } - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.Artifacts.ArtifactObjects parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.Artifacts.ArtifactObjects parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.Artifacts.ArtifactObjects parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.Artifacts.ArtifactObjects parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.Artifacts.ArtifactObjects parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.Artifacts.ArtifactObjects parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.Artifacts.ArtifactObjects parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.Artifacts.ArtifactObjects parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.Artifacts.ArtifactObjects parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.Artifacts.ArtifactObjects parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.Artifacts.ArtifactObjects parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.Artifacts.ArtifactObjects parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.Artifacts.ArtifactObjects prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-     * Files in the workspace to upload to Cloud Storage upon successful
-     * completion of all build steps.
-     * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.Artifacts.ArtifactObjects} - */ - public static final class Builder - extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.Artifacts.ArtifactObjects) - com.google.cloudbuild.v1.Artifacts.ArtifactObjectsOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Artifacts_ArtifactObjects_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Artifacts_ArtifactObjects_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.Artifacts.ArtifactObjects.class, - com.google.cloudbuild.v1.Artifacts.ArtifactObjects.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.Artifacts.ArtifactObjects.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - location_ = ""; - - paths_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000001); - if (timingBuilder_ == null) { - timing_ = null; - } else { - timing_ = null; - timingBuilder_ = null; - } - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Artifacts_ArtifactObjects_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.Artifacts.ArtifactObjects getDefaultInstanceForType() { - return com.google.cloudbuild.v1.Artifacts.ArtifactObjects.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.Artifacts.ArtifactObjects build() { - com.google.cloudbuild.v1.Artifacts.ArtifactObjects result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.Artifacts.ArtifactObjects buildPartial() { - com.google.cloudbuild.v1.Artifacts.ArtifactObjects result = - new com.google.cloudbuild.v1.Artifacts.ArtifactObjects(this); - int from_bitField0_ = bitField0_; - result.location_ = location_; - if (((bitField0_ & 0x00000001) != 0)) { - paths_ = paths_.getUnmodifiableView(); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.paths_ = paths_; - if (timingBuilder_ == null) { - result.timing_ = timing_; - } else { - result.timing_ = timingBuilder_.build(); - } - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, - java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.Artifacts.ArtifactObjects) { - return mergeFrom((com.google.cloudbuild.v1.Artifacts.ArtifactObjects) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.Artifacts.ArtifactObjects other) { - if (other == com.google.cloudbuild.v1.Artifacts.ArtifactObjects.getDefaultInstance()) - return this; - if (!other.getLocation().isEmpty()) { - location_ = other.location_; - onChanged(); - } - if (!other.paths_.isEmpty()) { - if (paths_.isEmpty()) { - paths_ = other.paths_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensurePathsIsMutable(); - paths_.addAll(other.paths_); - } - onChanged(); - } - if (other.hasTiming()) { - mergeTiming(other.getTiming()); - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - location_ = input.readStringRequireUtf8(); - - break; - } // case 10 - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - ensurePathsIsMutable(); - paths_.add(s); - break; - } // case 18 - case 26: - { - input.readMessage(getTimingFieldBuilder().getBuilder(), extensionRegistry); - - break; - } // case 26 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private int bitField0_; - - private java.lang.Object location_ = ""; - /** - * - * - *
-       * Cloud Storage bucket and optional object path, in the form
-       * "gs://bucket/path/to/somewhere/". (see [Bucket Name
-       * Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)).
-       * Files in the workspace matching any path pattern will be uploaded to
-       * Cloud Storage with this location as a prefix.
-       * 
- * - * string location = 1; - * - * @return The location. - */ - public java.lang.String getLocation() { - java.lang.Object ref = location_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - location_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-       * Cloud Storage bucket and optional object path, in the form
-       * "gs://bucket/path/to/somewhere/". (see [Bucket Name
-       * Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)).
-       * Files in the workspace matching any path pattern will be uploaded to
-       * Cloud Storage with this location as a prefix.
-       * 
- * - * string location = 1; - * - * @return The bytes for location. - */ - public com.google.protobuf.ByteString getLocationBytes() { - java.lang.Object ref = location_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - location_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-       * Cloud Storage bucket and optional object path, in the form
-       * "gs://bucket/path/to/somewhere/". (see [Bucket Name
-       * Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)).
-       * Files in the workspace matching any path pattern will be uploaded to
-       * Cloud Storage with this location as a prefix.
-       * 
- * - * string location = 1; - * - * @param value The location to set. - * @return This builder for chaining. - */ - public Builder setLocation(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - location_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * Cloud Storage bucket and optional object path, in the form
-       * "gs://bucket/path/to/somewhere/". (see [Bucket Name
-       * Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)).
-       * Files in the workspace matching any path pattern will be uploaded to
-       * Cloud Storage with this location as a prefix.
-       * 
- * - * string location = 1; - * - * @return This builder for chaining. - */ - public Builder clearLocation() { - - location_ = getDefaultInstance().getLocation(); - onChanged(); - return this; - } - /** - * - * - *
-       * Cloud Storage bucket and optional object path, in the form
-       * "gs://bucket/path/to/somewhere/". (see [Bucket Name
-       * Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)).
-       * Files in the workspace matching any path pattern will be uploaded to
-       * Cloud Storage with this location as a prefix.
-       * 
- * - * string location = 1; - * - * @param value The bytes for location to set. - * @return This builder for chaining. - */ - public Builder setLocationBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - location_ = value; - onChanged(); - return this; - } - - private com.google.protobuf.LazyStringList paths_ = - com.google.protobuf.LazyStringArrayList.EMPTY; - - private void ensurePathsIsMutable() { - if (!((bitField0_ & 0x00000001) != 0)) { - paths_ = new com.google.protobuf.LazyStringArrayList(paths_); - bitField0_ |= 0x00000001; - } - } - /** - * - * - *
-       * Path globs used to match files in the build's workspace.
-       * 
- * - * repeated string paths = 2; - * - * @return A list containing the paths. - */ - public com.google.protobuf.ProtocolStringList getPathsList() { - return paths_.getUnmodifiableView(); - } - /** - * - * - *
-       * Path globs used to match files in the build's workspace.
-       * 
- * - * repeated string paths = 2; - * - * @return The count of paths. - */ - public int getPathsCount() { - return paths_.size(); - } - /** - * - * - *
-       * Path globs used to match files in the build's workspace.
-       * 
- * - * repeated string paths = 2; - * - * @param index The index of the element to return. - * @return The paths at the given index. - */ - public java.lang.String getPaths(int index) { - return paths_.get(index); - } - /** - * - * - *
-       * Path globs used to match files in the build's workspace.
-       * 
- * - * repeated string paths = 2; - * - * @param index The index of the value to return. - * @return The bytes of the paths at the given index. - */ - public com.google.protobuf.ByteString getPathsBytes(int index) { - return paths_.getByteString(index); - } - /** - * - * - *
-       * Path globs used to match files in the build's workspace.
-       * 
- * - * repeated string paths = 2; - * - * @param index The index to set the value at. - * @param value The paths to set. - * @return This builder for chaining. - */ - public Builder setPaths(int index, java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensurePathsIsMutable(); - paths_.set(index, value); - onChanged(); - return this; - } - /** - * - * - *
-       * Path globs used to match files in the build's workspace.
-       * 
- * - * repeated string paths = 2; - * - * @param value The paths to add. - * @return This builder for chaining. - */ - public Builder addPaths(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensurePathsIsMutable(); - paths_.add(value); - onChanged(); - return this; - } - /** - * - * - *
-       * Path globs used to match files in the build's workspace.
-       * 
- * - * repeated string paths = 2; - * - * @param values The paths to add. - * @return This builder for chaining. - */ - public Builder addAllPaths(java.lang.Iterable values) { - ensurePathsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, paths_); - onChanged(); - return this; - } - /** - * - * - *
-       * Path globs used to match files in the build's workspace.
-       * 
- * - * repeated string paths = 2; - * - * @return This builder for chaining. - */ - public Builder clearPaths() { - paths_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - return this; - } - /** - * - * - *
-       * Path globs used to match files in the build's workspace.
-       * 
- * - * repeated string paths = 2; - * - * @param value The bytes of the paths to add. - * @return This builder for chaining. - */ - public Builder addPathsBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - ensurePathsIsMutable(); - paths_.add(value); - onChanged(); - return this; - } - - private com.google.cloudbuild.v1.TimeSpan timing_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.TimeSpan, - com.google.cloudbuild.v1.TimeSpan.Builder, - com.google.cloudbuild.v1.TimeSpanOrBuilder> - timingBuilder_; - /** - * - * - *
-       * Output only. Stores timing information for pushing all artifact objects.
-       * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan timing = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return Whether the timing field is set. - */ - public boolean hasTiming() { - return timingBuilder_ != null || timing_ != null; - } - /** - * - * - *
-       * Output only. Stores timing information for pushing all artifact objects.
-       * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan timing = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The timing. - */ - public com.google.cloudbuild.v1.TimeSpan getTiming() { - if (timingBuilder_ == null) { - return timing_ == null ? com.google.cloudbuild.v1.TimeSpan.getDefaultInstance() : timing_; - } else { - return timingBuilder_.getMessage(); - } - } - /** - * - * - *
-       * Output only. Stores timing information for pushing all artifact objects.
-       * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan timing = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder setTiming(com.google.cloudbuild.v1.TimeSpan value) { - if (timingBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - timing_ = value; - onChanged(); - } else { - timingBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-       * Output only. Stores timing information for pushing all artifact objects.
-       * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan timing = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder setTiming(com.google.cloudbuild.v1.TimeSpan.Builder builderForValue) { - if (timingBuilder_ == null) { - timing_ = builderForValue.build(); - onChanged(); - } else { - timingBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-       * Output only. Stores timing information for pushing all artifact objects.
-       * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan timing = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder mergeTiming(com.google.cloudbuild.v1.TimeSpan value) { - if (timingBuilder_ == null) { - if (timing_ != null) { - timing_ = - com.google.cloudbuild.v1.TimeSpan.newBuilder(timing_) - .mergeFrom(value) - .buildPartial(); - } else { - timing_ = value; - } - onChanged(); - } else { - timingBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-       * Output only. Stores timing information for pushing all artifact objects.
-       * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan timing = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder clearTiming() { - if (timingBuilder_ == null) { - timing_ = null; - onChanged(); - } else { - timing_ = null; - timingBuilder_ = null; - } - - return this; - } - /** - * - * - *
-       * Output only. Stores timing information for pushing all artifact objects.
-       * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan timing = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public com.google.cloudbuild.v1.TimeSpan.Builder getTimingBuilder() { - - onChanged(); - return getTimingFieldBuilder().getBuilder(); - } - /** - * - * - *
-       * Output only. Stores timing information for pushing all artifact objects.
-       * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan timing = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public com.google.cloudbuild.v1.TimeSpanOrBuilder getTimingOrBuilder() { - if (timingBuilder_ != null) { - return timingBuilder_.getMessageOrBuilder(); - } else { - return timing_ == null ? com.google.cloudbuild.v1.TimeSpan.getDefaultInstance() : timing_; - } - } - /** - * - * - *
-       * Output only. Stores timing information for pushing all artifact objects.
-       * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan timing = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.TimeSpan, - com.google.cloudbuild.v1.TimeSpan.Builder, - com.google.cloudbuild.v1.TimeSpanOrBuilder> - getTimingFieldBuilder() { - if (timingBuilder_ == null) { - timingBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.TimeSpan, - com.google.cloudbuild.v1.TimeSpan.Builder, - com.google.cloudbuild.v1.TimeSpanOrBuilder>( - getTiming(), getParentForChildren(), isClean()); - timing_ = null; - } - return timingBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.Artifacts.ArtifactObjects) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.Artifacts.ArtifactObjects) - private static final com.google.cloudbuild.v1.Artifacts.ArtifactObjects DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.Artifacts.ArtifactObjects(); - } - - public static com.google.cloudbuild.v1.Artifacts.ArtifactObjects getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public ArtifactObjects parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException() - .setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.Artifacts.ArtifactObjects getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - } - - public static final int IMAGES_FIELD_NUMBER = 1; - private com.google.protobuf.LazyStringList images_; - /** - * - * - *
-   * A list of images to be pushed upon the successful completion of all build
-   * steps.
-   * The images will be pushed using the builder service account's credentials.
-   * The digests of the pushed images will be stored in the Build resource's
-   * results field.
-   * If any of the images fail to be pushed, the build is marked FAILURE.
-   * 
- * - * repeated string images = 1; - * - * @return A list containing the images. - */ - public com.google.protobuf.ProtocolStringList getImagesList() { - return images_; - } - /** - * - * - *
-   * A list of images to be pushed upon the successful completion of all build
-   * steps.
-   * The images will be pushed using the builder service account's credentials.
-   * The digests of the pushed images will be stored in the Build resource's
-   * results field.
-   * If any of the images fail to be pushed, the build is marked FAILURE.
-   * 
- * - * repeated string images = 1; - * - * @return The count of images. - */ - public int getImagesCount() { - return images_.size(); - } - /** - * - * - *
-   * A list of images to be pushed upon the successful completion of all build
-   * steps.
-   * The images will be pushed using the builder service account's credentials.
-   * The digests of the pushed images will be stored in the Build resource's
-   * results field.
-   * If any of the images fail to be pushed, the build is marked FAILURE.
-   * 
- * - * repeated string images = 1; - * - * @param index The index of the element to return. - * @return The images at the given index. - */ - public java.lang.String getImages(int index) { - return images_.get(index); - } - /** - * - * - *
-   * A list of images to be pushed upon the successful completion of all build
-   * steps.
-   * The images will be pushed using the builder service account's credentials.
-   * The digests of the pushed images will be stored in the Build resource's
-   * results field.
-   * If any of the images fail to be pushed, the build is marked FAILURE.
-   * 
- * - * repeated string images = 1; - * - * @param index The index of the value to return. - * @return The bytes of the images at the given index. - */ - public com.google.protobuf.ByteString getImagesBytes(int index) { - return images_.getByteString(index); - } - - public static final int OBJECTS_FIELD_NUMBER = 2; - private com.google.cloudbuild.v1.Artifacts.ArtifactObjects objects_; - /** - * - * - *
-   * A list of objects to be uploaded to Cloud Storage upon successful
-   * completion of all build steps.
-   * Files in the workspace matching specified paths globs will be uploaded to
-   * the specified Cloud Storage location using the builder service account's
-   * credentials.
-   * The location and generation of the uploaded objects will be stored in the
-   * Build resource's results field.
-   * If any objects fail to be pushed, the build is marked FAILURE.
-   * 
- * - * .google.devtools.cloudbuild.v1.Artifacts.ArtifactObjects objects = 2; - * - * @return Whether the objects field is set. - */ - @java.lang.Override - public boolean hasObjects() { - return objects_ != null; - } - /** - * - * - *
-   * A list of objects to be uploaded to Cloud Storage upon successful
-   * completion of all build steps.
-   * Files in the workspace matching specified paths globs will be uploaded to
-   * the specified Cloud Storage location using the builder service account's
-   * credentials.
-   * The location and generation of the uploaded objects will be stored in the
-   * Build resource's results field.
-   * If any objects fail to be pushed, the build is marked FAILURE.
-   * 
- * - * .google.devtools.cloudbuild.v1.Artifacts.ArtifactObjects objects = 2; - * - * @return The objects. - */ - @java.lang.Override - public com.google.cloudbuild.v1.Artifacts.ArtifactObjects getObjects() { - return objects_ == null - ? com.google.cloudbuild.v1.Artifacts.ArtifactObjects.getDefaultInstance() - : objects_; - } - /** - * - * - *
-   * A list of objects to be uploaded to Cloud Storage upon successful
-   * completion of all build steps.
-   * Files in the workspace matching specified paths globs will be uploaded to
-   * the specified Cloud Storage location using the builder service account's
-   * credentials.
-   * The location and generation of the uploaded objects will be stored in the
-   * Build resource's results field.
-   * If any objects fail to be pushed, the build is marked FAILURE.
-   * 
- * - * .google.devtools.cloudbuild.v1.Artifacts.ArtifactObjects objects = 2; - */ - @java.lang.Override - public com.google.cloudbuild.v1.Artifacts.ArtifactObjectsOrBuilder getObjectsOrBuilder() { - return getObjects(); - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - for (int i = 0; i < images_.size(); i++) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, images_.getRaw(i)); - } - if (objects_ != null) { - output.writeMessage(2, getObjects()); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - { - int dataSize = 0; - for (int i = 0; i < images_.size(); i++) { - dataSize += computeStringSizeNoTag(images_.getRaw(i)); - } - size += dataSize; - size += 1 * getImagesList().size(); - } - if (objects_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getObjects()); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.Artifacts)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.Artifacts other = (com.google.cloudbuild.v1.Artifacts) obj; - - if (!getImagesList().equals(other.getImagesList())) return false; - if (hasObjects() != other.hasObjects()) return false; - if (hasObjects()) { - if (!getObjects().equals(other.getObjects())) return false; - } - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (getImagesCount() > 0) { - hash = (37 * hash) + IMAGES_FIELD_NUMBER; - hash = (53 * hash) + getImagesList().hashCode(); - } - if (hasObjects()) { - hash = (37 * hash) + OBJECTS_FIELD_NUMBER; - hash = (53 * hash) + getObjects().hashCode(); - } - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.Artifacts parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.Artifacts parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.Artifacts parseFrom(com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.Artifacts parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.Artifacts parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.Artifacts parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.Artifacts parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.Artifacts parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.Artifacts parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.Artifacts parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.Artifacts parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.Artifacts parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.Artifacts prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * Artifacts produced by a build that should be uploaded upon
-   * successful completion of all build steps.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.Artifacts} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.Artifacts) - com.google.cloudbuild.v1.ArtifactsOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Artifacts_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Artifacts_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.Artifacts.class, - com.google.cloudbuild.v1.Artifacts.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.Artifacts.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - images_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000001); - if (objectsBuilder_ == null) { - objects_ = null; - } else { - objects_ = null; - objectsBuilder_ = null; - } - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Artifacts_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.Artifacts getDefaultInstanceForType() { - return com.google.cloudbuild.v1.Artifacts.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.Artifacts build() { - com.google.cloudbuild.v1.Artifacts result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.Artifacts buildPartial() { - com.google.cloudbuild.v1.Artifacts result = new com.google.cloudbuild.v1.Artifacts(this); - int from_bitField0_ = bitField0_; - if (((bitField0_ & 0x00000001) != 0)) { - images_ = images_.getUnmodifiableView(); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.images_ = images_; - if (objectsBuilder_ == null) { - result.objects_ = objects_; - } else { - result.objects_ = objectsBuilder_.build(); - } - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.Artifacts) { - return mergeFrom((com.google.cloudbuild.v1.Artifacts) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.Artifacts other) { - if (other == com.google.cloudbuild.v1.Artifacts.getDefaultInstance()) return this; - if (!other.images_.isEmpty()) { - if (images_.isEmpty()) { - images_ = other.images_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureImagesIsMutable(); - images_.addAll(other.images_); - } - onChanged(); - } - if (other.hasObjects()) { - mergeObjects(other.getObjects()); - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - java.lang.String s = input.readStringRequireUtf8(); - ensureImagesIsMutable(); - images_.add(s); - break; - } // case 10 - case 18: - { - input.readMessage(getObjectsFieldBuilder().getBuilder(), extensionRegistry); - - break; - } // case 18 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private int bitField0_; - - private com.google.protobuf.LazyStringList images_ = - com.google.protobuf.LazyStringArrayList.EMPTY; - - private void ensureImagesIsMutable() { - if (!((bitField0_ & 0x00000001) != 0)) { - images_ = new com.google.protobuf.LazyStringArrayList(images_); - bitField0_ |= 0x00000001; - } - } - /** - * - * - *
-     * A list of images to be pushed upon the successful completion of all build
-     * steps.
-     * The images will be pushed using the builder service account's credentials.
-     * The digests of the pushed images will be stored in the Build resource's
-     * results field.
-     * If any of the images fail to be pushed, the build is marked FAILURE.
-     * 
- * - * repeated string images = 1; - * - * @return A list containing the images. - */ - public com.google.protobuf.ProtocolStringList getImagesList() { - return images_.getUnmodifiableView(); - } - /** - * - * - *
-     * A list of images to be pushed upon the successful completion of all build
-     * steps.
-     * The images will be pushed using the builder service account's credentials.
-     * The digests of the pushed images will be stored in the Build resource's
-     * results field.
-     * If any of the images fail to be pushed, the build is marked FAILURE.
-     * 
- * - * repeated string images = 1; - * - * @return The count of images. - */ - public int getImagesCount() { - return images_.size(); - } - /** - * - * - *
-     * A list of images to be pushed upon the successful completion of all build
-     * steps.
-     * The images will be pushed using the builder service account's credentials.
-     * The digests of the pushed images will be stored in the Build resource's
-     * results field.
-     * If any of the images fail to be pushed, the build is marked FAILURE.
-     * 
- * - * repeated string images = 1; - * - * @param index The index of the element to return. - * @return The images at the given index. - */ - public java.lang.String getImages(int index) { - return images_.get(index); - } - /** - * - * - *
-     * A list of images to be pushed upon the successful completion of all build
-     * steps.
-     * The images will be pushed using the builder service account's credentials.
-     * The digests of the pushed images will be stored in the Build resource's
-     * results field.
-     * If any of the images fail to be pushed, the build is marked FAILURE.
-     * 
- * - * repeated string images = 1; - * - * @param index The index of the value to return. - * @return The bytes of the images at the given index. - */ - public com.google.protobuf.ByteString getImagesBytes(int index) { - return images_.getByteString(index); - } - /** - * - * - *
-     * A list of images to be pushed upon the successful completion of all build
-     * steps.
-     * The images will be pushed using the builder service account's credentials.
-     * The digests of the pushed images will be stored in the Build resource's
-     * results field.
-     * If any of the images fail to be pushed, the build is marked FAILURE.
-     * 
- * - * repeated string images = 1; - * - * @param index The index to set the value at. - * @param value The images to set. - * @return This builder for chaining. - */ - public Builder setImages(int index, java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureImagesIsMutable(); - images_.set(index, value); - onChanged(); - return this; - } - /** - * - * - *
-     * A list of images to be pushed upon the successful completion of all build
-     * steps.
-     * The images will be pushed using the builder service account's credentials.
-     * The digests of the pushed images will be stored in the Build resource's
-     * results field.
-     * If any of the images fail to be pushed, the build is marked FAILURE.
-     * 
- * - * repeated string images = 1; - * - * @param value The images to add. - * @return This builder for chaining. - */ - public Builder addImages(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureImagesIsMutable(); - images_.add(value); - onChanged(); - return this; - } - /** - * - * - *
-     * A list of images to be pushed upon the successful completion of all build
-     * steps.
-     * The images will be pushed using the builder service account's credentials.
-     * The digests of the pushed images will be stored in the Build resource's
-     * results field.
-     * If any of the images fail to be pushed, the build is marked FAILURE.
-     * 
- * - * repeated string images = 1; - * - * @param values The images to add. - * @return This builder for chaining. - */ - public Builder addAllImages(java.lang.Iterable values) { - ensureImagesIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, images_); - onChanged(); - return this; - } - /** - * - * - *
-     * A list of images to be pushed upon the successful completion of all build
-     * steps.
-     * The images will be pushed using the builder service account's credentials.
-     * The digests of the pushed images will be stored in the Build resource's
-     * results field.
-     * If any of the images fail to be pushed, the build is marked FAILURE.
-     * 
- * - * repeated string images = 1; - * - * @return This builder for chaining. - */ - public Builder clearImages() { - images_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - return this; - } - /** - * - * - *
-     * A list of images to be pushed upon the successful completion of all build
-     * steps.
-     * The images will be pushed using the builder service account's credentials.
-     * The digests of the pushed images will be stored in the Build resource's
-     * results field.
-     * If any of the images fail to be pushed, the build is marked FAILURE.
-     * 
- * - * repeated string images = 1; - * - * @param value The bytes of the images to add. - * @return This builder for chaining. - */ - public Builder addImagesBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - ensureImagesIsMutable(); - images_.add(value); - onChanged(); - return this; - } - - private com.google.cloudbuild.v1.Artifacts.ArtifactObjects objects_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.Artifacts.ArtifactObjects, - com.google.cloudbuild.v1.Artifacts.ArtifactObjects.Builder, - com.google.cloudbuild.v1.Artifacts.ArtifactObjectsOrBuilder> - objectsBuilder_; - /** - * - * - *
-     * A list of objects to be uploaded to Cloud Storage upon successful
-     * completion of all build steps.
-     * Files in the workspace matching specified paths globs will be uploaded to
-     * the specified Cloud Storage location using the builder service account's
-     * credentials.
-     * The location and generation of the uploaded objects will be stored in the
-     * Build resource's results field.
-     * If any objects fail to be pushed, the build is marked FAILURE.
-     * 
- * - * .google.devtools.cloudbuild.v1.Artifacts.ArtifactObjects objects = 2; - * - * @return Whether the objects field is set. - */ - public boolean hasObjects() { - return objectsBuilder_ != null || objects_ != null; - } - /** - * - * - *
-     * A list of objects to be uploaded to Cloud Storage upon successful
-     * completion of all build steps.
-     * Files in the workspace matching specified paths globs will be uploaded to
-     * the specified Cloud Storage location using the builder service account's
-     * credentials.
-     * The location and generation of the uploaded objects will be stored in the
-     * Build resource's results field.
-     * If any objects fail to be pushed, the build is marked FAILURE.
-     * 
- * - * .google.devtools.cloudbuild.v1.Artifacts.ArtifactObjects objects = 2; - * - * @return The objects. - */ - public com.google.cloudbuild.v1.Artifacts.ArtifactObjects getObjects() { - if (objectsBuilder_ == null) { - return objects_ == null - ? com.google.cloudbuild.v1.Artifacts.ArtifactObjects.getDefaultInstance() - : objects_; - } else { - return objectsBuilder_.getMessage(); - } - } - /** - * - * - *
-     * A list of objects to be uploaded to Cloud Storage upon successful
-     * completion of all build steps.
-     * Files in the workspace matching specified paths globs will be uploaded to
-     * the specified Cloud Storage location using the builder service account's
-     * credentials.
-     * The location and generation of the uploaded objects will be stored in the
-     * Build resource's results field.
-     * If any objects fail to be pushed, the build is marked FAILURE.
-     * 
- * - * .google.devtools.cloudbuild.v1.Artifacts.ArtifactObjects objects = 2; - */ - public Builder setObjects(com.google.cloudbuild.v1.Artifacts.ArtifactObjects value) { - if (objectsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - objects_ = value; - onChanged(); - } else { - objectsBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * A list of objects to be uploaded to Cloud Storage upon successful
-     * completion of all build steps.
-     * Files in the workspace matching specified paths globs will be uploaded to
-     * the specified Cloud Storage location using the builder service account's
-     * credentials.
-     * The location and generation of the uploaded objects will be stored in the
-     * Build resource's results field.
-     * If any objects fail to be pushed, the build is marked FAILURE.
-     * 
- * - * .google.devtools.cloudbuild.v1.Artifacts.ArtifactObjects objects = 2; - */ - public Builder setObjects( - com.google.cloudbuild.v1.Artifacts.ArtifactObjects.Builder builderForValue) { - if (objectsBuilder_ == null) { - objects_ = builderForValue.build(); - onChanged(); - } else { - objectsBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * A list of objects to be uploaded to Cloud Storage upon successful
-     * completion of all build steps.
-     * Files in the workspace matching specified paths globs will be uploaded to
-     * the specified Cloud Storage location using the builder service account's
-     * credentials.
-     * The location and generation of the uploaded objects will be stored in the
-     * Build resource's results field.
-     * If any objects fail to be pushed, the build is marked FAILURE.
-     * 
- * - * .google.devtools.cloudbuild.v1.Artifacts.ArtifactObjects objects = 2; - */ - public Builder mergeObjects(com.google.cloudbuild.v1.Artifacts.ArtifactObjects value) { - if (objectsBuilder_ == null) { - if (objects_ != null) { - objects_ = - com.google.cloudbuild.v1.Artifacts.ArtifactObjects.newBuilder(objects_) - .mergeFrom(value) - .buildPartial(); - } else { - objects_ = value; - } - onChanged(); - } else { - objectsBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * A list of objects to be uploaded to Cloud Storage upon successful
-     * completion of all build steps.
-     * Files in the workspace matching specified paths globs will be uploaded to
-     * the specified Cloud Storage location using the builder service account's
-     * credentials.
-     * The location and generation of the uploaded objects will be stored in the
-     * Build resource's results field.
-     * If any objects fail to be pushed, the build is marked FAILURE.
-     * 
- * - * .google.devtools.cloudbuild.v1.Artifacts.ArtifactObjects objects = 2; - */ - public Builder clearObjects() { - if (objectsBuilder_ == null) { - objects_ = null; - onChanged(); - } else { - objects_ = null; - objectsBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * A list of objects to be uploaded to Cloud Storage upon successful
-     * completion of all build steps.
-     * Files in the workspace matching specified paths globs will be uploaded to
-     * the specified Cloud Storage location using the builder service account's
-     * credentials.
-     * The location and generation of the uploaded objects will be stored in the
-     * Build resource's results field.
-     * If any objects fail to be pushed, the build is marked FAILURE.
-     * 
- * - * .google.devtools.cloudbuild.v1.Artifacts.ArtifactObjects objects = 2; - */ - public com.google.cloudbuild.v1.Artifacts.ArtifactObjects.Builder getObjectsBuilder() { - - onChanged(); - return getObjectsFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * A list of objects to be uploaded to Cloud Storage upon successful
-     * completion of all build steps.
-     * Files in the workspace matching specified paths globs will be uploaded to
-     * the specified Cloud Storage location using the builder service account's
-     * credentials.
-     * The location and generation of the uploaded objects will be stored in the
-     * Build resource's results field.
-     * If any objects fail to be pushed, the build is marked FAILURE.
-     * 
- * - * .google.devtools.cloudbuild.v1.Artifacts.ArtifactObjects objects = 2; - */ - public com.google.cloudbuild.v1.Artifacts.ArtifactObjectsOrBuilder getObjectsOrBuilder() { - if (objectsBuilder_ != null) { - return objectsBuilder_.getMessageOrBuilder(); - } else { - return objects_ == null - ? com.google.cloudbuild.v1.Artifacts.ArtifactObjects.getDefaultInstance() - : objects_; - } - } - /** - * - * - *
-     * A list of objects to be uploaded to Cloud Storage upon successful
-     * completion of all build steps.
-     * Files in the workspace matching specified paths globs will be uploaded to
-     * the specified Cloud Storage location using the builder service account's
-     * credentials.
-     * The location and generation of the uploaded objects will be stored in the
-     * Build resource's results field.
-     * If any objects fail to be pushed, the build is marked FAILURE.
-     * 
- * - * .google.devtools.cloudbuild.v1.Artifacts.ArtifactObjects objects = 2; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.Artifacts.ArtifactObjects, - com.google.cloudbuild.v1.Artifacts.ArtifactObjects.Builder, - com.google.cloudbuild.v1.Artifacts.ArtifactObjectsOrBuilder> - getObjectsFieldBuilder() { - if (objectsBuilder_ == null) { - objectsBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.Artifacts.ArtifactObjects, - com.google.cloudbuild.v1.Artifacts.ArtifactObjects.Builder, - com.google.cloudbuild.v1.Artifacts.ArtifactObjectsOrBuilder>( - getObjects(), getParentForChildren(), isClean()); - objects_ = null; - } - return objectsBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.Artifacts) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.Artifacts) - private static final com.google.cloudbuild.v1.Artifacts DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.Artifacts(); - } - - public static com.google.cloudbuild.v1.Artifacts getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public Artifacts parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.Artifacts getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ArtifactsOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ArtifactsOrBuilder.java deleted file mode 100644 index d59a718b..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ArtifactsOrBuilder.java +++ /dev/null @@ -1,152 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface ArtifactsOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.Artifacts) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * A list of images to be pushed upon the successful completion of all build
-   * steps.
-   * The images will be pushed using the builder service account's credentials.
-   * The digests of the pushed images will be stored in the Build resource's
-   * results field.
-   * If any of the images fail to be pushed, the build is marked FAILURE.
-   * 
- * - * repeated string images = 1; - * - * @return A list containing the images. - */ - java.util.List getImagesList(); - /** - * - * - *
-   * A list of images to be pushed upon the successful completion of all build
-   * steps.
-   * The images will be pushed using the builder service account's credentials.
-   * The digests of the pushed images will be stored in the Build resource's
-   * results field.
-   * If any of the images fail to be pushed, the build is marked FAILURE.
-   * 
- * - * repeated string images = 1; - * - * @return The count of images. - */ - int getImagesCount(); - /** - * - * - *
-   * A list of images to be pushed upon the successful completion of all build
-   * steps.
-   * The images will be pushed using the builder service account's credentials.
-   * The digests of the pushed images will be stored in the Build resource's
-   * results field.
-   * If any of the images fail to be pushed, the build is marked FAILURE.
-   * 
- * - * repeated string images = 1; - * - * @param index The index of the element to return. - * @return The images at the given index. - */ - java.lang.String getImages(int index); - /** - * - * - *
-   * A list of images to be pushed upon the successful completion of all build
-   * steps.
-   * The images will be pushed using the builder service account's credentials.
-   * The digests of the pushed images will be stored in the Build resource's
-   * results field.
-   * If any of the images fail to be pushed, the build is marked FAILURE.
-   * 
- * - * repeated string images = 1; - * - * @param index The index of the value to return. - * @return The bytes of the images at the given index. - */ - com.google.protobuf.ByteString getImagesBytes(int index); - - /** - * - * - *
-   * A list of objects to be uploaded to Cloud Storage upon successful
-   * completion of all build steps.
-   * Files in the workspace matching specified paths globs will be uploaded to
-   * the specified Cloud Storage location using the builder service account's
-   * credentials.
-   * The location and generation of the uploaded objects will be stored in the
-   * Build resource's results field.
-   * If any objects fail to be pushed, the build is marked FAILURE.
-   * 
- * - * .google.devtools.cloudbuild.v1.Artifacts.ArtifactObjects objects = 2; - * - * @return Whether the objects field is set. - */ - boolean hasObjects(); - /** - * - * - *
-   * A list of objects to be uploaded to Cloud Storage upon successful
-   * completion of all build steps.
-   * Files in the workspace matching specified paths globs will be uploaded to
-   * the specified Cloud Storage location using the builder service account's
-   * credentials.
-   * The location and generation of the uploaded objects will be stored in the
-   * Build resource's results field.
-   * If any objects fail to be pushed, the build is marked FAILURE.
-   * 
- * - * .google.devtools.cloudbuild.v1.Artifacts.ArtifactObjects objects = 2; - * - * @return The objects. - */ - com.google.cloudbuild.v1.Artifacts.ArtifactObjects getObjects(); - /** - * - * - *
-   * A list of objects to be uploaded to Cloud Storage upon successful
-   * completion of all build steps.
-   * Files in the workspace matching specified paths globs will be uploaded to
-   * the specified Cloud Storage location using the builder service account's
-   * credentials.
-   * The location and generation of the uploaded objects will be stored in the
-   * Build resource's results field.
-   * If any objects fail to be pushed, the build is marked FAILURE.
-   * 
- * - * .google.devtools.cloudbuild.v1.Artifacts.ArtifactObjects objects = 2; - */ - com.google.cloudbuild.v1.Artifacts.ArtifactObjectsOrBuilder getObjectsOrBuilder(); -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Build.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Build.java deleted file mode 100644 index 9a9f98f7..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Build.java +++ /dev/null @@ -1,11130 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * A build resource in the Cloud Build API.
- * At a high level, a `Build` describes where to find source code, how to build
- * it (for example, the builder image to run on the source), and where to store
- * the built artifacts.
- * Fields can include the following variables, which will be expanded when the
- * build is created:
- * - $PROJECT_ID: the project ID of the build.
- * - $PROJECT_NUMBER: the project number of the build.
- * - $BUILD_ID: the autogenerated ID of the build.
- * - $REPO_NAME: the source repository name specified by RepoSource.
- * - $BRANCH_NAME: the branch name specified by RepoSource.
- * - $TAG_NAME: the tag name specified by RepoSource.
- * - $REVISION_ID or $COMMIT_SHA: the commit SHA specified by RepoSource or
- *   resolved from the specified branch or tag.
- * - $SHORT_SHA: first 7 characters of $REVISION_ID or $COMMIT_SHA.
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.Build} - */ -public final class Build extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.Build) - BuildOrBuilder { - private static final long serialVersionUID = 0L; - // Use Build.newBuilder() to construct. - private Build(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private Build() { - name_ = ""; - id_ = ""; - projectId_ = ""; - status_ = 0; - statusDetail_ = ""; - steps_ = java.util.Collections.emptyList(); - images_ = com.google.protobuf.LazyStringArrayList.EMPTY; - logsBucket_ = ""; - buildTriggerId_ = ""; - logUrl_ = ""; - tags_ = com.google.protobuf.LazyStringArrayList.EMPTY; - secrets_ = java.util.Collections.emptyList(); - serviceAccount_ = ""; - warnings_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new Build(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Build_descriptor; - } - - @SuppressWarnings({"rawtypes"}) - @java.lang.Override - protected com.google.protobuf.MapField internalGetMapField(int number) { - switch (number) { - case 29: - return internalGetSubstitutions(); - case 33: - return internalGetTiming(); - default: - throw new RuntimeException("Invalid map field number: " + number); - } - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Build_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.Build.class, com.google.cloudbuild.v1.Build.Builder.class); - } - - /** - * - * - *
-   * Possible status of a build or build step.
-   * 
- * - * Protobuf enum {@code google.devtools.cloudbuild.v1.Build.Status} - */ - public enum Status implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
-     * Status of the build is unknown.
-     * 
- * - * STATUS_UNKNOWN = 0; - */ - STATUS_UNKNOWN(0), - /** - * - * - *
-     * Build has been created and is pending execution and queuing. It has not
-     * been queued.
-     * 
- * - * PENDING = 10; - */ - PENDING(10), - /** - * - * - *
-     * Build or step is queued; work has not yet begun.
-     * 
- * - * QUEUED = 1; - */ - QUEUED(1), - /** - * - * - *
-     * Build or step is being executed.
-     * 
- * - * WORKING = 2; - */ - WORKING(2), - /** - * - * - *
-     * Build or step finished successfully.
-     * 
- * - * SUCCESS = 3; - */ - SUCCESS(3), - /** - * - * - *
-     * Build or step failed to complete successfully.
-     * 
- * - * FAILURE = 4; - */ - FAILURE(4), - /** - * - * - *
-     * Build or step failed due to an internal cause.
-     * 
- * - * INTERNAL_ERROR = 5; - */ - INTERNAL_ERROR(5), - /** - * - * - *
-     * Build or step took longer than was allowed.
-     * 
- * - * TIMEOUT = 6; - */ - TIMEOUT(6), - /** - * - * - *
-     * Build or step was canceled by a user.
-     * 
- * - * CANCELLED = 7; - */ - CANCELLED(7), - /** - * - * - *
-     * Build was enqueued for longer than the value of `queue_ttl`.
-     * 
- * - * EXPIRED = 9; - */ - EXPIRED(9), - UNRECOGNIZED(-1), - ; - - /** - * - * - *
-     * Status of the build is unknown.
-     * 
- * - * STATUS_UNKNOWN = 0; - */ - public static final int STATUS_UNKNOWN_VALUE = 0; - /** - * - * - *
-     * Build has been created and is pending execution and queuing. It has not
-     * been queued.
-     * 
- * - * PENDING = 10; - */ - public static final int PENDING_VALUE = 10; - /** - * - * - *
-     * Build or step is queued; work has not yet begun.
-     * 
- * - * QUEUED = 1; - */ - public static final int QUEUED_VALUE = 1; - /** - * - * - *
-     * Build or step is being executed.
-     * 
- * - * WORKING = 2; - */ - public static final int WORKING_VALUE = 2; - /** - * - * - *
-     * Build or step finished successfully.
-     * 
- * - * SUCCESS = 3; - */ - public static final int SUCCESS_VALUE = 3; - /** - * - * - *
-     * Build or step failed to complete successfully.
-     * 
- * - * FAILURE = 4; - */ - public static final int FAILURE_VALUE = 4; - /** - * - * - *
-     * Build or step failed due to an internal cause.
-     * 
- * - * INTERNAL_ERROR = 5; - */ - public static final int INTERNAL_ERROR_VALUE = 5; - /** - * - * - *
-     * Build or step took longer than was allowed.
-     * 
- * - * TIMEOUT = 6; - */ - public static final int TIMEOUT_VALUE = 6; - /** - * - * - *
-     * Build or step was canceled by a user.
-     * 
- * - * CANCELLED = 7; - */ - public static final int CANCELLED_VALUE = 7; - /** - * - * - *
-     * Build was enqueued for longer than the value of `queue_ttl`.
-     * 
- * - * EXPIRED = 9; - */ - public static final int EXPIRED_VALUE = 9; - - public final int getNumber() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalArgumentException( - "Can't get the number of an unknown enum value."); - } - return value; - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static Status valueOf(int value) { - return forNumber(value); - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - */ - public static Status forNumber(int value) { - switch (value) { - case 0: - return STATUS_UNKNOWN; - case 10: - return PENDING; - case 1: - return QUEUED; - case 2: - return WORKING; - case 3: - return SUCCESS; - case 4: - return FAILURE; - case 5: - return INTERNAL_ERROR; - case 6: - return TIMEOUT; - case 7: - return CANCELLED; - case 9: - return EXPIRED; - default: - return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { - return internalValueMap; - } - - private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public Status findValueByNumber(int number) { - return Status.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalStateException( - "Can't get the descriptor of an unrecognized enum value."); - } - return getDescriptor().getValues().get(ordinal()); - } - - public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { - return getDescriptor(); - } - - public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return com.google.cloudbuild.v1.Build.getDescriptor().getEnumTypes().get(0); - } - - private static final Status[] VALUES = values(); - - public static Status valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); - } - if (desc.getIndex() == -1) { - return UNRECOGNIZED; - } - return VALUES[desc.getIndex()]; - } - - private final int value; - - private Status(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:google.devtools.cloudbuild.v1.Build.Status) - } - - public interface WarningOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.Build.Warning) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-     * Explanation of the warning generated.
-     * 
- * - * string text = 1; - * - * @return The text. - */ - java.lang.String getText(); - /** - * - * - *
-     * Explanation of the warning generated.
-     * 
- * - * string text = 1; - * - * @return The bytes for text. - */ - com.google.protobuf.ByteString getTextBytes(); - - /** - * - * - *
-     * The priority for this warning.
-     * 
- * - * .google.devtools.cloudbuild.v1.Build.Warning.Priority priority = 2; - * - * @return The enum numeric value on the wire for priority. - */ - int getPriorityValue(); - /** - * - * - *
-     * The priority for this warning.
-     * 
- * - * .google.devtools.cloudbuild.v1.Build.Warning.Priority priority = 2; - * - * @return The priority. - */ - com.google.cloudbuild.v1.Build.Warning.Priority getPriority(); - } - /** - * - * - *
-   * A non-fatal problem encountered during the execution of the build.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.Build.Warning} - */ - public static final class Warning extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.Build.Warning) - WarningOrBuilder { - private static final long serialVersionUID = 0L; - // Use Warning.newBuilder() to construct. - private Warning(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private Warning() { - text_ = ""; - priority_ = 0; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new Warning(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Build_Warning_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Build_Warning_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.Build.Warning.class, - com.google.cloudbuild.v1.Build.Warning.Builder.class); - } - - /** - * - * - *
-     * The relative importance of this warning.
-     * 
- * - * Protobuf enum {@code google.devtools.cloudbuild.v1.Build.Warning.Priority} - */ - public enum Priority implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
-       * Should not be used.
-       * 
- * - * PRIORITY_UNSPECIFIED = 0; - */ - PRIORITY_UNSPECIFIED(0), - /** - * - * - *
-       * e.g. deprecation warnings and alternative feature highlights.
-       * 
- * - * INFO = 1; - */ - INFO(1), - /** - * - * - *
-       * e.g. automated detection of possible issues with the build.
-       * 
- * - * WARNING = 2; - */ - WARNING(2), - /** - * - * - *
-       * e.g. alerts that a feature used in the build is pending removal
-       * 
- * - * ALERT = 3; - */ - ALERT(3), - UNRECOGNIZED(-1), - ; - - /** - * - * - *
-       * Should not be used.
-       * 
- * - * PRIORITY_UNSPECIFIED = 0; - */ - public static final int PRIORITY_UNSPECIFIED_VALUE = 0; - /** - * - * - *
-       * e.g. deprecation warnings and alternative feature highlights.
-       * 
- * - * INFO = 1; - */ - public static final int INFO_VALUE = 1; - /** - * - * - *
-       * e.g. automated detection of possible issues with the build.
-       * 
- * - * WARNING = 2; - */ - public static final int WARNING_VALUE = 2; - /** - * - * - *
-       * e.g. alerts that a feature used in the build is pending removal
-       * 
- * - * ALERT = 3; - */ - public static final int ALERT_VALUE = 3; - - public final int getNumber() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalArgumentException( - "Can't get the number of an unknown enum value."); - } - return value; - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static Priority valueOf(int value) { - return forNumber(value); - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - */ - public static Priority forNumber(int value) { - switch (value) { - case 0: - return PRIORITY_UNSPECIFIED; - case 1: - return INFO; - case 2: - return WARNING; - case 3: - return ALERT; - default: - return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { - return internalValueMap; - } - - private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public Priority findValueByNumber(int number) { - return Priority.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalStateException( - "Can't get the descriptor of an unrecognized enum value."); - } - return getDescriptor().getValues().get(ordinal()); - } - - public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { - return getDescriptor(); - } - - public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return com.google.cloudbuild.v1.Build.Warning.getDescriptor().getEnumTypes().get(0); - } - - private static final Priority[] VALUES = values(); - - public static Priority valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); - } - if (desc.getIndex() == -1) { - return UNRECOGNIZED; - } - return VALUES[desc.getIndex()]; - } - - private final int value; - - private Priority(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:google.devtools.cloudbuild.v1.Build.Warning.Priority) - } - - public static final int TEXT_FIELD_NUMBER = 1; - private volatile java.lang.Object text_; - /** - * - * - *
-     * Explanation of the warning generated.
-     * 
- * - * string text = 1; - * - * @return The text. - */ - @java.lang.Override - public java.lang.String getText() { - java.lang.Object ref = text_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - text_ = s; - return s; - } - } - /** - * - * - *
-     * Explanation of the warning generated.
-     * 
- * - * string text = 1; - * - * @return The bytes for text. - */ - @java.lang.Override - public com.google.protobuf.ByteString getTextBytes() { - java.lang.Object ref = text_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - text_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int PRIORITY_FIELD_NUMBER = 2; - private int priority_; - /** - * - * - *
-     * The priority for this warning.
-     * 
- * - * .google.devtools.cloudbuild.v1.Build.Warning.Priority priority = 2; - * - * @return The enum numeric value on the wire for priority. - */ - @java.lang.Override - public int getPriorityValue() { - return priority_; - } - /** - * - * - *
-     * The priority for this warning.
-     * 
- * - * .google.devtools.cloudbuild.v1.Build.Warning.Priority priority = 2; - * - * @return The priority. - */ - @java.lang.Override - public com.google.cloudbuild.v1.Build.Warning.Priority getPriority() { - @SuppressWarnings("deprecation") - com.google.cloudbuild.v1.Build.Warning.Priority result = - com.google.cloudbuild.v1.Build.Warning.Priority.valueOf(priority_); - return result == null ? com.google.cloudbuild.v1.Build.Warning.Priority.UNRECOGNIZED : result; - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(text_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, text_); - } - if (priority_ - != com.google.cloudbuild.v1.Build.Warning.Priority.PRIORITY_UNSPECIFIED.getNumber()) { - output.writeEnum(2, priority_); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(text_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, text_); - } - if (priority_ - != com.google.cloudbuild.v1.Build.Warning.Priority.PRIORITY_UNSPECIFIED.getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(2, priority_); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.Build.Warning)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.Build.Warning other = (com.google.cloudbuild.v1.Build.Warning) obj; - - if (!getText().equals(other.getText())) return false; - if (priority_ != other.priority_) return false; - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + TEXT_FIELD_NUMBER; - hash = (53 * hash) + getText().hashCode(); - hash = (37 * hash) + PRIORITY_FIELD_NUMBER; - hash = (53 * hash) + priority_; - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.Build.Warning parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.Build.Warning parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.Build.Warning parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.Build.Warning parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.Build.Warning parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.Build.Warning parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.Build.Warning parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.Build.Warning parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.Build.Warning parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.Build.Warning parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.Build.Warning parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.Build.Warning parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.Build.Warning prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-     * A non-fatal problem encountered during the execution of the build.
-     * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.Build.Warning} - */ - public static final class Builder - extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.Build.Warning) - com.google.cloudbuild.v1.Build.WarningOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Build_Warning_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Build_Warning_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.Build.Warning.class, - com.google.cloudbuild.v1.Build.Warning.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.Build.Warning.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - text_ = ""; - - priority_ = 0; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Build_Warning_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.Build.Warning getDefaultInstanceForType() { - return com.google.cloudbuild.v1.Build.Warning.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.Build.Warning build() { - com.google.cloudbuild.v1.Build.Warning result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.Build.Warning buildPartial() { - com.google.cloudbuild.v1.Build.Warning result = - new com.google.cloudbuild.v1.Build.Warning(this); - result.text_ = text_; - result.priority_ = priority_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, - java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.Build.Warning) { - return mergeFrom((com.google.cloudbuild.v1.Build.Warning) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.Build.Warning other) { - if (other == com.google.cloudbuild.v1.Build.Warning.getDefaultInstance()) return this; - if (!other.getText().isEmpty()) { - text_ = other.text_; - onChanged(); - } - if (other.priority_ != 0) { - setPriorityValue(other.getPriorityValue()); - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - text_ = input.readStringRequireUtf8(); - - break; - } // case 10 - case 16: - { - priority_ = input.readEnum(); - - break; - } // case 16 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private java.lang.Object text_ = ""; - /** - * - * - *
-       * Explanation of the warning generated.
-       * 
- * - * string text = 1; - * - * @return The text. - */ - public java.lang.String getText() { - java.lang.Object ref = text_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - text_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-       * Explanation of the warning generated.
-       * 
- * - * string text = 1; - * - * @return The bytes for text. - */ - public com.google.protobuf.ByteString getTextBytes() { - java.lang.Object ref = text_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - text_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-       * Explanation of the warning generated.
-       * 
- * - * string text = 1; - * - * @param value The text to set. - * @return This builder for chaining. - */ - public Builder setText(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - text_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * Explanation of the warning generated.
-       * 
- * - * string text = 1; - * - * @return This builder for chaining. - */ - public Builder clearText() { - - text_ = getDefaultInstance().getText(); - onChanged(); - return this; - } - /** - * - * - *
-       * Explanation of the warning generated.
-       * 
- * - * string text = 1; - * - * @param value The bytes for text to set. - * @return This builder for chaining. - */ - public Builder setTextBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - text_ = value; - onChanged(); - return this; - } - - private int priority_ = 0; - /** - * - * - *
-       * The priority for this warning.
-       * 
- * - * .google.devtools.cloudbuild.v1.Build.Warning.Priority priority = 2; - * - * @return The enum numeric value on the wire for priority. - */ - @java.lang.Override - public int getPriorityValue() { - return priority_; - } - /** - * - * - *
-       * The priority for this warning.
-       * 
- * - * .google.devtools.cloudbuild.v1.Build.Warning.Priority priority = 2; - * - * @param value The enum numeric value on the wire for priority to set. - * @return This builder for chaining. - */ - public Builder setPriorityValue(int value) { - - priority_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * The priority for this warning.
-       * 
- * - * .google.devtools.cloudbuild.v1.Build.Warning.Priority priority = 2; - * - * @return The priority. - */ - @java.lang.Override - public com.google.cloudbuild.v1.Build.Warning.Priority getPriority() { - @SuppressWarnings("deprecation") - com.google.cloudbuild.v1.Build.Warning.Priority result = - com.google.cloudbuild.v1.Build.Warning.Priority.valueOf(priority_); - return result == null - ? com.google.cloudbuild.v1.Build.Warning.Priority.UNRECOGNIZED - : result; - } - /** - * - * - *
-       * The priority for this warning.
-       * 
- * - * .google.devtools.cloudbuild.v1.Build.Warning.Priority priority = 2; - * - * @param value The priority to set. - * @return This builder for chaining. - */ - public Builder setPriority(com.google.cloudbuild.v1.Build.Warning.Priority value) { - if (value == null) { - throw new NullPointerException(); - } - - priority_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-       * The priority for this warning.
-       * 
- * - * .google.devtools.cloudbuild.v1.Build.Warning.Priority priority = 2; - * - * @return This builder for chaining. - */ - public Builder clearPriority() { - - priority_ = 0; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.Build.Warning) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.Build.Warning) - private static final com.google.cloudbuild.v1.Build.Warning DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.Build.Warning(); - } - - public static com.google.cloudbuild.v1.Build.Warning getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public Warning parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException() - .setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.Build.Warning getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - } - - public interface FailureInfoOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.Build.FailureInfo) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-     * The name of the failure.
-     * 
- * - * .google.devtools.cloudbuild.v1.Build.FailureInfo.FailureType type = 1; - * - * @return The enum numeric value on the wire for type. - */ - int getTypeValue(); - /** - * - * - *
-     * The name of the failure.
-     * 
- * - * .google.devtools.cloudbuild.v1.Build.FailureInfo.FailureType type = 1; - * - * @return The type. - */ - com.google.cloudbuild.v1.Build.FailureInfo.FailureType getType(); - - /** - * - * - *
-     * Explains the failure issue in more detail using hard-coded text.
-     * 
- * - * string detail = 2; - * - * @return The detail. - */ - java.lang.String getDetail(); - /** - * - * - *
-     * Explains the failure issue in more detail using hard-coded text.
-     * 
- * - * string detail = 2; - * - * @return The bytes for detail. - */ - com.google.protobuf.ByteString getDetailBytes(); - } - /** - * - * - *
-   * A fatal problem encountered during the execution of the build.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.Build.FailureInfo} - */ - public static final class FailureInfo extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.Build.FailureInfo) - FailureInfoOrBuilder { - private static final long serialVersionUID = 0L; - // Use FailureInfo.newBuilder() to construct. - private FailureInfo(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private FailureInfo() { - type_ = 0; - detail_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new FailureInfo(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Build_FailureInfo_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Build_FailureInfo_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.Build.FailureInfo.class, - com.google.cloudbuild.v1.Build.FailureInfo.Builder.class); - } - - /** - * - * - *
-     * The name of a fatal problem encountered during the execution of the
-     * build.
-     * 
- * - * Protobuf enum {@code google.devtools.cloudbuild.v1.Build.FailureInfo.FailureType} - */ - public enum FailureType implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
-       * Type unspecified
-       * 
- * - * FAILURE_TYPE_UNSPECIFIED = 0; - */ - FAILURE_TYPE_UNSPECIFIED(0), - /** - * - * - *
-       * Unable to push the image to the repository.
-       * 
- * - * PUSH_FAILED = 1; - */ - PUSH_FAILED(1), - /** - * - * - *
-       * Final image not found.
-       * 
- * - * PUSH_IMAGE_NOT_FOUND = 2; - */ - PUSH_IMAGE_NOT_FOUND(2), - /** - * - * - *
-       * Unauthorized push of the final image.
-       * 
- * - * PUSH_NOT_AUTHORIZED = 3; - */ - PUSH_NOT_AUTHORIZED(3), - /** - * - * - *
-       * Backend logging failures. Should retry.
-       * 
- * - * LOGGING_FAILURE = 4; - */ - LOGGING_FAILURE(4), - /** - * - * - *
-       * A build step has failed.
-       * 
- * - * USER_BUILD_STEP = 5; - */ - USER_BUILD_STEP(5), - /** - * - * - *
-       * The source fetching has failed.
-       * 
- * - * FETCH_SOURCE_FAILED = 6; - */ - FETCH_SOURCE_FAILED(6), - UNRECOGNIZED(-1), - ; - - /** - * - * - *
-       * Type unspecified
-       * 
- * - * FAILURE_TYPE_UNSPECIFIED = 0; - */ - public static final int FAILURE_TYPE_UNSPECIFIED_VALUE = 0; - /** - * - * - *
-       * Unable to push the image to the repository.
-       * 
- * - * PUSH_FAILED = 1; - */ - public static final int PUSH_FAILED_VALUE = 1; - /** - * - * - *
-       * Final image not found.
-       * 
- * - * PUSH_IMAGE_NOT_FOUND = 2; - */ - public static final int PUSH_IMAGE_NOT_FOUND_VALUE = 2; - /** - * - * - *
-       * Unauthorized push of the final image.
-       * 
- * - * PUSH_NOT_AUTHORIZED = 3; - */ - public static final int PUSH_NOT_AUTHORIZED_VALUE = 3; - /** - * - * - *
-       * Backend logging failures. Should retry.
-       * 
- * - * LOGGING_FAILURE = 4; - */ - public static final int LOGGING_FAILURE_VALUE = 4; - /** - * - * - *
-       * A build step has failed.
-       * 
- * - * USER_BUILD_STEP = 5; - */ - public static final int USER_BUILD_STEP_VALUE = 5; - /** - * - * - *
-       * The source fetching has failed.
-       * 
- * - * FETCH_SOURCE_FAILED = 6; - */ - public static final int FETCH_SOURCE_FAILED_VALUE = 6; - - public final int getNumber() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalArgumentException( - "Can't get the number of an unknown enum value."); - } - return value; - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static FailureType valueOf(int value) { - return forNumber(value); - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - */ - public static FailureType forNumber(int value) { - switch (value) { - case 0: - return FAILURE_TYPE_UNSPECIFIED; - case 1: - return PUSH_FAILED; - case 2: - return PUSH_IMAGE_NOT_FOUND; - case 3: - return PUSH_NOT_AUTHORIZED; - case 4: - return LOGGING_FAILURE; - case 5: - return USER_BUILD_STEP; - case 6: - return FETCH_SOURCE_FAILED; - default: - return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { - return internalValueMap; - } - - private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public FailureType findValueByNumber(int number) { - return FailureType.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalStateException( - "Can't get the descriptor of an unrecognized enum value."); - } - return getDescriptor().getValues().get(ordinal()); - } - - public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { - return getDescriptor(); - } - - public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return com.google.cloudbuild.v1.Build.FailureInfo.getDescriptor().getEnumTypes().get(0); - } - - private static final FailureType[] VALUES = values(); - - public static FailureType valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); - } - if (desc.getIndex() == -1) { - return UNRECOGNIZED; - } - return VALUES[desc.getIndex()]; - } - - private final int value; - - private FailureType(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:google.devtools.cloudbuild.v1.Build.FailureInfo.FailureType) - } - - public static final int TYPE_FIELD_NUMBER = 1; - private int type_; - /** - * - * - *
-     * The name of the failure.
-     * 
- * - * .google.devtools.cloudbuild.v1.Build.FailureInfo.FailureType type = 1; - * - * @return The enum numeric value on the wire for type. - */ - @java.lang.Override - public int getTypeValue() { - return type_; - } - /** - * - * - *
-     * The name of the failure.
-     * 
- * - * .google.devtools.cloudbuild.v1.Build.FailureInfo.FailureType type = 1; - * - * @return The type. - */ - @java.lang.Override - public com.google.cloudbuild.v1.Build.FailureInfo.FailureType getType() { - @SuppressWarnings("deprecation") - com.google.cloudbuild.v1.Build.FailureInfo.FailureType result = - com.google.cloudbuild.v1.Build.FailureInfo.FailureType.valueOf(type_); - return result == null - ? com.google.cloudbuild.v1.Build.FailureInfo.FailureType.UNRECOGNIZED - : result; - } - - public static final int DETAIL_FIELD_NUMBER = 2; - private volatile java.lang.Object detail_; - /** - * - * - *
-     * Explains the failure issue in more detail using hard-coded text.
-     * 
- * - * string detail = 2; - * - * @return The detail. - */ - @java.lang.Override - public java.lang.String getDetail() { - java.lang.Object ref = detail_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - detail_ = s; - return s; - } - } - /** - * - * - *
-     * Explains the failure issue in more detail using hard-coded text.
-     * 
- * - * string detail = 2; - * - * @return The bytes for detail. - */ - @java.lang.Override - public com.google.protobuf.ByteString getDetailBytes() { - java.lang.Object ref = detail_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - detail_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (type_ - != com.google.cloudbuild.v1.Build.FailureInfo.FailureType.FAILURE_TYPE_UNSPECIFIED - .getNumber()) { - output.writeEnum(1, type_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(detail_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, detail_); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (type_ - != com.google.cloudbuild.v1.Build.FailureInfo.FailureType.FAILURE_TYPE_UNSPECIFIED - .getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, type_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(detail_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, detail_); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.Build.FailureInfo)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.Build.FailureInfo other = - (com.google.cloudbuild.v1.Build.FailureInfo) obj; - - if (type_ != other.type_) return false; - if (!getDetail().equals(other.getDetail())) return false; - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + TYPE_FIELD_NUMBER; - hash = (53 * hash) + type_; - hash = (37 * hash) + DETAIL_FIELD_NUMBER; - hash = (53 * hash) + getDetail().hashCode(); - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.Build.FailureInfo parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.Build.FailureInfo parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.Build.FailureInfo parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.Build.FailureInfo parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.Build.FailureInfo parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.Build.FailureInfo parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.Build.FailureInfo parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.Build.FailureInfo parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.Build.FailureInfo parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.Build.FailureInfo parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.Build.FailureInfo parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.Build.FailureInfo parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.Build.FailureInfo prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-     * A fatal problem encountered during the execution of the build.
-     * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.Build.FailureInfo} - */ - public static final class Builder - extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.Build.FailureInfo) - com.google.cloudbuild.v1.Build.FailureInfoOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Build_FailureInfo_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Build_FailureInfo_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.Build.FailureInfo.class, - com.google.cloudbuild.v1.Build.FailureInfo.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.Build.FailureInfo.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - type_ = 0; - - detail_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Build_FailureInfo_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.Build.FailureInfo getDefaultInstanceForType() { - return com.google.cloudbuild.v1.Build.FailureInfo.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.Build.FailureInfo build() { - com.google.cloudbuild.v1.Build.FailureInfo result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.Build.FailureInfo buildPartial() { - com.google.cloudbuild.v1.Build.FailureInfo result = - new com.google.cloudbuild.v1.Build.FailureInfo(this); - result.type_ = type_; - result.detail_ = detail_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, - java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.Build.FailureInfo) { - return mergeFrom((com.google.cloudbuild.v1.Build.FailureInfo) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.Build.FailureInfo other) { - if (other == com.google.cloudbuild.v1.Build.FailureInfo.getDefaultInstance()) return this; - if (other.type_ != 0) { - setTypeValue(other.getTypeValue()); - } - if (!other.getDetail().isEmpty()) { - detail_ = other.detail_; - onChanged(); - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 8: - { - type_ = input.readEnum(); - - break; - } // case 8 - case 18: - { - detail_ = input.readStringRequireUtf8(); - - break; - } // case 18 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private int type_ = 0; - /** - * - * - *
-       * The name of the failure.
-       * 
- * - * .google.devtools.cloudbuild.v1.Build.FailureInfo.FailureType type = 1; - * - * @return The enum numeric value on the wire for type. - */ - @java.lang.Override - public int getTypeValue() { - return type_; - } - /** - * - * - *
-       * The name of the failure.
-       * 
- * - * .google.devtools.cloudbuild.v1.Build.FailureInfo.FailureType type = 1; - * - * @param value The enum numeric value on the wire for type to set. - * @return This builder for chaining. - */ - public Builder setTypeValue(int value) { - - type_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * The name of the failure.
-       * 
- * - * .google.devtools.cloudbuild.v1.Build.FailureInfo.FailureType type = 1; - * - * @return The type. - */ - @java.lang.Override - public com.google.cloudbuild.v1.Build.FailureInfo.FailureType getType() { - @SuppressWarnings("deprecation") - com.google.cloudbuild.v1.Build.FailureInfo.FailureType result = - com.google.cloudbuild.v1.Build.FailureInfo.FailureType.valueOf(type_); - return result == null - ? com.google.cloudbuild.v1.Build.FailureInfo.FailureType.UNRECOGNIZED - : result; - } - /** - * - * - *
-       * The name of the failure.
-       * 
- * - * .google.devtools.cloudbuild.v1.Build.FailureInfo.FailureType type = 1; - * - * @param value The type to set. - * @return This builder for chaining. - */ - public Builder setType(com.google.cloudbuild.v1.Build.FailureInfo.FailureType value) { - if (value == null) { - throw new NullPointerException(); - } - - type_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-       * The name of the failure.
-       * 
- * - * .google.devtools.cloudbuild.v1.Build.FailureInfo.FailureType type = 1; - * - * @return This builder for chaining. - */ - public Builder clearType() { - - type_ = 0; - onChanged(); - return this; - } - - private java.lang.Object detail_ = ""; - /** - * - * - *
-       * Explains the failure issue in more detail using hard-coded text.
-       * 
- * - * string detail = 2; - * - * @return The detail. - */ - public java.lang.String getDetail() { - java.lang.Object ref = detail_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - detail_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-       * Explains the failure issue in more detail using hard-coded text.
-       * 
- * - * string detail = 2; - * - * @return The bytes for detail. - */ - public com.google.protobuf.ByteString getDetailBytes() { - java.lang.Object ref = detail_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - detail_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-       * Explains the failure issue in more detail using hard-coded text.
-       * 
- * - * string detail = 2; - * - * @param value The detail to set. - * @return This builder for chaining. - */ - public Builder setDetail(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - detail_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * Explains the failure issue in more detail using hard-coded text.
-       * 
- * - * string detail = 2; - * - * @return This builder for chaining. - */ - public Builder clearDetail() { - - detail_ = getDefaultInstance().getDetail(); - onChanged(); - return this; - } - /** - * - * - *
-       * Explains the failure issue in more detail using hard-coded text.
-       * 
- * - * string detail = 2; - * - * @param value The bytes for detail to set. - * @return This builder for chaining. - */ - public Builder setDetailBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - detail_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.Build.FailureInfo) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.Build.FailureInfo) - private static final com.google.cloudbuild.v1.Build.FailureInfo DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.Build.FailureInfo(); - } - - public static com.google.cloudbuild.v1.Build.FailureInfo getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public FailureInfo parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException() - .setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.Build.FailureInfo getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - } - - public static final int NAME_FIELD_NUMBER = 45; - private volatile java.lang.Object name_; - /** - * - * - *
-   * Output only. The 'Build' name with format:
-   * `projects/{project}/locations/{location}/builds/{build}`, where {build}
-   * is a unique identifier generated by the service.
-   * 
- * - * string name = 45 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The name. - */ - @java.lang.Override - public java.lang.String getName() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - name_ = s; - return s; - } - } - /** - * - * - *
-   * Output only. The 'Build' name with format:
-   * `projects/{project}/locations/{location}/builds/{build}`, where {build}
-   * is a unique identifier generated by the service.
-   * 
- * - * string name = 45 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The bytes for name. - */ - @java.lang.Override - public com.google.protobuf.ByteString getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int ID_FIELD_NUMBER = 1; - private volatile java.lang.Object id_; - /** - * - * - *
-   * Output only. Unique identifier of the build.
-   * 
- * - * string id = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The id. - */ - @java.lang.Override - public java.lang.String getId() { - java.lang.Object ref = id_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - id_ = s; - return s; - } - } - /** - * - * - *
-   * Output only. Unique identifier of the build.
-   * 
- * - * string id = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The bytes for id. - */ - @java.lang.Override - public com.google.protobuf.ByteString getIdBytes() { - java.lang.Object ref = id_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - id_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int PROJECT_ID_FIELD_NUMBER = 16; - private volatile java.lang.Object projectId_; - /** - * - * - *
-   * Output only. ID of the project.
-   * 
- * - * string project_id = 16 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The projectId. - */ - @java.lang.Override - public java.lang.String getProjectId() { - java.lang.Object ref = projectId_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - projectId_ = s; - return s; - } - } - /** - * - * - *
-   * Output only. ID of the project.
-   * 
- * - * string project_id = 16 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The bytes for projectId. - */ - @java.lang.Override - public com.google.protobuf.ByteString getProjectIdBytes() { - java.lang.Object ref = projectId_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - projectId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int STATUS_FIELD_NUMBER = 2; - private int status_; - /** - * - * - *
-   * Output only. Status of the build.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.Build.Status status = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The enum numeric value on the wire for status. - */ - @java.lang.Override - public int getStatusValue() { - return status_; - } - /** - * - * - *
-   * Output only. Status of the build.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.Build.Status status = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The status. - */ - @java.lang.Override - public com.google.cloudbuild.v1.Build.Status getStatus() { - @SuppressWarnings("deprecation") - com.google.cloudbuild.v1.Build.Status result = - com.google.cloudbuild.v1.Build.Status.valueOf(status_); - return result == null ? com.google.cloudbuild.v1.Build.Status.UNRECOGNIZED : result; - } - - public static final int STATUS_DETAIL_FIELD_NUMBER = 24; - private volatile java.lang.Object statusDetail_; - /** - * - * - *
-   * Output only. Customer-readable message about the current status.
-   * 
- * - * string status_detail = 24 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The statusDetail. - */ - @java.lang.Override - public java.lang.String getStatusDetail() { - java.lang.Object ref = statusDetail_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - statusDetail_ = s; - return s; - } - } - /** - * - * - *
-   * Output only. Customer-readable message about the current status.
-   * 
- * - * string status_detail = 24 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The bytes for statusDetail. - */ - @java.lang.Override - public com.google.protobuf.ByteString getStatusDetailBytes() { - java.lang.Object ref = statusDetail_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - statusDetail_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int SOURCE_FIELD_NUMBER = 3; - private com.google.cloudbuild.v1.Source source_; - /** - * - * - *
-   * The location of the source files to build.
-   * 
- * - * .google.devtools.cloudbuild.v1.Source source = 3; - * - * @return Whether the source field is set. - */ - @java.lang.Override - public boolean hasSource() { - return source_ != null; - } - /** - * - * - *
-   * The location of the source files to build.
-   * 
- * - * .google.devtools.cloudbuild.v1.Source source = 3; - * - * @return The source. - */ - @java.lang.Override - public com.google.cloudbuild.v1.Source getSource() { - return source_ == null ? com.google.cloudbuild.v1.Source.getDefaultInstance() : source_; - } - /** - * - * - *
-   * The location of the source files to build.
-   * 
- * - * .google.devtools.cloudbuild.v1.Source source = 3; - */ - @java.lang.Override - public com.google.cloudbuild.v1.SourceOrBuilder getSourceOrBuilder() { - return getSource(); - } - - public static final int STEPS_FIELD_NUMBER = 11; - private java.util.List steps_; - /** - * - * - *
-   * Required. The operations to be performed on the workspace.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildStep steps = 11; - */ - @java.lang.Override - public java.util.List getStepsList() { - return steps_; - } - /** - * - * - *
-   * Required. The operations to be performed on the workspace.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildStep steps = 11; - */ - @java.lang.Override - public java.util.List - getStepsOrBuilderList() { - return steps_; - } - /** - * - * - *
-   * Required. The operations to be performed on the workspace.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildStep steps = 11; - */ - @java.lang.Override - public int getStepsCount() { - return steps_.size(); - } - /** - * - * - *
-   * Required. The operations to be performed on the workspace.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildStep steps = 11; - */ - @java.lang.Override - public com.google.cloudbuild.v1.BuildStep getSteps(int index) { - return steps_.get(index); - } - /** - * - * - *
-   * Required. The operations to be performed on the workspace.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildStep steps = 11; - */ - @java.lang.Override - public com.google.cloudbuild.v1.BuildStepOrBuilder getStepsOrBuilder(int index) { - return steps_.get(index); - } - - public static final int RESULTS_FIELD_NUMBER = 10; - private com.google.cloudbuild.v1.Results results_; - /** - * - * - *
-   * Output only. Results of the build.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.Results results = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return Whether the results field is set. - */ - @java.lang.Override - public boolean hasResults() { - return results_ != null; - } - /** - * - * - *
-   * Output only. Results of the build.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.Results results = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The results. - */ - @java.lang.Override - public com.google.cloudbuild.v1.Results getResults() { - return results_ == null ? com.google.cloudbuild.v1.Results.getDefaultInstance() : results_; - } - /** - * - * - *
-   * Output only. Results of the build.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.Results results = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - @java.lang.Override - public com.google.cloudbuild.v1.ResultsOrBuilder getResultsOrBuilder() { - return getResults(); - } - - public static final int CREATE_TIME_FIELD_NUMBER = 6; - private com.google.protobuf.Timestamp createTime_; - /** - * - * - *
-   * Output only. Time at which the request to create the build was received.
-   * 
- * - * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return Whether the createTime field is set. - */ - @java.lang.Override - public boolean hasCreateTime() { - return createTime_ != null; - } - /** - * - * - *
-   * Output only. Time at which the request to create the build was received.
-   * 
- * - * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The createTime. - */ - @java.lang.Override - public com.google.protobuf.Timestamp getCreateTime() { - return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; - } - /** - * - * - *
-   * Output only. Time at which the request to create the build was received.
-   * 
- * - * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - @java.lang.Override - public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { - return getCreateTime(); - } - - public static final int START_TIME_FIELD_NUMBER = 7; - private com.google.protobuf.Timestamp startTime_; - /** - * - * - *
-   * Output only. Time at which execution of the build was started.
-   * 
- * - * .google.protobuf.Timestamp start_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return Whether the startTime field is set. - */ - @java.lang.Override - public boolean hasStartTime() { - return startTime_ != null; - } - /** - * - * - *
-   * Output only. Time at which execution of the build was started.
-   * 
- * - * .google.protobuf.Timestamp start_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The startTime. - */ - @java.lang.Override - public com.google.protobuf.Timestamp getStartTime() { - return startTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : startTime_; - } - /** - * - * - *
-   * Output only. Time at which execution of the build was started.
-   * 
- * - * .google.protobuf.Timestamp start_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - @java.lang.Override - public com.google.protobuf.TimestampOrBuilder getStartTimeOrBuilder() { - return getStartTime(); - } - - public static final int FINISH_TIME_FIELD_NUMBER = 8; - private com.google.protobuf.Timestamp finishTime_; - /** - * - * - *
-   * Output only. Time at which execution of the build was finished.
-   * The difference between finish_time and start_time is the duration of the
-   * build's execution.
-   * 
- * - * .google.protobuf.Timestamp finish_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return Whether the finishTime field is set. - */ - @java.lang.Override - public boolean hasFinishTime() { - return finishTime_ != null; - } - /** - * - * - *
-   * Output only. Time at which execution of the build was finished.
-   * The difference between finish_time and start_time is the duration of the
-   * build's execution.
-   * 
- * - * .google.protobuf.Timestamp finish_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The finishTime. - */ - @java.lang.Override - public com.google.protobuf.Timestamp getFinishTime() { - return finishTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : finishTime_; - } - /** - * - * - *
-   * Output only. Time at which execution of the build was finished.
-   * The difference between finish_time and start_time is the duration of the
-   * build's execution.
-   * 
- * - * .google.protobuf.Timestamp finish_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - @java.lang.Override - public com.google.protobuf.TimestampOrBuilder getFinishTimeOrBuilder() { - return getFinishTime(); - } - - public static final int TIMEOUT_FIELD_NUMBER = 12; - private com.google.protobuf.Duration timeout_; - /** - * - * - *
-   * Amount of time that this build should be allowed to run, to second
-   * granularity. If this amount of time elapses, work on the build will cease
-   * and the build status will be `TIMEOUT`.
-   * `timeout` starts ticking from `startTime`.
-   * Default time is ten minutes.
-   * 
- * - * .google.protobuf.Duration timeout = 12; - * - * @return Whether the timeout field is set. - */ - @java.lang.Override - public boolean hasTimeout() { - return timeout_ != null; - } - /** - * - * - *
-   * Amount of time that this build should be allowed to run, to second
-   * granularity. If this amount of time elapses, work on the build will cease
-   * and the build status will be `TIMEOUT`.
-   * `timeout` starts ticking from `startTime`.
-   * Default time is ten minutes.
-   * 
- * - * .google.protobuf.Duration timeout = 12; - * - * @return The timeout. - */ - @java.lang.Override - public com.google.protobuf.Duration getTimeout() { - return timeout_ == null ? com.google.protobuf.Duration.getDefaultInstance() : timeout_; - } - /** - * - * - *
-   * Amount of time that this build should be allowed to run, to second
-   * granularity. If this amount of time elapses, work on the build will cease
-   * and the build status will be `TIMEOUT`.
-   * `timeout` starts ticking from `startTime`.
-   * Default time is ten minutes.
-   * 
- * - * .google.protobuf.Duration timeout = 12; - */ - @java.lang.Override - public com.google.protobuf.DurationOrBuilder getTimeoutOrBuilder() { - return getTimeout(); - } - - public static final int IMAGES_FIELD_NUMBER = 13; - private com.google.protobuf.LazyStringList images_; - /** - * - * - *
-   * A list of images to be pushed upon the successful completion of all build
-   * steps.
-   * The images are pushed using the builder service account's credentials.
-   * The digests of the pushed images will be stored in the `Build` resource's
-   * results field.
-   * If any of the images fail to be pushed, the build status is marked
-   * `FAILURE`.
-   * 
- * - * repeated string images = 13; - * - * @return A list containing the images. - */ - public com.google.protobuf.ProtocolStringList getImagesList() { - return images_; - } - /** - * - * - *
-   * A list of images to be pushed upon the successful completion of all build
-   * steps.
-   * The images are pushed using the builder service account's credentials.
-   * The digests of the pushed images will be stored in the `Build` resource's
-   * results field.
-   * If any of the images fail to be pushed, the build status is marked
-   * `FAILURE`.
-   * 
- * - * repeated string images = 13; - * - * @return The count of images. - */ - public int getImagesCount() { - return images_.size(); - } - /** - * - * - *
-   * A list of images to be pushed upon the successful completion of all build
-   * steps.
-   * The images are pushed using the builder service account's credentials.
-   * The digests of the pushed images will be stored in the `Build` resource's
-   * results field.
-   * If any of the images fail to be pushed, the build status is marked
-   * `FAILURE`.
-   * 
- * - * repeated string images = 13; - * - * @param index The index of the element to return. - * @return The images at the given index. - */ - public java.lang.String getImages(int index) { - return images_.get(index); - } - /** - * - * - *
-   * A list of images to be pushed upon the successful completion of all build
-   * steps.
-   * The images are pushed using the builder service account's credentials.
-   * The digests of the pushed images will be stored in the `Build` resource's
-   * results field.
-   * If any of the images fail to be pushed, the build status is marked
-   * `FAILURE`.
-   * 
- * - * repeated string images = 13; - * - * @param index The index of the value to return. - * @return The bytes of the images at the given index. - */ - public com.google.protobuf.ByteString getImagesBytes(int index) { - return images_.getByteString(index); - } - - public static final int QUEUE_TTL_FIELD_NUMBER = 40; - private com.google.protobuf.Duration queueTtl_; - /** - * - * - *
-   * TTL in queue for this build. If provided and the build is enqueued longer
-   * than this value, the build will expire and the build status will be
-   * `EXPIRED`.
-   * The TTL starts ticking from create_time.
-   * 
- * - * .google.protobuf.Duration queue_ttl = 40; - * - * @return Whether the queueTtl field is set. - */ - @java.lang.Override - public boolean hasQueueTtl() { - return queueTtl_ != null; - } - /** - * - * - *
-   * TTL in queue for this build. If provided and the build is enqueued longer
-   * than this value, the build will expire and the build status will be
-   * `EXPIRED`.
-   * The TTL starts ticking from create_time.
-   * 
- * - * .google.protobuf.Duration queue_ttl = 40; - * - * @return The queueTtl. - */ - @java.lang.Override - public com.google.protobuf.Duration getQueueTtl() { - return queueTtl_ == null ? com.google.protobuf.Duration.getDefaultInstance() : queueTtl_; - } - /** - * - * - *
-   * TTL in queue for this build. If provided and the build is enqueued longer
-   * than this value, the build will expire and the build status will be
-   * `EXPIRED`.
-   * The TTL starts ticking from create_time.
-   * 
- * - * .google.protobuf.Duration queue_ttl = 40; - */ - @java.lang.Override - public com.google.protobuf.DurationOrBuilder getQueueTtlOrBuilder() { - return getQueueTtl(); - } - - public static final int ARTIFACTS_FIELD_NUMBER = 37; - private com.google.cloudbuild.v1.Artifacts artifacts_; - /** - * - * - *
-   * Artifacts produced by the build that should be uploaded upon
-   * successful completion of all build steps.
-   * 
- * - * .google.devtools.cloudbuild.v1.Artifacts artifacts = 37; - * - * @return Whether the artifacts field is set. - */ - @java.lang.Override - public boolean hasArtifacts() { - return artifacts_ != null; - } - /** - * - * - *
-   * Artifacts produced by the build that should be uploaded upon
-   * successful completion of all build steps.
-   * 
- * - * .google.devtools.cloudbuild.v1.Artifacts artifacts = 37; - * - * @return The artifacts. - */ - @java.lang.Override - public com.google.cloudbuild.v1.Artifacts getArtifacts() { - return artifacts_ == null - ? com.google.cloudbuild.v1.Artifacts.getDefaultInstance() - : artifacts_; - } - /** - * - * - *
-   * Artifacts produced by the build that should be uploaded upon
-   * successful completion of all build steps.
-   * 
- * - * .google.devtools.cloudbuild.v1.Artifacts artifacts = 37; - */ - @java.lang.Override - public com.google.cloudbuild.v1.ArtifactsOrBuilder getArtifactsOrBuilder() { - return getArtifacts(); - } - - public static final int LOGS_BUCKET_FIELD_NUMBER = 19; - private volatile java.lang.Object logsBucket_; - /** - * - * - *
-   * Google Cloud Storage bucket where logs should be written (see
-   * [Bucket Name
-   * Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)).
-   * Logs file names will be of the format `${logs_bucket}/log-${build_id}.txt`.
-   * 
- * - * string logs_bucket = 19; - * - * @return The logsBucket. - */ - @java.lang.Override - public java.lang.String getLogsBucket() { - java.lang.Object ref = logsBucket_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - logsBucket_ = s; - return s; - } - } - /** - * - * - *
-   * Google Cloud Storage bucket where logs should be written (see
-   * [Bucket Name
-   * Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)).
-   * Logs file names will be of the format `${logs_bucket}/log-${build_id}.txt`.
-   * 
- * - * string logs_bucket = 19; - * - * @return The bytes for logsBucket. - */ - @java.lang.Override - public com.google.protobuf.ByteString getLogsBucketBytes() { - java.lang.Object ref = logsBucket_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - logsBucket_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int SOURCE_PROVENANCE_FIELD_NUMBER = 21; - private com.google.cloudbuild.v1.SourceProvenance sourceProvenance_; - /** - * - * - *
-   * Output only. A permanent fixed identifier for source.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.SourceProvenance source_provenance = 21 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return Whether the sourceProvenance field is set. - */ - @java.lang.Override - public boolean hasSourceProvenance() { - return sourceProvenance_ != null; - } - /** - * - * - *
-   * Output only. A permanent fixed identifier for source.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.SourceProvenance source_provenance = 21 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The sourceProvenance. - */ - @java.lang.Override - public com.google.cloudbuild.v1.SourceProvenance getSourceProvenance() { - return sourceProvenance_ == null - ? com.google.cloudbuild.v1.SourceProvenance.getDefaultInstance() - : sourceProvenance_; - } - /** - * - * - *
-   * Output only. A permanent fixed identifier for source.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.SourceProvenance source_provenance = 21 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - @java.lang.Override - public com.google.cloudbuild.v1.SourceProvenanceOrBuilder getSourceProvenanceOrBuilder() { - return getSourceProvenance(); - } - - public static final int BUILD_TRIGGER_ID_FIELD_NUMBER = 22; - private volatile java.lang.Object buildTriggerId_; - /** - * - * - *
-   * Output only. The ID of the `BuildTrigger` that triggered this build, if it
-   * was triggered automatically.
-   * 
- * - * string build_trigger_id = 22 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The buildTriggerId. - */ - @java.lang.Override - public java.lang.String getBuildTriggerId() { - java.lang.Object ref = buildTriggerId_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - buildTriggerId_ = s; - return s; - } - } - /** - * - * - *
-   * Output only. The ID of the `BuildTrigger` that triggered this build, if it
-   * was triggered automatically.
-   * 
- * - * string build_trigger_id = 22 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The bytes for buildTriggerId. - */ - @java.lang.Override - public com.google.protobuf.ByteString getBuildTriggerIdBytes() { - java.lang.Object ref = buildTriggerId_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - buildTriggerId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int OPTIONS_FIELD_NUMBER = 23; - private com.google.cloudbuild.v1.BuildOptions options_; - /** - * - * - *
-   * Special options for this build.
-   * 
- * - * .google.devtools.cloudbuild.v1.BuildOptions options = 23; - * - * @return Whether the options field is set. - */ - @java.lang.Override - public boolean hasOptions() { - return options_ != null; - } - /** - * - * - *
-   * Special options for this build.
-   * 
- * - * .google.devtools.cloudbuild.v1.BuildOptions options = 23; - * - * @return The options. - */ - @java.lang.Override - public com.google.cloudbuild.v1.BuildOptions getOptions() { - return options_ == null ? com.google.cloudbuild.v1.BuildOptions.getDefaultInstance() : options_; - } - /** - * - * - *
-   * Special options for this build.
-   * 
- * - * .google.devtools.cloudbuild.v1.BuildOptions options = 23; - */ - @java.lang.Override - public com.google.cloudbuild.v1.BuildOptionsOrBuilder getOptionsOrBuilder() { - return getOptions(); - } - - public static final int LOG_URL_FIELD_NUMBER = 25; - private volatile java.lang.Object logUrl_; - /** - * - * - *
-   * Output only. URL to logs for this build in Google Cloud Console.
-   * 
- * - * string log_url = 25 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The logUrl. - */ - @java.lang.Override - public java.lang.String getLogUrl() { - java.lang.Object ref = logUrl_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - logUrl_ = s; - return s; - } - } - /** - * - * - *
-   * Output only. URL to logs for this build in Google Cloud Console.
-   * 
- * - * string log_url = 25 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The bytes for logUrl. - */ - @java.lang.Override - public com.google.protobuf.ByteString getLogUrlBytes() { - java.lang.Object ref = logUrl_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - logUrl_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int SUBSTITUTIONS_FIELD_NUMBER = 29; - - private static final class SubstitutionsDefaultEntryHolder { - static final com.google.protobuf.MapEntry defaultEntry = - com.google.protobuf.MapEntry.newDefaultInstance( - com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Build_SubstitutionsEntry_descriptor, - com.google.protobuf.WireFormat.FieldType.STRING, - "", - com.google.protobuf.WireFormat.FieldType.STRING, - ""); - } - - private com.google.protobuf.MapField substitutions_; - - private com.google.protobuf.MapField - internalGetSubstitutions() { - if (substitutions_ == null) { - return com.google.protobuf.MapField.emptyMapField( - SubstitutionsDefaultEntryHolder.defaultEntry); - } - return substitutions_; - } - - public int getSubstitutionsCount() { - return internalGetSubstitutions().getMap().size(); - } - /** - * - * - *
-   * Substitutions data for `Build` resource.
-   * 
- * - * map<string, string> substitutions = 29; - */ - @java.lang.Override - public boolean containsSubstitutions(java.lang.String key) { - if (key == null) { - throw new NullPointerException("map key"); - } - return internalGetSubstitutions().getMap().containsKey(key); - } - /** Use {@link #getSubstitutionsMap()} instead. */ - @java.lang.Override - @java.lang.Deprecated - public java.util.Map getSubstitutions() { - return getSubstitutionsMap(); - } - /** - * - * - *
-   * Substitutions data for `Build` resource.
-   * 
- * - * map<string, string> substitutions = 29; - */ - @java.lang.Override - public java.util.Map getSubstitutionsMap() { - return internalGetSubstitutions().getMap(); - } - /** - * - * - *
-   * Substitutions data for `Build` resource.
-   * 
- * - * map<string, string> substitutions = 29; - */ - @java.lang.Override - public java.lang.String getSubstitutionsOrDefault( - java.lang.String key, java.lang.String defaultValue) { - if (key == null) { - throw new NullPointerException("map key"); - } - java.util.Map map = internalGetSubstitutions().getMap(); - return map.containsKey(key) ? map.get(key) : defaultValue; - } - /** - * - * - *
-   * Substitutions data for `Build` resource.
-   * 
- * - * map<string, string> substitutions = 29; - */ - @java.lang.Override - public java.lang.String getSubstitutionsOrThrow(java.lang.String key) { - if (key == null) { - throw new NullPointerException("map key"); - } - java.util.Map map = internalGetSubstitutions().getMap(); - if (!map.containsKey(key)) { - throw new java.lang.IllegalArgumentException(); - } - return map.get(key); - } - - public static final int TAGS_FIELD_NUMBER = 31; - private com.google.protobuf.LazyStringList tags_; - /** - * - * - *
-   * Tags for annotation of a `Build`. These are not docker tags.
-   * 
- * - * repeated string tags = 31; - * - * @return A list containing the tags. - */ - public com.google.protobuf.ProtocolStringList getTagsList() { - return tags_; - } - /** - * - * - *
-   * Tags for annotation of a `Build`. These are not docker tags.
-   * 
- * - * repeated string tags = 31; - * - * @return The count of tags. - */ - public int getTagsCount() { - return tags_.size(); - } - /** - * - * - *
-   * Tags for annotation of a `Build`. These are not docker tags.
-   * 
- * - * repeated string tags = 31; - * - * @param index The index of the element to return. - * @return The tags at the given index. - */ - public java.lang.String getTags(int index) { - return tags_.get(index); - } - /** - * - * - *
-   * Tags for annotation of a `Build`. These are not docker tags.
-   * 
- * - * repeated string tags = 31; - * - * @param index The index of the value to return. - * @return The bytes of the tags at the given index. - */ - public com.google.protobuf.ByteString getTagsBytes(int index) { - return tags_.getByteString(index); - } - - public static final int SECRETS_FIELD_NUMBER = 32; - private java.util.List secrets_; - /** - * - * - *
-   * Secrets to decrypt using Cloud Key Management Service.
-   * Note: Secret Manager is the recommended technique
-   * for managing sensitive data with Cloud Build. Use `available_secrets` to
-   * configure builds to access secrets from Secret Manager. For instructions,
-   * see: https://cloud.google.com/cloud-build/docs/securing-builds/use-secrets
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Secret secrets = 32; - */ - @java.lang.Override - public java.util.List getSecretsList() { - return secrets_; - } - /** - * - * - *
-   * Secrets to decrypt using Cloud Key Management Service.
-   * Note: Secret Manager is the recommended technique
-   * for managing sensitive data with Cloud Build. Use `available_secrets` to
-   * configure builds to access secrets from Secret Manager. For instructions,
-   * see: https://cloud.google.com/cloud-build/docs/securing-builds/use-secrets
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Secret secrets = 32; - */ - @java.lang.Override - public java.util.List - getSecretsOrBuilderList() { - return secrets_; - } - /** - * - * - *
-   * Secrets to decrypt using Cloud Key Management Service.
-   * Note: Secret Manager is the recommended technique
-   * for managing sensitive data with Cloud Build. Use `available_secrets` to
-   * configure builds to access secrets from Secret Manager. For instructions,
-   * see: https://cloud.google.com/cloud-build/docs/securing-builds/use-secrets
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Secret secrets = 32; - */ - @java.lang.Override - public int getSecretsCount() { - return secrets_.size(); - } - /** - * - * - *
-   * Secrets to decrypt using Cloud Key Management Service.
-   * Note: Secret Manager is the recommended technique
-   * for managing sensitive data with Cloud Build. Use `available_secrets` to
-   * configure builds to access secrets from Secret Manager. For instructions,
-   * see: https://cloud.google.com/cloud-build/docs/securing-builds/use-secrets
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Secret secrets = 32; - */ - @java.lang.Override - public com.google.cloudbuild.v1.Secret getSecrets(int index) { - return secrets_.get(index); - } - /** - * - * - *
-   * Secrets to decrypt using Cloud Key Management Service.
-   * Note: Secret Manager is the recommended technique
-   * for managing sensitive data with Cloud Build. Use `available_secrets` to
-   * configure builds to access secrets from Secret Manager. For instructions,
-   * see: https://cloud.google.com/cloud-build/docs/securing-builds/use-secrets
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Secret secrets = 32; - */ - @java.lang.Override - public com.google.cloudbuild.v1.SecretOrBuilder getSecretsOrBuilder(int index) { - return secrets_.get(index); - } - - public static final int TIMING_FIELD_NUMBER = 33; - - private static final class TimingDefaultEntryHolder { - static final com.google.protobuf.MapEntry - defaultEntry = - com.google.protobuf.MapEntry - .newDefaultInstance( - com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Build_TimingEntry_descriptor, - com.google.protobuf.WireFormat.FieldType.STRING, - "", - com.google.protobuf.WireFormat.FieldType.MESSAGE, - com.google.cloudbuild.v1.TimeSpan.getDefaultInstance()); - } - - private com.google.protobuf.MapField timing_; - - private com.google.protobuf.MapField - internalGetTiming() { - if (timing_ == null) { - return com.google.protobuf.MapField.emptyMapField(TimingDefaultEntryHolder.defaultEntry); - } - return timing_; - } - - public int getTimingCount() { - return internalGetTiming().getMap().size(); - } - /** - * - * - *
-   * Output only. Stores timing information for phases of the build. Valid keys
-   * are:
-   * * BUILD: time to execute all build steps.
-   * * PUSH: time to push all specified images.
-   * * FETCHSOURCE: time to fetch source.
-   * * SETUPBUILD: time to set up build.
-   * If the build does not specify source or images,
-   * these keys will not be included.
-   * 
- * - * - * map<string, .google.devtools.cloudbuild.v1.TimeSpan> timing = 33 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - @java.lang.Override - public boolean containsTiming(java.lang.String key) { - if (key == null) { - throw new NullPointerException("map key"); - } - return internalGetTiming().getMap().containsKey(key); - } - /** Use {@link #getTimingMap()} instead. */ - @java.lang.Override - @java.lang.Deprecated - public java.util.Map getTiming() { - return getTimingMap(); - } - /** - * - * - *
-   * Output only. Stores timing information for phases of the build. Valid keys
-   * are:
-   * * BUILD: time to execute all build steps.
-   * * PUSH: time to push all specified images.
-   * * FETCHSOURCE: time to fetch source.
-   * * SETUPBUILD: time to set up build.
-   * If the build does not specify source or images,
-   * these keys will not be included.
-   * 
- * - * - * map<string, .google.devtools.cloudbuild.v1.TimeSpan> timing = 33 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - @java.lang.Override - public java.util.Map getTimingMap() { - return internalGetTiming().getMap(); - } - /** - * - * - *
-   * Output only. Stores timing information for phases of the build. Valid keys
-   * are:
-   * * BUILD: time to execute all build steps.
-   * * PUSH: time to push all specified images.
-   * * FETCHSOURCE: time to fetch source.
-   * * SETUPBUILD: time to set up build.
-   * If the build does not specify source or images,
-   * these keys will not be included.
-   * 
- * - * - * map<string, .google.devtools.cloudbuild.v1.TimeSpan> timing = 33 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - @java.lang.Override - public com.google.cloudbuild.v1.TimeSpan getTimingOrDefault( - java.lang.String key, com.google.cloudbuild.v1.TimeSpan defaultValue) { - if (key == null) { - throw new NullPointerException("map key"); - } - java.util.Map map = - internalGetTiming().getMap(); - return map.containsKey(key) ? map.get(key) : defaultValue; - } - /** - * - * - *
-   * Output only. Stores timing information for phases of the build. Valid keys
-   * are:
-   * * BUILD: time to execute all build steps.
-   * * PUSH: time to push all specified images.
-   * * FETCHSOURCE: time to fetch source.
-   * * SETUPBUILD: time to set up build.
-   * If the build does not specify source or images,
-   * these keys will not be included.
-   * 
- * - * - * map<string, .google.devtools.cloudbuild.v1.TimeSpan> timing = 33 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - @java.lang.Override - public com.google.cloudbuild.v1.TimeSpan getTimingOrThrow(java.lang.String key) { - if (key == null) { - throw new NullPointerException("map key"); - } - java.util.Map map = - internalGetTiming().getMap(); - if (!map.containsKey(key)) { - throw new java.lang.IllegalArgumentException(); - } - return map.get(key); - } - - public static final int APPROVAL_FIELD_NUMBER = 44; - private com.google.cloudbuild.v1.BuildApproval approval_; - /** - * - * - *
-   * Output only. Describes this build's approval configuration, status,
-   * and result.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.BuildApproval approval = 44 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return Whether the approval field is set. - */ - @java.lang.Override - public boolean hasApproval() { - return approval_ != null; - } - /** - * - * - *
-   * Output only. Describes this build's approval configuration, status,
-   * and result.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.BuildApproval approval = 44 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The approval. - */ - @java.lang.Override - public com.google.cloudbuild.v1.BuildApproval getApproval() { - return approval_ == null - ? com.google.cloudbuild.v1.BuildApproval.getDefaultInstance() - : approval_; - } - /** - * - * - *
-   * Output only. Describes this build's approval configuration, status,
-   * and result.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.BuildApproval approval = 44 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - @java.lang.Override - public com.google.cloudbuild.v1.BuildApprovalOrBuilder getApprovalOrBuilder() { - return getApproval(); - } - - public static final int SERVICE_ACCOUNT_FIELD_NUMBER = 42; - private volatile java.lang.Object serviceAccount_; - /** - * - * - *
-   * IAM service account whose credentials will be used at build runtime.
-   * Must be of the format `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`.
-   * ACCOUNT can be email address or uniqueId of the service account.
-   * 
- * - * string service_account = 42 [(.google.api.resource_reference) = { ... } - * - * @return The serviceAccount. - */ - @java.lang.Override - public java.lang.String getServiceAccount() { - java.lang.Object ref = serviceAccount_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - serviceAccount_ = s; - return s; - } - } - /** - * - * - *
-   * IAM service account whose credentials will be used at build runtime.
-   * Must be of the format `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`.
-   * ACCOUNT can be email address or uniqueId of the service account.
-   * 
- * - * string service_account = 42 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for serviceAccount. - */ - @java.lang.Override - public com.google.protobuf.ByteString getServiceAccountBytes() { - java.lang.Object ref = serviceAccount_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - serviceAccount_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int AVAILABLE_SECRETS_FIELD_NUMBER = 47; - private com.google.cloudbuild.v1.Secrets availableSecrets_; - /** - * - * - *
-   * Secrets and secret environment variables.
-   * 
- * - * .google.devtools.cloudbuild.v1.Secrets available_secrets = 47; - * - * @return Whether the availableSecrets field is set. - */ - @java.lang.Override - public boolean hasAvailableSecrets() { - return availableSecrets_ != null; - } - /** - * - * - *
-   * Secrets and secret environment variables.
-   * 
- * - * .google.devtools.cloudbuild.v1.Secrets available_secrets = 47; - * - * @return The availableSecrets. - */ - @java.lang.Override - public com.google.cloudbuild.v1.Secrets getAvailableSecrets() { - return availableSecrets_ == null - ? com.google.cloudbuild.v1.Secrets.getDefaultInstance() - : availableSecrets_; - } - /** - * - * - *
-   * Secrets and secret environment variables.
-   * 
- * - * .google.devtools.cloudbuild.v1.Secrets available_secrets = 47; - */ - @java.lang.Override - public com.google.cloudbuild.v1.SecretsOrBuilder getAvailableSecretsOrBuilder() { - return getAvailableSecrets(); - } - - public static final int WARNINGS_FIELD_NUMBER = 49; - private java.util.List warnings_; - /** - * - * - *
-   * Output only. Non-fatal problems encountered during the execution of the
-   * build.
-   * 
- * - * - * repeated .google.devtools.cloudbuild.v1.Build.Warning warnings = 49 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - @java.lang.Override - public java.util.List getWarningsList() { - return warnings_; - } - /** - * - * - *
-   * Output only. Non-fatal problems encountered during the execution of the
-   * build.
-   * 
- * - * - * repeated .google.devtools.cloudbuild.v1.Build.Warning warnings = 49 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - @java.lang.Override - public java.util.List - getWarningsOrBuilderList() { - return warnings_; - } - /** - * - * - *
-   * Output only. Non-fatal problems encountered during the execution of the
-   * build.
-   * 
- * - * - * repeated .google.devtools.cloudbuild.v1.Build.Warning warnings = 49 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - @java.lang.Override - public int getWarningsCount() { - return warnings_.size(); - } - /** - * - * - *
-   * Output only. Non-fatal problems encountered during the execution of the
-   * build.
-   * 
- * - * - * repeated .google.devtools.cloudbuild.v1.Build.Warning warnings = 49 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - @java.lang.Override - public com.google.cloudbuild.v1.Build.Warning getWarnings(int index) { - return warnings_.get(index); - } - /** - * - * - *
-   * Output only. Non-fatal problems encountered during the execution of the
-   * build.
-   * 
- * - * - * repeated .google.devtools.cloudbuild.v1.Build.Warning warnings = 49 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - @java.lang.Override - public com.google.cloudbuild.v1.Build.WarningOrBuilder getWarningsOrBuilder(int index) { - return warnings_.get(index); - } - - public static final int FAILURE_INFO_FIELD_NUMBER = 51; - private com.google.cloudbuild.v1.Build.FailureInfo failureInfo_; - /** - * - * - *
-   * Output only. Contains information about the build when status=FAILURE.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.Build.FailureInfo failure_info = 51 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return Whether the failureInfo field is set. - */ - @java.lang.Override - public boolean hasFailureInfo() { - return failureInfo_ != null; - } - /** - * - * - *
-   * Output only. Contains information about the build when status=FAILURE.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.Build.FailureInfo failure_info = 51 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The failureInfo. - */ - @java.lang.Override - public com.google.cloudbuild.v1.Build.FailureInfo getFailureInfo() { - return failureInfo_ == null - ? com.google.cloudbuild.v1.Build.FailureInfo.getDefaultInstance() - : failureInfo_; - } - /** - * - * - *
-   * Output only. Contains information about the build when status=FAILURE.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.Build.FailureInfo failure_info = 51 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - @java.lang.Override - public com.google.cloudbuild.v1.Build.FailureInfoOrBuilder getFailureInfoOrBuilder() { - return getFailureInfo(); - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(id_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, id_); - } - if (status_ != com.google.cloudbuild.v1.Build.Status.STATUS_UNKNOWN.getNumber()) { - output.writeEnum(2, status_); - } - if (source_ != null) { - output.writeMessage(3, getSource()); - } - if (createTime_ != null) { - output.writeMessage(6, getCreateTime()); - } - if (startTime_ != null) { - output.writeMessage(7, getStartTime()); - } - if (finishTime_ != null) { - output.writeMessage(8, getFinishTime()); - } - if (results_ != null) { - output.writeMessage(10, getResults()); - } - for (int i = 0; i < steps_.size(); i++) { - output.writeMessage(11, steps_.get(i)); - } - if (timeout_ != null) { - output.writeMessage(12, getTimeout()); - } - for (int i = 0; i < images_.size(); i++) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 13, images_.getRaw(i)); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(projectId_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 16, projectId_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(logsBucket_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 19, logsBucket_); - } - if (sourceProvenance_ != null) { - output.writeMessage(21, getSourceProvenance()); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(buildTriggerId_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 22, buildTriggerId_); - } - if (options_ != null) { - output.writeMessage(23, getOptions()); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(statusDetail_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 24, statusDetail_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(logUrl_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 25, logUrl_); - } - com.google.protobuf.GeneratedMessageV3.serializeStringMapTo( - output, internalGetSubstitutions(), SubstitutionsDefaultEntryHolder.defaultEntry, 29); - for (int i = 0; i < tags_.size(); i++) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 31, tags_.getRaw(i)); - } - for (int i = 0; i < secrets_.size(); i++) { - output.writeMessage(32, secrets_.get(i)); - } - com.google.protobuf.GeneratedMessageV3.serializeStringMapTo( - output, internalGetTiming(), TimingDefaultEntryHolder.defaultEntry, 33); - if (artifacts_ != null) { - output.writeMessage(37, getArtifacts()); - } - if (queueTtl_ != null) { - output.writeMessage(40, getQueueTtl()); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(serviceAccount_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 42, serviceAccount_); - } - if (approval_ != null) { - output.writeMessage(44, getApproval()); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 45, name_); - } - if (availableSecrets_ != null) { - output.writeMessage(47, getAvailableSecrets()); - } - for (int i = 0; i < warnings_.size(); i++) { - output.writeMessage(49, warnings_.get(i)); - } - if (failureInfo_ != null) { - output.writeMessage(51, getFailureInfo()); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(id_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, id_); - } - if (status_ != com.google.cloudbuild.v1.Build.Status.STATUS_UNKNOWN.getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(2, status_); - } - if (source_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getSource()); - } - if (createTime_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(6, getCreateTime()); - } - if (startTime_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(7, getStartTime()); - } - if (finishTime_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(8, getFinishTime()); - } - if (results_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(10, getResults()); - } - for (int i = 0; i < steps_.size(); i++) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(11, steps_.get(i)); - } - if (timeout_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(12, getTimeout()); - } - { - int dataSize = 0; - for (int i = 0; i < images_.size(); i++) { - dataSize += computeStringSizeNoTag(images_.getRaw(i)); - } - size += dataSize; - size += 1 * getImagesList().size(); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(projectId_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(16, projectId_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(logsBucket_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(19, logsBucket_); - } - if (sourceProvenance_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(21, getSourceProvenance()); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(buildTriggerId_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(22, buildTriggerId_); - } - if (options_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(23, getOptions()); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(statusDetail_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(24, statusDetail_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(logUrl_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(25, logUrl_); - } - for (java.util.Map.Entry entry : - internalGetSubstitutions().getMap().entrySet()) { - com.google.protobuf.MapEntry substitutions__ = - SubstitutionsDefaultEntryHolder.defaultEntry - .newBuilderForType() - .setKey(entry.getKey()) - .setValue(entry.getValue()) - .build(); - size += com.google.protobuf.CodedOutputStream.computeMessageSize(29, substitutions__); - } - { - int dataSize = 0; - for (int i = 0; i < tags_.size(); i++) { - dataSize += computeStringSizeNoTag(tags_.getRaw(i)); - } - size += dataSize; - size += 2 * getTagsList().size(); - } - for (int i = 0; i < secrets_.size(); i++) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(32, secrets_.get(i)); - } - for (java.util.Map.Entry entry : - internalGetTiming().getMap().entrySet()) { - com.google.protobuf.MapEntry timing__ = - TimingDefaultEntryHolder.defaultEntry - .newBuilderForType() - .setKey(entry.getKey()) - .setValue(entry.getValue()) - .build(); - size += com.google.protobuf.CodedOutputStream.computeMessageSize(33, timing__); - } - if (artifacts_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(37, getArtifacts()); - } - if (queueTtl_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(40, getQueueTtl()); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(serviceAccount_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(42, serviceAccount_); - } - if (approval_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(44, getApproval()); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(45, name_); - } - if (availableSecrets_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(47, getAvailableSecrets()); - } - for (int i = 0; i < warnings_.size(); i++) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(49, warnings_.get(i)); - } - if (failureInfo_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(51, getFailureInfo()); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.Build)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.Build other = (com.google.cloudbuild.v1.Build) obj; - - if (!getName().equals(other.getName())) return false; - if (!getId().equals(other.getId())) return false; - if (!getProjectId().equals(other.getProjectId())) return false; - if (status_ != other.status_) return false; - if (!getStatusDetail().equals(other.getStatusDetail())) return false; - if (hasSource() != other.hasSource()) return false; - if (hasSource()) { - if (!getSource().equals(other.getSource())) return false; - } - if (!getStepsList().equals(other.getStepsList())) return false; - if (hasResults() != other.hasResults()) return false; - if (hasResults()) { - if (!getResults().equals(other.getResults())) return false; - } - if (hasCreateTime() != other.hasCreateTime()) return false; - if (hasCreateTime()) { - if (!getCreateTime().equals(other.getCreateTime())) return false; - } - if (hasStartTime() != other.hasStartTime()) return false; - if (hasStartTime()) { - if (!getStartTime().equals(other.getStartTime())) return false; - } - if (hasFinishTime() != other.hasFinishTime()) return false; - if (hasFinishTime()) { - if (!getFinishTime().equals(other.getFinishTime())) return false; - } - if (hasTimeout() != other.hasTimeout()) return false; - if (hasTimeout()) { - if (!getTimeout().equals(other.getTimeout())) return false; - } - if (!getImagesList().equals(other.getImagesList())) return false; - if (hasQueueTtl() != other.hasQueueTtl()) return false; - if (hasQueueTtl()) { - if (!getQueueTtl().equals(other.getQueueTtl())) return false; - } - if (hasArtifacts() != other.hasArtifacts()) return false; - if (hasArtifacts()) { - if (!getArtifacts().equals(other.getArtifacts())) return false; - } - if (!getLogsBucket().equals(other.getLogsBucket())) return false; - if (hasSourceProvenance() != other.hasSourceProvenance()) return false; - if (hasSourceProvenance()) { - if (!getSourceProvenance().equals(other.getSourceProvenance())) return false; - } - if (!getBuildTriggerId().equals(other.getBuildTriggerId())) return false; - if (hasOptions() != other.hasOptions()) return false; - if (hasOptions()) { - if (!getOptions().equals(other.getOptions())) return false; - } - if (!getLogUrl().equals(other.getLogUrl())) return false; - if (!internalGetSubstitutions().equals(other.internalGetSubstitutions())) return false; - if (!getTagsList().equals(other.getTagsList())) return false; - if (!getSecretsList().equals(other.getSecretsList())) return false; - if (!internalGetTiming().equals(other.internalGetTiming())) return false; - if (hasApproval() != other.hasApproval()) return false; - if (hasApproval()) { - if (!getApproval().equals(other.getApproval())) return false; - } - if (!getServiceAccount().equals(other.getServiceAccount())) return false; - if (hasAvailableSecrets() != other.hasAvailableSecrets()) return false; - if (hasAvailableSecrets()) { - if (!getAvailableSecrets().equals(other.getAvailableSecrets())) return false; - } - if (!getWarningsList().equals(other.getWarningsList())) return false; - if (hasFailureInfo() != other.hasFailureInfo()) return false; - if (hasFailureInfo()) { - if (!getFailureInfo().equals(other.getFailureInfo())) return false; - } - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + NAME_FIELD_NUMBER; - hash = (53 * hash) + getName().hashCode(); - hash = (37 * hash) + ID_FIELD_NUMBER; - hash = (53 * hash) + getId().hashCode(); - hash = (37 * hash) + PROJECT_ID_FIELD_NUMBER; - hash = (53 * hash) + getProjectId().hashCode(); - hash = (37 * hash) + STATUS_FIELD_NUMBER; - hash = (53 * hash) + status_; - hash = (37 * hash) + STATUS_DETAIL_FIELD_NUMBER; - hash = (53 * hash) + getStatusDetail().hashCode(); - if (hasSource()) { - hash = (37 * hash) + SOURCE_FIELD_NUMBER; - hash = (53 * hash) + getSource().hashCode(); - } - if (getStepsCount() > 0) { - hash = (37 * hash) + STEPS_FIELD_NUMBER; - hash = (53 * hash) + getStepsList().hashCode(); - } - if (hasResults()) { - hash = (37 * hash) + RESULTS_FIELD_NUMBER; - hash = (53 * hash) + getResults().hashCode(); - } - if (hasCreateTime()) { - hash = (37 * hash) + CREATE_TIME_FIELD_NUMBER; - hash = (53 * hash) + getCreateTime().hashCode(); - } - if (hasStartTime()) { - hash = (37 * hash) + START_TIME_FIELD_NUMBER; - hash = (53 * hash) + getStartTime().hashCode(); - } - if (hasFinishTime()) { - hash = (37 * hash) + FINISH_TIME_FIELD_NUMBER; - hash = (53 * hash) + getFinishTime().hashCode(); - } - if (hasTimeout()) { - hash = (37 * hash) + TIMEOUT_FIELD_NUMBER; - hash = (53 * hash) + getTimeout().hashCode(); - } - if (getImagesCount() > 0) { - hash = (37 * hash) + IMAGES_FIELD_NUMBER; - hash = (53 * hash) + getImagesList().hashCode(); - } - if (hasQueueTtl()) { - hash = (37 * hash) + QUEUE_TTL_FIELD_NUMBER; - hash = (53 * hash) + getQueueTtl().hashCode(); - } - if (hasArtifacts()) { - hash = (37 * hash) + ARTIFACTS_FIELD_NUMBER; - hash = (53 * hash) + getArtifacts().hashCode(); - } - hash = (37 * hash) + LOGS_BUCKET_FIELD_NUMBER; - hash = (53 * hash) + getLogsBucket().hashCode(); - if (hasSourceProvenance()) { - hash = (37 * hash) + SOURCE_PROVENANCE_FIELD_NUMBER; - hash = (53 * hash) + getSourceProvenance().hashCode(); - } - hash = (37 * hash) + BUILD_TRIGGER_ID_FIELD_NUMBER; - hash = (53 * hash) + getBuildTriggerId().hashCode(); - if (hasOptions()) { - hash = (37 * hash) + OPTIONS_FIELD_NUMBER; - hash = (53 * hash) + getOptions().hashCode(); - } - hash = (37 * hash) + LOG_URL_FIELD_NUMBER; - hash = (53 * hash) + getLogUrl().hashCode(); - if (!internalGetSubstitutions().getMap().isEmpty()) { - hash = (37 * hash) + SUBSTITUTIONS_FIELD_NUMBER; - hash = (53 * hash) + internalGetSubstitutions().hashCode(); - } - if (getTagsCount() > 0) { - hash = (37 * hash) + TAGS_FIELD_NUMBER; - hash = (53 * hash) + getTagsList().hashCode(); - } - if (getSecretsCount() > 0) { - hash = (37 * hash) + SECRETS_FIELD_NUMBER; - hash = (53 * hash) + getSecretsList().hashCode(); - } - if (!internalGetTiming().getMap().isEmpty()) { - hash = (37 * hash) + TIMING_FIELD_NUMBER; - hash = (53 * hash) + internalGetTiming().hashCode(); - } - if (hasApproval()) { - hash = (37 * hash) + APPROVAL_FIELD_NUMBER; - hash = (53 * hash) + getApproval().hashCode(); - } - hash = (37 * hash) + SERVICE_ACCOUNT_FIELD_NUMBER; - hash = (53 * hash) + getServiceAccount().hashCode(); - if (hasAvailableSecrets()) { - hash = (37 * hash) + AVAILABLE_SECRETS_FIELD_NUMBER; - hash = (53 * hash) + getAvailableSecrets().hashCode(); - } - if (getWarningsCount() > 0) { - hash = (37 * hash) + WARNINGS_FIELD_NUMBER; - hash = (53 * hash) + getWarningsList().hashCode(); - } - if (hasFailureInfo()) { - hash = (37 * hash) + FAILURE_INFO_FIELD_NUMBER; - hash = (53 * hash) + getFailureInfo().hashCode(); - } - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.Build parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.Build parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.Build parseFrom(com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.Build parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.Build parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.Build parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.Build parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.Build parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.Build parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.Build parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.Build parseFrom(com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.Build parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.Build prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * A build resource in the Cloud Build API.
-   * At a high level, a `Build` describes where to find source code, how to build
-   * it (for example, the builder image to run on the source), and where to store
-   * the built artifacts.
-   * Fields can include the following variables, which will be expanded when the
-   * build is created:
-   * - $PROJECT_ID: the project ID of the build.
-   * - $PROJECT_NUMBER: the project number of the build.
-   * - $BUILD_ID: the autogenerated ID of the build.
-   * - $REPO_NAME: the source repository name specified by RepoSource.
-   * - $BRANCH_NAME: the branch name specified by RepoSource.
-   * - $TAG_NAME: the tag name specified by RepoSource.
-   * - $REVISION_ID or $COMMIT_SHA: the commit SHA specified by RepoSource or
-   *   resolved from the specified branch or tag.
-   * - $SHORT_SHA: first 7 characters of $REVISION_ID or $COMMIT_SHA.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.Build} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.Build) - com.google.cloudbuild.v1.BuildOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Build_descriptor; - } - - @SuppressWarnings({"rawtypes"}) - protected com.google.protobuf.MapField internalGetMapField(int number) { - switch (number) { - case 29: - return internalGetSubstitutions(); - case 33: - return internalGetTiming(); - default: - throw new RuntimeException("Invalid map field number: " + number); - } - } - - @SuppressWarnings({"rawtypes"}) - protected com.google.protobuf.MapField internalGetMutableMapField(int number) { - switch (number) { - case 29: - return internalGetMutableSubstitutions(); - case 33: - return internalGetMutableTiming(); - default: - throw new RuntimeException("Invalid map field number: " + number); - } - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Build_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.Build.class, com.google.cloudbuild.v1.Build.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.Build.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - name_ = ""; - - id_ = ""; - - projectId_ = ""; - - status_ = 0; - - statusDetail_ = ""; - - if (sourceBuilder_ == null) { - source_ = null; - } else { - source_ = null; - sourceBuilder_ = null; - } - if (stepsBuilder_ == null) { - steps_ = java.util.Collections.emptyList(); - } else { - steps_ = null; - stepsBuilder_.clear(); - } - bitField0_ = (bitField0_ & ~0x00000001); - if (resultsBuilder_ == null) { - results_ = null; - } else { - results_ = null; - resultsBuilder_ = null; - } - if (createTimeBuilder_ == null) { - createTime_ = null; - } else { - createTime_ = null; - createTimeBuilder_ = null; - } - if (startTimeBuilder_ == null) { - startTime_ = null; - } else { - startTime_ = null; - startTimeBuilder_ = null; - } - if (finishTimeBuilder_ == null) { - finishTime_ = null; - } else { - finishTime_ = null; - finishTimeBuilder_ = null; - } - if (timeoutBuilder_ == null) { - timeout_ = null; - } else { - timeout_ = null; - timeoutBuilder_ = null; - } - images_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000002); - if (queueTtlBuilder_ == null) { - queueTtl_ = null; - } else { - queueTtl_ = null; - queueTtlBuilder_ = null; - } - if (artifactsBuilder_ == null) { - artifacts_ = null; - } else { - artifacts_ = null; - artifactsBuilder_ = null; - } - logsBucket_ = ""; - - if (sourceProvenanceBuilder_ == null) { - sourceProvenance_ = null; - } else { - sourceProvenance_ = null; - sourceProvenanceBuilder_ = null; - } - buildTriggerId_ = ""; - - if (optionsBuilder_ == null) { - options_ = null; - } else { - options_ = null; - optionsBuilder_ = null; - } - logUrl_ = ""; - - internalGetMutableSubstitutions().clear(); - tags_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000008); - if (secretsBuilder_ == null) { - secrets_ = java.util.Collections.emptyList(); - } else { - secrets_ = null; - secretsBuilder_.clear(); - } - bitField0_ = (bitField0_ & ~0x00000010); - internalGetMutableTiming().clear(); - if (approvalBuilder_ == null) { - approval_ = null; - } else { - approval_ = null; - approvalBuilder_ = null; - } - serviceAccount_ = ""; - - if (availableSecretsBuilder_ == null) { - availableSecrets_ = null; - } else { - availableSecrets_ = null; - availableSecretsBuilder_ = null; - } - if (warningsBuilder_ == null) { - warnings_ = java.util.Collections.emptyList(); - } else { - warnings_ = null; - warningsBuilder_.clear(); - } - bitField0_ = (bitField0_ & ~0x00000040); - if (failureInfoBuilder_ == null) { - failureInfo_ = null; - } else { - failureInfo_ = null; - failureInfoBuilder_ = null; - } - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Build_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.Build getDefaultInstanceForType() { - return com.google.cloudbuild.v1.Build.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.Build build() { - com.google.cloudbuild.v1.Build result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.Build buildPartial() { - com.google.cloudbuild.v1.Build result = new com.google.cloudbuild.v1.Build(this); - int from_bitField0_ = bitField0_; - result.name_ = name_; - result.id_ = id_; - result.projectId_ = projectId_; - result.status_ = status_; - result.statusDetail_ = statusDetail_; - if (sourceBuilder_ == null) { - result.source_ = source_; - } else { - result.source_ = sourceBuilder_.build(); - } - if (stepsBuilder_ == null) { - if (((bitField0_ & 0x00000001) != 0)) { - steps_ = java.util.Collections.unmodifiableList(steps_); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.steps_ = steps_; - } else { - result.steps_ = stepsBuilder_.build(); - } - if (resultsBuilder_ == null) { - result.results_ = results_; - } else { - result.results_ = resultsBuilder_.build(); - } - if (createTimeBuilder_ == null) { - result.createTime_ = createTime_; - } else { - result.createTime_ = createTimeBuilder_.build(); - } - if (startTimeBuilder_ == null) { - result.startTime_ = startTime_; - } else { - result.startTime_ = startTimeBuilder_.build(); - } - if (finishTimeBuilder_ == null) { - result.finishTime_ = finishTime_; - } else { - result.finishTime_ = finishTimeBuilder_.build(); - } - if (timeoutBuilder_ == null) { - result.timeout_ = timeout_; - } else { - result.timeout_ = timeoutBuilder_.build(); - } - if (((bitField0_ & 0x00000002) != 0)) { - images_ = images_.getUnmodifiableView(); - bitField0_ = (bitField0_ & ~0x00000002); - } - result.images_ = images_; - if (queueTtlBuilder_ == null) { - result.queueTtl_ = queueTtl_; - } else { - result.queueTtl_ = queueTtlBuilder_.build(); - } - if (artifactsBuilder_ == null) { - result.artifacts_ = artifacts_; - } else { - result.artifacts_ = artifactsBuilder_.build(); - } - result.logsBucket_ = logsBucket_; - if (sourceProvenanceBuilder_ == null) { - result.sourceProvenance_ = sourceProvenance_; - } else { - result.sourceProvenance_ = sourceProvenanceBuilder_.build(); - } - result.buildTriggerId_ = buildTriggerId_; - if (optionsBuilder_ == null) { - result.options_ = options_; - } else { - result.options_ = optionsBuilder_.build(); - } - result.logUrl_ = logUrl_; - result.substitutions_ = internalGetSubstitutions(); - result.substitutions_.makeImmutable(); - if (((bitField0_ & 0x00000008) != 0)) { - tags_ = tags_.getUnmodifiableView(); - bitField0_ = (bitField0_ & ~0x00000008); - } - result.tags_ = tags_; - if (secretsBuilder_ == null) { - if (((bitField0_ & 0x00000010) != 0)) { - secrets_ = java.util.Collections.unmodifiableList(secrets_); - bitField0_ = (bitField0_ & ~0x00000010); - } - result.secrets_ = secrets_; - } else { - result.secrets_ = secretsBuilder_.build(); - } - result.timing_ = internalGetTiming(); - result.timing_.makeImmutable(); - if (approvalBuilder_ == null) { - result.approval_ = approval_; - } else { - result.approval_ = approvalBuilder_.build(); - } - result.serviceAccount_ = serviceAccount_; - if (availableSecretsBuilder_ == null) { - result.availableSecrets_ = availableSecrets_; - } else { - result.availableSecrets_ = availableSecretsBuilder_.build(); - } - if (warningsBuilder_ == null) { - if (((bitField0_ & 0x00000040) != 0)) { - warnings_ = java.util.Collections.unmodifiableList(warnings_); - bitField0_ = (bitField0_ & ~0x00000040); - } - result.warnings_ = warnings_; - } else { - result.warnings_ = warningsBuilder_.build(); - } - if (failureInfoBuilder_ == null) { - result.failureInfo_ = failureInfo_; - } else { - result.failureInfo_ = failureInfoBuilder_.build(); - } - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.Build) { - return mergeFrom((com.google.cloudbuild.v1.Build) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.Build other) { - if (other == com.google.cloudbuild.v1.Build.getDefaultInstance()) return this; - if (!other.getName().isEmpty()) { - name_ = other.name_; - onChanged(); - } - if (!other.getId().isEmpty()) { - id_ = other.id_; - onChanged(); - } - if (!other.getProjectId().isEmpty()) { - projectId_ = other.projectId_; - onChanged(); - } - if (other.status_ != 0) { - setStatusValue(other.getStatusValue()); - } - if (!other.getStatusDetail().isEmpty()) { - statusDetail_ = other.statusDetail_; - onChanged(); - } - if (other.hasSource()) { - mergeSource(other.getSource()); - } - if (stepsBuilder_ == null) { - if (!other.steps_.isEmpty()) { - if (steps_.isEmpty()) { - steps_ = other.steps_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureStepsIsMutable(); - steps_.addAll(other.steps_); - } - onChanged(); - } - } else { - if (!other.steps_.isEmpty()) { - if (stepsBuilder_.isEmpty()) { - stepsBuilder_.dispose(); - stepsBuilder_ = null; - steps_ = other.steps_; - bitField0_ = (bitField0_ & ~0x00000001); - stepsBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders - ? getStepsFieldBuilder() - : null; - } else { - stepsBuilder_.addAllMessages(other.steps_); - } - } - } - if (other.hasResults()) { - mergeResults(other.getResults()); - } - if (other.hasCreateTime()) { - mergeCreateTime(other.getCreateTime()); - } - if (other.hasStartTime()) { - mergeStartTime(other.getStartTime()); - } - if (other.hasFinishTime()) { - mergeFinishTime(other.getFinishTime()); - } - if (other.hasTimeout()) { - mergeTimeout(other.getTimeout()); - } - if (!other.images_.isEmpty()) { - if (images_.isEmpty()) { - images_ = other.images_; - bitField0_ = (bitField0_ & ~0x00000002); - } else { - ensureImagesIsMutable(); - images_.addAll(other.images_); - } - onChanged(); - } - if (other.hasQueueTtl()) { - mergeQueueTtl(other.getQueueTtl()); - } - if (other.hasArtifacts()) { - mergeArtifacts(other.getArtifacts()); - } - if (!other.getLogsBucket().isEmpty()) { - logsBucket_ = other.logsBucket_; - onChanged(); - } - if (other.hasSourceProvenance()) { - mergeSourceProvenance(other.getSourceProvenance()); - } - if (!other.getBuildTriggerId().isEmpty()) { - buildTriggerId_ = other.buildTriggerId_; - onChanged(); - } - if (other.hasOptions()) { - mergeOptions(other.getOptions()); - } - if (!other.getLogUrl().isEmpty()) { - logUrl_ = other.logUrl_; - onChanged(); - } - internalGetMutableSubstitutions().mergeFrom(other.internalGetSubstitutions()); - if (!other.tags_.isEmpty()) { - if (tags_.isEmpty()) { - tags_ = other.tags_; - bitField0_ = (bitField0_ & ~0x00000008); - } else { - ensureTagsIsMutable(); - tags_.addAll(other.tags_); - } - onChanged(); - } - if (secretsBuilder_ == null) { - if (!other.secrets_.isEmpty()) { - if (secrets_.isEmpty()) { - secrets_ = other.secrets_; - bitField0_ = (bitField0_ & ~0x00000010); - } else { - ensureSecretsIsMutable(); - secrets_.addAll(other.secrets_); - } - onChanged(); - } - } else { - if (!other.secrets_.isEmpty()) { - if (secretsBuilder_.isEmpty()) { - secretsBuilder_.dispose(); - secretsBuilder_ = null; - secrets_ = other.secrets_; - bitField0_ = (bitField0_ & ~0x00000010); - secretsBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders - ? getSecretsFieldBuilder() - : null; - } else { - secretsBuilder_.addAllMessages(other.secrets_); - } - } - } - internalGetMutableTiming().mergeFrom(other.internalGetTiming()); - if (other.hasApproval()) { - mergeApproval(other.getApproval()); - } - if (!other.getServiceAccount().isEmpty()) { - serviceAccount_ = other.serviceAccount_; - onChanged(); - } - if (other.hasAvailableSecrets()) { - mergeAvailableSecrets(other.getAvailableSecrets()); - } - if (warningsBuilder_ == null) { - if (!other.warnings_.isEmpty()) { - if (warnings_.isEmpty()) { - warnings_ = other.warnings_; - bitField0_ = (bitField0_ & ~0x00000040); - } else { - ensureWarningsIsMutable(); - warnings_.addAll(other.warnings_); - } - onChanged(); - } - } else { - if (!other.warnings_.isEmpty()) { - if (warningsBuilder_.isEmpty()) { - warningsBuilder_.dispose(); - warningsBuilder_ = null; - warnings_ = other.warnings_; - bitField0_ = (bitField0_ & ~0x00000040); - warningsBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders - ? getWarningsFieldBuilder() - : null; - } else { - warningsBuilder_.addAllMessages(other.warnings_); - } - } - } - if (other.hasFailureInfo()) { - mergeFailureInfo(other.getFailureInfo()); - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - id_ = input.readStringRequireUtf8(); - - break; - } // case 10 - case 16: - { - status_ = input.readEnum(); - - break; - } // case 16 - case 26: - { - input.readMessage(getSourceFieldBuilder().getBuilder(), extensionRegistry); - - break; - } // case 26 - case 50: - { - input.readMessage(getCreateTimeFieldBuilder().getBuilder(), extensionRegistry); - - break; - } // case 50 - case 58: - { - input.readMessage(getStartTimeFieldBuilder().getBuilder(), extensionRegistry); - - break; - } // case 58 - case 66: - { - input.readMessage(getFinishTimeFieldBuilder().getBuilder(), extensionRegistry); - - break; - } // case 66 - case 82: - { - input.readMessage(getResultsFieldBuilder().getBuilder(), extensionRegistry); - - break; - } // case 82 - case 90: - { - com.google.cloudbuild.v1.BuildStep m = - input.readMessage( - com.google.cloudbuild.v1.BuildStep.parser(), extensionRegistry); - if (stepsBuilder_ == null) { - ensureStepsIsMutable(); - steps_.add(m); - } else { - stepsBuilder_.addMessage(m); - } - break; - } // case 90 - case 98: - { - input.readMessage(getTimeoutFieldBuilder().getBuilder(), extensionRegistry); - - break; - } // case 98 - case 106: - { - java.lang.String s = input.readStringRequireUtf8(); - ensureImagesIsMutable(); - images_.add(s); - break; - } // case 106 - case 130: - { - projectId_ = input.readStringRequireUtf8(); - - break; - } // case 130 - case 154: - { - logsBucket_ = input.readStringRequireUtf8(); - - break; - } // case 154 - case 170: - { - input.readMessage( - getSourceProvenanceFieldBuilder().getBuilder(), extensionRegistry); - - break; - } // case 170 - case 178: - { - buildTriggerId_ = input.readStringRequireUtf8(); - - break; - } // case 178 - case 186: - { - input.readMessage(getOptionsFieldBuilder().getBuilder(), extensionRegistry); - - break; - } // case 186 - case 194: - { - statusDetail_ = input.readStringRequireUtf8(); - - break; - } // case 194 - case 202: - { - logUrl_ = input.readStringRequireUtf8(); - - break; - } // case 202 - case 234: - { - com.google.protobuf.MapEntry substitutions__ = - input.readMessage( - SubstitutionsDefaultEntryHolder.defaultEntry.getParserForType(), - extensionRegistry); - internalGetMutableSubstitutions() - .getMutableMap() - .put(substitutions__.getKey(), substitutions__.getValue()); - break; - } // case 234 - case 250: - { - java.lang.String s = input.readStringRequireUtf8(); - ensureTagsIsMutable(); - tags_.add(s); - break; - } // case 250 - case 258: - { - com.google.cloudbuild.v1.Secret m = - input.readMessage(com.google.cloudbuild.v1.Secret.parser(), extensionRegistry); - if (secretsBuilder_ == null) { - ensureSecretsIsMutable(); - secrets_.add(m); - } else { - secretsBuilder_.addMessage(m); - } - break; - } // case 258 - case 266: - { - com.google.protobuf.MapEntry - timing__ = - input.readMessage( - TimingDefaultEntryHolder.defaultEntry.getParserForType(), - extensionRegistry); - internalGetMutableTiming() - .getMutableMap() - .put(timing__.getKey(), timing__.getValue()); - break; - } // case 266 - case 298: - { - input.readMessage(getArtifactsFieldBuilder().getBuilder(), extensionRegistry); - - break; - } // case 298 - case 322: - { - input.readMessage(getQueueTtlFieldBuilder().getBuilder(), extensionRegistry); - - break; - } // case 322 - case 338: - { - serviceAccount_ = input.readStringRequireUtf8(); - - break; - } // case 338 - case 354: - { - input.readMessage(getApprovalFieldBuilder().getBuilder(), extensionRegistry); - - break; - } // case 354 - case 362: - { - name_ = input.readStringRequireUtf8(); - - break; - } // case 362 - case 378: - { - input.readMessage( - getAvailableSecretsFieldBuilder().getBuilder(), extensionRegistry); - - break; - } // case 378 - case 394: - { - com.google.cloudbuild.v1.Build.Warning m = - input.readMessage( - com.google.cloudbuild.v1.Build.Warning.parser(), extensionRegistry); - if (warningsBuilder_ == null) { - ensureWarningsIsMutable(); - warnings_.add(m); - } else { - warningsBuilder_.addMessage(m); - } - break; - } // case 394 - case 410: - { - input.readMessage(getFailureInfoFieldBuilder().getBuilder(), extensionRegistry); - - break; - } // case 410 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private int bitField0_; - - private java.lang.Object name_ = ""; - /** - * - * - *
-     * Output only. The 'Build' name with format:
-     * `projects/{project}/locations/{location}/builds/{build}`, where {build}
-     * is a unique identifier generated by the service.
-     * 
- * - * string name = 45 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The name. - */ - public java.lang.String getName() { - java.lang.Object ref = name_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - name_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Output only. The 'Build' name with format:
-     * `projects/{project}/locations/{location}/builds/{build}`, where {build}
-     * is a unique identifier generated by the service.
-     * 
- * - * string name = 45 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The bytes for name. - */ - public com.google.protobuf.ByteString getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Output only. The 'Build' name with format:
-     * `projects/{project}/locations/{location}/builds/{build}`, where {build}
-     * is a unique identifier generated by the service.
-     * 
- * - * string name = 45 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @param value The name to set. - * @return This builder for chaining. - */ - public Builder setName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - name_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. The 'Build' name with format:
-     * `projects/{project}/locations/{location}/builds/{build}`, where {build}
-     * is a unique identifier generated by the service.
-     * 
- * - * string name = 45 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return This builder for chaining. - */ - public Builder clearName() { - - name_ = getDefaultInstance().getName(); - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. The 'Build' name with format:
-     * `projects/{project}/locations/{location}/builds/{build}`, where {build}
-     * is a unique identifier generated by the service.
-     * 
- * - * string name = 45 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @param value The bytes for name to set. - * @return This builder for chaining. - */ - public Builder setNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - name_ = value; - onChanged(); - return this; - } - - private java.lang.Object id_ = ""; - /** - * - * - *
-     * Output only. Unique identifier of the build.
-     * 
- * - * string id = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The id. - */ - public java.lang.String getId() { - java.lang.Object ref = id_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - id_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Output only. Unique identifier of the build.
-     * 
- * - * string id = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The bytes for id. - */ - public com.google.protobuf.ByteString getIdBytes() { - java.lang.Object ref = id_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - id_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Output only. Unique identifier of the build.
-     * 
- * - * string id = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @param value The id to set. - * @return This builder for chaining. - */ - public Builder setId(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - id_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. Unique identifier of the build.
-     * 
- * - * string id = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return This builder for chaining. - */ - public Builder clearId() { - - id_ = getDefaultInstance().getId(); - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. Unique identifier of the build.
-     * 
- * - * string id = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @param value The bytes for id to set. - * @return This builder for chaining. - */ - public Builder setIdBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - id_ = value; - onChanged(); - return this; - } - - private java.lang.Object projectId_ = ""; - /** - * - * - *
-     * Output only. ID of the project.
-     * 
- * - * string project_id = 16 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The projectId. - */ - public java.lang.String getProjectId() { - java.lang.Object ref = projectId_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - projectId_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Output only. ID of the project.
-     * 
- * - * string project_id = 16 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The bytes for projectId. - */ - public com.google.protobuf.ByteString getProjectIdBytes() { - java.lang.Object ref = projectId_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - projectId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Output only. ID of the project.
-     * 
- * - * string project_id = 16 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @param value The projectId to set. - * @return This builder for chaining. - */ - public Builder setProjectId(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - projectId_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. ID of the project.
-     * 
- * - * string project_id = 16 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return This builder for chaining. - */ - public Builder clearProjectId() { - - projectId_ = getDefaultInstance().getProjectId(); - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. ID of the project.
-     * 
- * - * string project_id = 16 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @param value The bytes for projectId to set. - * @return This builder for chaining. - */ - public Builder setProjectIdBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - projectId_ = value; - onChanged(); - return this; - } - - private int status_ = 0; - /** - * - * - *
-     * Output only. Status of the build.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.Build.Status status = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The enum numeric value on the wire for status. - */ - @java.lang.Override - public int getStatusValue() { - return status_; - } - /** - * - * - *
-     * Output only. Status of the build.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.Build.Status status = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @param value The enum numeric value on the wire for status to set. - * @return This builder for chaining. - */ - public Builder setStatusValue(int value) { - - status_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. Status of the build.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.Build.Status status = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The status. - */ - @java.lang.Override - public com.google.cloudbuild.v1.Build.Status getStatus() { - @SuppressWarnings("deprecation") - com.google.cloudbuild.v1.Build.Status result = - com.google.cloudbuild.v1.Build.Status.valueOf(status_); - return result == null ? com.google.cloudbuild.v1.Build.Status.UNRECOGNIZED : result; - } - /** - * - * - *
-     * Output only. Status of the build.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.Build.Status status = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @param value The status to set. - * @return This builder for chaining. - */ - public Builder setStatus(com.google.cloudbuild.v1.Build.Status value) { - if (value == null) { - throw new NullPointerException(); - } - - status_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. Status of the build.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.Build.Status status = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return This builder for chaining. - */ - public Builder clearStatus() { - - status_ = 0; - onChanged(); - return this; - } - - private java.lang.Object statusDetail_ = ""; - /** - * - * - *
-     * Output only. Customer-readable message about the current status.
-     * 
- * - * string status_detail = 24 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The statusDetail. - */ - public java.lang.String getStatusDetail() { - java.lang.Object ref = statusDetail_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - statusDetail_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Output only. Customer-readable message about the current status.
-     * 
- * - * string status_detail = 24 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The bytes for statusDetail. - */ - public com.google.protobuf.ByteString getStatusDetailBytes() { - java.lang.Object ref = statusDetail_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - statusDetail_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Output only. Customer-readable message about the current status.
-     * 
- * - * string status_detail = 24 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @param value The statusDetail to set. - * @return This builder for chaining. - */ - public Builder setStatusDetail(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - statusDetail_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. Customer-readable message about the current status.
-     * 
- * - * string status_detail = 24 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return This builder for chaining. - */ - public Builder clearStatusDetail() { - - statusDetail_ = getDefaultInstance().getStatusDetail(); - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. Customer-readable message about the current status.
-     * 
- * - * string status_detail = 24 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @param value The bytes for statusDetail to set. - * @return This builder for chaining. - */ - public Builder setStatusDetailBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - statusDetail_ = value; - onChanged(); - return this; - } - - private com.google.cloudbuild.v1.Source source_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.Source, - com.google.cloudbuild.v1.Source.Builder, - com.google.cloudbuild.v1.SourceOrBuilder> - sourceBuilder_; - /** - * - * - *
-     * The location of the source files to build.
-     * 
- * - * .google.devtools.cloudbuild.v1.Source source = 3; - * - * @return Whether the source field is set. - */ - public boolean hasSource() { - return sourceBuilder_ != null || source_ != null; - } - /** - * - * - *
-     * The location of the source files to build.
-     * 
- * - * .google.devtools.cloudbuild.v1.Source source = 3; - * - * @return The source. - */ - public com.google.cloudbuild.v1.Source getSource() { - if (sourceBuilder_ == null) { - return source_ == null ? com.google.cloudbuild.v1.Source.getDefaultInstance() : source_; - } else { - return sourceBuilder_.getMessage(); - } - } - /** - * - * - *
-     * The location of the source files to build.
-     * 
- * - * .google.devtools.cloudbuild.v1.Source source = 3; - */ - public Builder setSource(com.google.cloudbuild.v1.Source value) { - if (sourceBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - source_ = value; - onChanged(); - } else { - sourceBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * The location of the source files to build.
-     * 
- * - * .google.devtools.cloudbuild.v1.Source source = 3; - */ - public Builder setSource(com.google.cloudbuild.v1.Source.Builder builderForValue) { - if (sourceBuilder_ == null) { - source_ = builderForValue.build(); - onChanged(); - } else { - sourceBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * The location of the source files to build.
-     * 
- * - * .google.devtools.cloudbuild.v1.Source source = 3; - */ - public Builder mergeSource(com.google.cloudbuild.v1.Source value) { - if (sourceBuilder_ == null) { - if (source_ != null) { - source_ = - com.google.cloudbuild.v1.Source.newBuilder(source_).mergeFrom(value).buildPartial(); - } else { - source_ = value; - } - onChanged(); - } else { - sourceBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * The location of the source files to build.
-     * 
- * - * .google.devtools.cloudbuild.v1.Source source = 3; - */ - public Builder clearSource() { - if (sourceBuilder_ == null) { - source_ = null; - onChanged(); - } else { - source_ = null; - sourceBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * The location of the source files to build.
-     * 
- * - * .google.devtools.cloudbuild.v1.Source source = 3; - */ - public com.google.cloudbuild.v1.Source.Builder getSourceBuilder() { - - onChanged(); - return getSourceFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * The location of the source files to build.
-     * 
- * - * .google.devtools.cloudbuild.v1.Source source = 3; - */ - public com.google.cloudbuild.v1.SourceOrBuilder getSourceOrBuilder() { - if (sourceBuilder_ != null) { - return sourceBuilder_.getMessageOrBuilder(); - } else { - return source_ == null ? com.google.cloudbuild.v1.Source.getDefaultInstance() : source_; - } - } - /** - * - * - *
-     * The location of the source files to build.
-     * 
- * - * .google.devtools.cloudbuild.v1.Source source = 3; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.Source, - com.google.cloudbuild.v1.Source.Builder, - com.google.cloudbuild.v1.SourceOrBuilder> - getSourceFieldBuilder() { - if (sourceBuilder_ == null) { - sourceBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.Source, - com.google.cloudbuild.v1.Source.Builder, - com.google.cloudbuild.v1.SourceOrBuilder>( - getSource(), getParentForChildren(), isClean()); - source_ = null; - } - return sourceBuilder_; - } - - private java.util.List steps_ = - java.util.Collections.emptyList(); - - private void ensureStepsIsMutable() { - if (!((bitField0_ & 0x00000001) != 0)) { - steps_ = new java.util.ArrayList(steps_); - bitField0_ |= 0x00000001; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloudbuild.v1.BuildStep, - com.google.cloudbuild.v1.BuildStep.Builder, - com.google.cloudbuild.v1.BuildStepOrBuilder> - stepsBuilder_; - - /** - * - * - *
-     * Required. The operations to be performed on the workspace.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildStep steps = 11; - */ - public java.util.List getStepsList() { - if (stepsBuilder_ == null) { - return java.util.Collections.unmodifiableList(steps_); - } else { - return stepsBuilder_.getMessageList(); - } - } - /** - * - * - *
-     * Required. The operations to be performed on the workspace.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildStep steps = 11; - */ - public int getStepsCount() { - if (stepsBuilder_ == null) { - return steps_.size(); - } else { - return stepsBuilder_.getCount(); - } - } - /** - * - * - *
-     * Required. The operations to be performed on the workspace.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildStep steps = 11; - */ - public com.google.cloudbuild.v1.BuildStep getSteps(int index) { - if (stepsBuilder_ == null) { - return steps_.get(index); - } else { - return stepsBuilder_.getMessage(index); - } - } - /** - * - * - *
-     * Required. The operations to be performed on the workspace.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildStep steps = 11; - */ - public Builder setSteps(int index, com.google.cloudbuild.v1.BuildStep value) { - if (stepsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureStepsIsMutable(); - steps_.set(index, value); - onChanged(); - } else { - stepsBuilder_.setMessage(index, value); - } - return this; - } - /** - * - * - *
-     * Required. The operations to be performed on the workspace.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildStep steps = 11; - */ - public Builder setSteps(int index, com.google.cloudbuild.v1.BuildStep.Builder builderForValue) { - if (stepsBuilder_ == null) { - ensureStepsIsMutable(); - steps_.set(index, builderForValue.build()); - onChanged(); - } else { - stepsBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * Required. The operations to be performed on the workspace.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildStep steps = 11; - */ - public Builder addSteps(com.google.cloudbuild.v1.BuildStep value) { - if (stepsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureStepsIsMutable(); - steps_.add(value); - onChanged(); - } else { - stepsBuilder_.addMessage(value); - } - return this; - } - /** - * - * - *
-     * Required. The operations to be performed on the workspace.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildStep steps = 11; - */ - public Builder addSteps(int index, com.google.cloudbuild.v1.BuildStep value) { - if (stepsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureStepsIsMutable(); - steps_.add(index, value); - onChanged(); - } else { - stepsBuilder_.addMessage(index, value); - } - return this; - } - /** - * - * - *
-     * Required. The operations to be performed on the workspace.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildStep steps = 11; - */ - public Builder addSteps(com.google.cloudbuild.v1.BuildStep.Builder builderForValue) { - if (stepsBuilder_ == null) { - ensureStepsIsMutable(); - steps_.add(builderForValue.build()); - onChanged(); - } else { - stepsBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * Required. The operations to be performed on the workspace.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildStep steps = 11; - */ - public Builder addSteps(int index, com.google.cloudbuild.v1.BuildStep.Builder builderForValue) { - if (stepsBuilder_ == null) { - ensureStepsIsMutable(); - steps_.add(index, builderForValue.build()); - onChanged(); - } else { - stepsBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * Required. The operations to be performed on the workspace.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildStep steps = 11; - */ - public Builder addAllSteps( - java.lang.Iterable values) { - if (stepsBuilder_ == null) { - ensureStepsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, steps_); - onChanged(); - } else { - stepsBuilder_.addAllMessages(values); - } - return this; - } - /** - * - * - *
-     * Required. The operations to be performed on the workspace.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildStep steps = 11; - */ - public Builder clearSteps() { - if (stepsBuilder_ == null) { - steps_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - } else { - stepsBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * Required. The operations to be performed on the workspace.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildStep steps = 11; - */ - public Builder removeSteps(int index) { - if (stepsBuilder_ == null) { - ensureStepsIsMutable(); - steps_.remove(index); - onChanged(); - } else { - stepsBuilder_.remove(index); - } - return this; - } - /** - * - * - *
-     * Required. The operations to be performed on the workspace.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildStep steps = 11; - */ - public com.google.cloudbuild.v1.BuildStep.Builder getStepsBuilder(int index) { - return getStepsFieldBuilder().getBuilder(index); - } - /** - * - * - *
-     * Required. The operations to be performed on the workspace.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildStep steps = 11; - */ - public com.google.cloudbuild.v1.BuildStepOrBuilder getStepsOrBuilder(int index) { - if (stepsBuilder_ == null) { - return steps_.get(index); - } else { - return stepsBuilder_.getMessageOrBuilder(index); - } - } - /** - * - * - *
-     * Required. The operations to be performed on the workspace.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildStep steps = 11; - */ - public java.util.List - getStepsOrBuilderList() { - if (stepsBuilder_ != null) { - return stepsBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(steps_); - } - } - /** - * - * - *
-     * Required. The operations to be performed on the workspace.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildStep steps = 11; - */ - public com.google.cloudbuild.v1.BuildStep.Builder addStepsBuilder() { - return getStepsFieldBuilder() - .addBuilder(com.google.cloudbuild.v1.BuildStep.getDefaultInstance()); - } - /** - * - * - *
-     * Required. The operations to be performed on the workspace.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildStep steps = 11; - */ - public com.google.cloudbuild.v1.BuildStep.Builder addStepsBuilder(int index) { - return getStepsFieldBuilder() - .addBuilder(index, com.google.cloudbuild.v1.BuildStep.getDefaultInstance()); - } - /** - * - * - *
-     * Required. The operations to be performed on the workspace.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildStep steps = 11; - */ - public java.util.List getStepsBuilderList() { - return getStepsFieldBuilder().getBuilderList(); - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloudbuild.v1.BuildStep, - com.google.cloudbuild.v1.BuildStep.Builder, - com.google.cloudbuild.v1.BuildStepOrBuilder> - getStepsFieldBuilder() { - if (stepsBuilder_ == null) { - stepsBuilder_ = - new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloudbuild.v1.BuildStep, - com.google.cloudbuild.v1.BuildStep.Builder, - com.google.cloudbuild.v1.BuildStepOrBuilder>( - steps_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); - steps_ = null; - } - return stepsBuilder_; - } - - private com.google.cloudbuild.v1.Results results_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.Results, - com.google.cloudbuild.v1.Results.Builder, - com.google.cloudbuild.v1.ResultsOrBuilder> - resultsBuilder_; - /** - * - * - *
-     * Output only. Results of the build.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.Results results = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return Whether the results field is set. - */ - public boolean hasResults() { - return resultsBuilder_ != null || results_ != null; - } - /** - * - * - *
-     * Output only. Results of the build.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.Results results = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The results. - */ - public com.google.cloudbuild.v1.Results getResults() { - if (resultsBuilder_ == null) { - return results_ == null ? com.google.cloudbuild.v1.Results.getDefaultInstance() : results_; - } else { - return resultsBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Output only. Results of the build.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.Results results = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder setResults(com.google.cloudbuild.v1.Results value) { - if (resultsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - results_ = value; - onChanged(); - } else { - resultsBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * Output only. Results of the build.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.Results results = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder setResults(com.google.cloudbuild.v1.Results.Builder builderForValue) { - if (resultsBuilder_ == null) { - results_ = builderForValue.build(); - onChanged(); - } else { - resultsBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Output only. Results of the build.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.Results results = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder mergeResults(com.google.cloudbuild.v1.Results value) { - if (resultsBuilder_ == null) { - if (results_ != null) { - results_ = - com.google.cloudbuild.v1.Results.newBuilder(results_).mergeFrom(value).buildPartial(); - } else { - results_ = value; - } - onChanged(); - } else { - resultsBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * Output only. Results of the build.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.Results results = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder clearResults() { - if (resultsBuilder_ == null) { - results_ = null; - onChanged(); - } else { - results_ = null; - resultsBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Output only. Results of the build.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.Results results = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public com.google.cloudbuild.v1.Results.Builder getResultsBuilder() { - - onChanged(); - return getResultsFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Output only. Results of the build.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.Results results = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public com.google.cloudbuild.v1.ResultsOrBuilder getResultsOrBuilder() { - if (resultsBuilder_ != null) { - return resultsBuilder_.getMessageOrBuilder(); - } else { - return results_ == null ? com.google.cloudbuild.v1.Results.getDefaultInstance() : results_; - } - } - /** - * - * - *
-     * Output only. Results of the build.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.Results results = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.Results, - com.google.cloudbuild.v1.Results.Builder, - com.google.cloudbuild.v1.ResultsOrBuilder> - getResultsFieldBuilder() { - if (resultsBuilder_ == null) { - resultsBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.Results, - com.google.cloudbuild.v1.Results.Builder, - com.google.cloudbuild.v1.ResultsOrBuilder>( - getResults(), getParentForChildren(), isClean()); - results_ = null; - } - return resultsBuilder_; - } - - private com.google.protobuf.Timestamp createTime_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - createTimeBuilder_; - /** - * - * - *
-     * Output only. Time at which the request to create the build was received.
-     * 
- * - * - * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return Whether the createTime field is set. - */ - public boolean hasCreateTime() { - return createTimeBuilder_ != null || createTime_ != null; - } - /** - * - * - *
-     * Output only. Time at which the request to create the build was received.
-     * 
- * - * - * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The createTime. - */ - public com.google.protobuf.Timestamp getCreateTime() { - if (createTimeBuilder_ == null) { - return createTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : createTime_; - } else { - return createTimeBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Output only. Time at which the request to create the build was received.
-     * 
- * - * - * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder setCreateTime(com.google.protobuf.Timestamp value) { - if (createTimeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - createTime_ = value; - onChanged(); - } else { - createTimeBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * Output only. Time at which the request to create the build was received.
-     * 
- * - * - * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder setCreateTime(com.google.protobuf.Timestamp.Builder builderForValue) { - if (createTimeBuilder_ == null) { - createTime_ = builderForValue.build(); - onChanged(); - } else { - createTimeBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Output only. Time at which the request to create the build was received.
-     * 
- * - * - * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder mergeCreateTime(com.google.protobuf.Timestamp value) { - if (createTimeBuilder_ == null) { - if (createTime_ != null) { - createTime_ = - com.google.protobuf.Timestamp.newBuilder(createTime_).mergeFrom(value).buildPartial(); - } else { - createTime_ = value; - } - onChanged(); - } else { - createTimeBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * Output only. Time at which the request to create the build was received.
-     * 
- * - * - * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder clearCreateTime() { - if (createTimeBuilder_ == null) { - createTime_ = null; - onChanged(); - } else { - createTime_ = null; - createTimeBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Output only. Time at which the request to create the build was received.
-     * 
- * - * - * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder() { - - onChanged(); - return getCreateTimeFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Output only. Time at which the request to create the build was received.
-     * 
- * - * - * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { - if (createTimeBuilder_ != null) { - return createTimeBuilder_.getMessageOrBuilder(); - } else { - return createTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : createTime_; - } - } - /** - * - * - *
-     * Output only. Time at which the request to create the build was received.
-     * 
- * - * - * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - getCreateTimeFieldBuilder() { - if (createTimeBuilder_ == null) { - createTimeBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder>( - getCreateTime(), getParentForChildren(), isClean()); - createTime_ = null; - } - return createTimeBuilder_; - } - - private com.google.protobuf.Timestamp startTime_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - startTimeBuilder_; - /** - * - * - *
-     * Output only. Time at which execution of the build was started.
-     * 
- * - * .google.protobuf.Timestamp start_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return Whether the startTime field is set. - */ - public boolean hasStartTime() { - return startTimeBuilder_ != null || startTime_ != null; - } - /** - * - * - *
-     * Output only. Time at which execution of the build was started.
-     * 
- * - * .google.protobuf.Timestamp start_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The startTime. - */ - public com.google.protobuf.Timestamp getStartTime() { - if (startTimeBuilder_ == null) { - return startTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : startTime_; - } else { - return startTimeBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Output only. Time at which execution of the build was started.
-     * 
- * - * .google.protobuf.Timestamp start_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder setStartTime(com.google.protobuf.Timestamp value) { - if (startTimeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - startTime_ = value; - onChanged(); - } else { - startTimeBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * Output only. Time at which execution of the build was started.
-     * 
- * - * .google.protobuf.Timestamp start_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder setStartTime(com.google.protobuf.Timestamp.Builder builderForValue) { - if (startTimeBuilder_ == null) { - startTime_ = builderForValue.build(); - onChanged(); - } else { - startTimeBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Output only. Time at which execution of the build was started.
-     * 
- * - * .google.protobuf.Timestamp start_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder mergeStartTime(com.google.protobuf.Timestamp value) { - if (startTimeBuilder_ == null) { - if (startTime_ != null) { - startTime_ = - com.google.protobuf.Timestamp.newBuilder(startTime_).mergeFrom(value).buildPartial(); - } else { - startTime_ = value; - } - onChanged(); - } else { - startTimeBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * Output only. Time at which execution of the build was started.
-     * 
- * - * .google.protobuf.Timestamp start_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder clearStartTime() { - if (startTimeBuilder_ == null) { - startTime_ = null; - onChanged(); - } else { - startTime_ = null; - startTimeBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Output only. Time at which execution of the build was started.
-     * 
- * - * .google.protobuf.Timestamp start_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public com.google.protobuf.Timestamp.Builder getStartTimeBuilder() { - - onChanged(); - return getStartTimeFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Output only. Time at which execution of the build was started.
-     * 
- * - * .google.protobuf.Timestamp start_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public com.google.protobuf.TimestampOrBuilder getStartTimeOrBuilder() { - if (startTimeBuilder_ != null) { - return startTimeBuilder_.getMessageOrBuilder(); - } else { - return startTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : startTime_; - } - } - /** - * - * - *
-     * Output only. Time at which execution of the build was started.
-     * 
- * - * .google.protobuf.Timestamp start_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - getStartTimeFieldBuilder() { - if (startTimeBuilder_ == null) { - startTimeBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder>( - getStartTime(), getParentForChildren(), isClean()); - startTime_ = null; - } - return startTimeBuilder_; - } - - private com.google.protobuf.Timestamp finishTime_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - finishTimeBuilder_; - /** - * - * - *
-     * Output only. Time at which execution of the build was finished.
-     * The difference between finish_time and start_time is the duration of the
-     * build's execution.
-     * 
- * - * - * .google.protobuf.Timestamp finish_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return Whether the finishTime field is set. - */ - public boolean hasFinishTime() { - return finishTimeBuilder_ != null || finishTime_ != null; - } - /** - * - * - *
-     * Output only. Time at which execution of the build was finished.
-     * The difference between finish_time and start_time is the duration of the
-     * build's execution.
-     * 
- * - * - * .google.protobuf.Timestamp finish_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The finishTime. - */ - public com.google.protobuf.Timestamp getFinishTime() { - if (finishTimeBuilder_ == null) { - return finishTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : finishTime_; - } else { - return finishTimeBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Output only. Time at which execution of the build was finished.
-     * The difference between finish_time and start_time is the duration of the
-     * build's execution.
-     * 
- * - * - * .google.protobuf.Timestamp finish_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder setFinishTime(com.google.protobuf.Timestamp value) { - if (finishTimeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - finishTime_ = value; - onChanged(); - } else { - finishTimeBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * Output only. Time at which execution of the build was finished.
-     * The difference between finish_time and start_time is the duration of the
-     * build's execution.
-     * 
- * - * - * .google.protobuf.Timestamp finish_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder setFinishTime(com.google.protobuf.Timestamp.Builder builderForValue) { - if (finishTimeBuilder_ == null) { - finishTime_ = builderForValue.build(); - onChanged(); - } else { - finishTimeBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Output only. Time at which execution of the build was finished.
-     * The difference between finish_time and start_time is the duration of the
-     * build's execution.
-     * 
- * - * - * .google.protobuf.Timestamp finish_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder mergeFinishTime(com.google.protobuf.Timestamp value) { - if (finishTimeBuilder_ == null) { - if (finishTime_ != null) { - finishTime_ = - com.google.protobuf.Timestamp.newBuilder(finishTime_).mergeFrom(value).buildPartial(); - } else { - finishTime_ = value; - } - onChanged(); - } else { - finishTimeBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * Output only. Time at which execution of the build was finished.
-     * The difference between finish_time and start_time is the duration of the
-     * build's execution.
-     * 
- * - * - * .google.protobuf.Timestamp finish_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder clearFinishTime() { - if (finishTimeBuilder_ == null) { - finishTime_ = null; - onChanged(); - } else { - finishTime_ = null; - finishTimeBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Output only. Time at which execution of the build was finished.
-     * The difference between finish_time and start_time is the duration of the
-     * build's execution.
-     * 
- * - * - * .google.protobuf.Timestamp finish_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public com.google.protobuf.Timestamp.Builder getFinishTimeBuilder() { - - onChanged(); - return getFinishTimeFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Output only. Time at which execution of the build was finished.
-     * The difference between finish_time and start_time is the duration of the
-     * build's execution.
-     * 
- * - * - * .google.protobuf.Timestamp finish_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public com.google.protobuf.TimestampOrBuilder getFinishTimeOrBuilder() { - if (finishTimeBuilder_ != null) { - return finishTimeBuilder_.getMessageOrBuilder(); - } else { - return finishTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : finishTime_; - } - } - /** - * - * - *
-     * Output only. Time at which execution of the build was finished.
-     * The difference between finish_time and start_time is the duration of the
-     * build's execution.
-     * 
- * - * - * .google.protobuf.Timestamp finish_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - getFinishTimeFieldBuilder() { - if (finishTimeBuilder_ == null) { - finishTimeBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder>( - getFinishTime(), getParentForChildren(), isClean()); - finishTime_ = null; - } - return finishTimeBuilder_; - } - - private com.google.protobuf.Duration timeout_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Duration, - com.google.protobuf.Duration.Builder, - com.google.protobuf.DurationOrBuilder> - timeoutBuilder_; - /** - * - * - *
-     * Amount of time that this build should be allowed to run, to second
-     * granularity. If this amount of time elapses, work on the build will cease
-     * and the build status will be `TIMEOUT`.
-     * `timeout` starts ticking from `startTime`.
-     * Default time is ten minutes.
-     * 
- * - * .google.protobuf.Duration timeout = 12; - * - * @return Whether the timeout field is set. - */ - public boolean hasTimeout() { - return timeoutBuilder_ != null || timeout_ != null; - } - /** - * - * - *
-     * Amount of time that this build should be allowed to run, to second
-     * granularity. If this amount of time elapses, work on the build will cease
-     * and the build status will be `TIMEOUT`.
-     * `timeout` starts ticking from `startTime`.
-     * Default time is ten minutes.
-     * 
- * - * .google.protobuf.Duration timeout = 12; - * - * @return The timeout. - */ - public com.google.protobuf.Duration getTimeout() { - if (timeoutBuilder_ == null) { - return timeout_ == null ? com.google.protobuf.Duration.getDefaultInstance() : timeout_; - } else { - return timeoutBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Amount of time that this build should be allowed to run, to second
-     * granularity. If this amount of time elapses, work on the build will cease
-     * and the build status will be `TIMEOUT`.
-     * `timeout` starts ticking from `startTime`.
-     * Default time is ten minutes.
-     * 
- * - * .google.protobuf.Duration timeout = 12; - */ - public Builder setTimeout(com.google.protobuf.Duration value) { - if (timeoutBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - timeout_ = value; - onChanged(); - } else { - timeoutBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * Amount of time that this build should be allowed to run, to second
-     * granularity. If this amount of time elapses, work on the build will cease
-     * and the build status will be `TIMEOUT`.
-     * `timeout` starts ticking from `startTime`.
-     * Default time is ten minutes.
-     * 
- * - * .google.protobuf.Duration timeout = 12; - */ - public Builder setTimeout(com.google.protobuf.Duration.Builder builderForValue) { - if (timeoutBuilder_ == null) { - timeout_ = builderForValue.build(); - onChanged(); - } else { - timeoutBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Amount of time that this build should be allowed to run, to second
-     * granularity. If this amount of time elapses, work on the build will cease
-     * and the build status will be `TIMEOUT`.
-     * `timeout` starts ticking from `startTime`.
-     * Default time is ten minutes.
-     * 
- * - * .google.protobuf.Duration timeout = 12; - */ - public Builder mergeTimeout(com.google.protobuf.Duration value) { - if (timeoutBuilder_ == null) { - if (timeout_ != null) { - timeout_ = - com.google.protobuf.Duration.newBuilder(timeout_).mergeFrom(value).buildPartial(); - } else { - timeout_ = value; - } - onChanged(); - } else { - timeoutBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * Amount of time that this build should be allowed to run, to second
-     * granularity. If this amount of time elapses, work on the build will cease
-     * and the build status will be `TIMEOUT`.
-     * `timeout` starts ticking from `startTime`.
-     * Default time is ten minutes.
-     * 
- * - * .google.protobuf.Duration timeout = 12; - */ - public Builder clearTimeout() { - if (timeoutBuilder_ == null) { - timeout_ = null; - onChanged(); - } else { - timeout_ = null; - timeoutBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Amount of time that this build should be allowed to run, to second
-     * granularity. If this amount of time elapses, work on the build will cease
-     * and the build status will be `TIMEOUT`.
-     * `timeout` starts ticking from `startTime`.
-     * Default time is ten minutes.
-     * 
- * - * .google.protobuf.Duration timeout = 12; - */ - public com.google.protobuf.Duration.Builder getTimeoutBuilder() { - - onChanged(); - return getTimeoutFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Amount of time that this build should be allowed to run, to second
-     * granularity. If this amount of time elapses, work on the build will cease
-     * and the build status will be `TIMEOUT`.
-     * `timeout` starts ticking from `startTime`.
-     * Default time is ten minutes.
-     * 
- * - * .google.protobuf.Duration timeout = 12; - */ - public com.google.protobuf.DurationOrBuilder getTimeoutOrBuilder() { - if (timeoutBuilder_ != null) { - return timeoutBuilder_.getMessageOrBuilder(); - } else { - return timeout_ == null ? com.google.protobuf.Duration.getDefaultInstance() : timeout_; - } - } - /** - * - * - *
-     * Amount of time that this build should be allowed to run, to second
-     * granularity. If this amount of time elapses, work on the build will cease
-     * and the build status will be `TIMEOUT`.
-     * `timeout` starts ticking from `startTime`.
-     * Default time is ten minutes.
-     * 
- * - * .google.protobuf.Duration timeout = 12; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Duration, - com.google.protobuf.Duration.Builder, - com.google.protobuf.DurationOrBuilder> - getTimeoutFieldBuilder() { - if (timeoutBuilder_ == null) { - timeoutBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Duration, - com.google.protobuf.Duration.Builder, - com.google.protobuf.DurationOrBuilder>( - getTimeout(), getParentForChildren(), isClean()); - timeout_ = null; - } - return timeoutBuilder_; - } - - private com.google.protobuf.LazyStringList images_ = - com.google.protobuf.LazyStringArrayList.EMPTY; - - private void ensureImagesIsMutable() { - if (!((bitField0_ & 0x00000002) != 0)) { - images_ = new com.google.protobuf.LazyStringArrayList(images_); - bitField0_ |= 0x00000002; - } - } - /** - * - * - *
-     * A list of images to be pushed upon the successful completion of all build
-     * steps.
-     * The images are pushed using the builder service account's credentials.
-     * The digests of the pushed images will be stored in the `Build` resource's
-     * results field.
-     * If any of the images fail to be pushed, the build status is marked
-     * `FAILURE`.
-     * 
- * - * repeated string images = 13; - * - * @return A list containing the images. - */ - public com.google.protobuf.ProtocolStringList getImagesList() { - return images_.getUnmodifiableView(); - } - /** - * - * - *
-     * A list of images to be pushed upon the successful completion of all build
-     * steps.
-     * The images are pushed using the builder service account's credentials.
-     * The digests of the pushed images will be stored in the `Build` resource's
-     * results field.
-     * If any of the images fail to be pushed, the build status is marked
-     * `FAILURE`.
-     * 
- * - * repeated string images = 13; - * - * @return The count of images. - */ - public int getImagesCount() { - return images_.size(); - } - /** - * - * - *
-     * A list of images to be pushed upon the successful completion of all build
-     * steps.
-     * The images are pushed using the builder service account's credentials.
-     * The digests of the pushed images will be stored in the `Build` resource's
-     * results field.
-     * If any of the images fail to be pushed, the build status is marked
-     * `FAILURE`.
-     * 
- * - * repeated string images = 13; - * - * @param index The index of the element to return. - * @return The images at the given index. - */ - public java.lang.String getImages(int index) { - return images_.get(index); - } - /** - * - * - *
-     * A list of images to be pushed upon the successful completion of all build
-     * steps.
-     * The images are pushed using the builder service account's credentials.
-     * The digests of the pushed images will be stored in the `Build` resource's
-     * results field.
-     * If any of the images fail to be pushed, the build status is marked
-     * `FAILURE`.
-     * 
- * - * repeated string images = 13; - * - * @param index The index of the value to return. - * @return The bytes of the images at the given index. - */ - public com.google.protobuf.ByteString getImagesBytes(int index) { - return images_.getByteString(index); - } - /** - * - * - *
-     * A list of images to be pushed upon the successful completion of all build
-     * steps.
-     * The images are pushed using the builder service account's credentials.
-     * The digests of the pushed images will be stored in the `Build` resource's
-     * results field.
-     * If any of the images fail to be pushed, the build status is marked
-     * `FAILURE`.
-     * 
- * - * repeated string images = 13; - * - * @param index The index to set the value at. - * @param value The images to set. - * @return This builder for chaining. - */ - public Builder setImages(int index, java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureImagesIsMutable(); - images_.set(index, value); - onChanged(); - return this; - } - /** - * - * - *
-     * A list of images to be pushed upon the successful completion of all build
-     * steps.
-     * The images are pushed using the builder service account's credentials.
-     * The digests of the pushed images will be stored in the `Build` resource's
-     * results field.
-     * If any of the images fail to be pushed, the build status is marked
-     * `FAILURE`.
-     * 
- * - * repeated string images = 13; - * - * @param value The images to add. - * @return This builder for chaining. - */ - public Builder addImages(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureImagesIsMutable(); - images_.add(value); - onChanged(); - return this; - } - /** - * - * - *
-     * A list of images to be pushed upon the successful completion of all build
-     * steps.
-     * The images are pushed using the builder service account's credentials.
-     * The digests of the pushed images will be stored in the `Build` resource's
-     * results field.
-     * If any of the images fail to be pushed, the build status is marked
-     * `FAILURE`.
-     * 
- * - * repeated string images = 13; - * - * @param values The images to add. - * @return This builder for chaining. - */ - public Builder addAllImages(java.lang.Iterable values) { - ensureImagesIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, images_); - onChanged(); - return this; - } - /** - * - * - *
-     * A list of images to be pushed upon the successful completion of all build
-     * steps.
-     * The images are pushed using the builder service account's credentials.
-     * The digests of the pushed images will be stored in the `Build` resource's
-     * results field.
-     * If any of the images fail to be pushed, the build status is marked
-     * `FAILURE`.
-     * 
- * - * repeated string images = 13; - * - * @return This builder for chaining. - */ - public Builder clearImages() { - images_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000002); - onChanged(); - return this; - } - /** - * - * - *
-     * A list of images to be pushed upon the successful completion of all build
-     * steps.
-     * The images are pushed using the builder service account's credentials.
-     * The digests of the pushed images will be stored in the `Build` resource's
-     * results field.
-     * If any of the images fail to be pushed, the build status is marked
-     * `FAILURE`.
-     * 
- * - * repeated string images = 13; - * - * @param value The bytes of the images to add. - * @return This builder for chaining. - */ - public Builder addImagesBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - ensureImagesIsMutable(); - images_.add(value); - onChanged(); - return this; - } - - private com.google.protobuf.Duration queueTtl_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Duration, - com.google.protobuf.Duration.Builder, - com.google.protobuf.DurationOrBuilder> - queueTtlBuilder_; - /** - * - * - *
-     * TTL in queue for this build. If provided and the build is enqueued longer
-     * than this value, the build will expire and the build status will be
-     * `EXPIRED`.
-     * The TTL starts ticking from create_time.
-     * 
- * - * .google.protobuf.Duration queue_ttl = 40; - * - * @return Whether the queueTtl field is set. - */ - public boolean hasQueueTtl() { - return queueTtlBuilder_ != null || queueTtl_ != null; - } - /** - * - * - *
-     * TTL in queue for this build. If provided and the build is enqueued longer
-     * than this value, the build will expire and the build status will be
-     * `EXPIRED`.
-     * The TTL starts ticking from create_time.
-     * 
- * - * .google.protobuf.Duration queue_ttl = 40; - * - * @return The queueTtl. - */ - public com.google.protobuf.Duration getQueueTtl() { - if (queueTtlBuilder_ == null) { - return queueTtl_ == null ? com.google.protobuf.Duration.getDefaultInstance() : queueTtl_; - } else { - return queueTtlBuilder_.getMessage(); - } - } - /** - * - * - *
-     * TTL in queue for this build. If provided and the build is enqueued longer
-     * than this value, the build will expire and the build status will be
-     * `EXPIRED`.
-     * The TTL starts ticking from create_time.
-     * 
- * - * .google.protobuf.Duration queue_ttl = 40; - */ - public Builder setQueueTtl(com.google.protobuf.Duration value) { - if (queueTtlBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - queueTtl_ = value; - onChanged(); - } else { - queueTtlBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * TTL in queue for this build. If provided and the build is enqueued longer
-     * than this value, the build will expire and the build status will be
-     * `EXPIRED`.
-     * The TTL starts ticking from create_time.
-     * 
- * - * .google.protobuf.Duration queue_ttl = 40; - */ - public Builder setQueueTtl(com.google.protobuf.Duration.Builder builderForValue) { - if (queueTtlBuilder_ == null) { - queueTtl_ = builderForValue.build(); - onChanged(); - } else { - queueTtlBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * TTL in queue for this build. If provided and the build is enqueued longer
-     * than this value, the build will expire and the build status will be
-     * `EXPIRED`.
-     * The TTL starts ticking from create_time.
-     * 
- * - * .google.protobuf.Duration queue_ttl = 40; - */ - public Builder mergeQueueTtl(com.google.protobuf.Duration value) { - if (queueTtlBuilder_ == null) { - if (queueTtl_ != null) { - queueTtl_ = - com.google.protobuf.Duration.newBuilder(queueTtl_).mergeFrom(value).buildPartial(); - } else { - queueTtl_ = value; - } - onChanged(); - } else { - queueTtlBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * TTL in queue for this build. If provided and the build is enqueued longer
-     * than this value, the build will expire and the build status will be
-     * `EXPIRED`.
-     * The TTL starts ticking from create_time.
-     * 
- * - * .google.protobuf.Duration queue_ttl = 40; - */ - public Builder clearQueueTtl() { - if (queueTtlBuilder_ == null) { - queueTtl_ = null; - onChanged(); - } else { - queueTtl_ = null; - queueTtlBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * TTL in queue for this build. If provided and the build is enqueued longer
-     * than this value, the build will expire and the build status will be
-     * `EXPIRED`.
-     * The TTL starts ticking from create_time.
-     * 
- * - * .google.protobuf.Duration queue_ttl = 40; - */ - public com.google.protobuf.Duration.Builder getQueueTtlBuilder() { - - onChanged(); - return getQueueTtlFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * TTL in queue for this build. If provided and the build is enqueued longer
-     * than this value, the build will expire and the build status will be
-     * `EXPIRED`.
-     * The TTL starts ticking from create_time.
-     * 
- * - * .google.protobuf.Duration queue_ttl = 40; - */ - public com.google.protobuf.DurationOrBuilder getQueueTtlOrBuilder() { - if (queueTtlBuilder_ != null) { - return queueTtlBuilder_.getMessageOrBuilder(); - } else { - return queueTtl_ == null ? com.google.protobuf.Duration.getDefaultInstance() : queueTtl_; - } - } - /** - * - * - *
-     * TTL in queue for this build. If provided and the build is enqueued longer
-     * than this value, the build will expire and the build status will be
-     * `EXPIRED`.
-     * The TTL starts ticking from create_time.
-     * 
- * - * .google.protobuf.Duration queue_ttl = 40; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Duration, - com.google.protobuf.Duration.Builder, - com.google.protobuf.DurationOrBuilder> - getQueueTtlFieldBuilder() { - if (queueTtlBuilder_ == null) { - queueTtlBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Duration, - com.google.protobuf.Duration.Builder, - com.google.protobuf.DurationOrBuilder>( - getQueueTtl(), getParentForChildren(), isClean()); - queueTtl_ = null; - } - return queueTtlBuilder_; - } - - private com.google.cloudbuild.v1.Artifacts artifacts_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.Artifacts, - com.google.cloudbuild.v1.Artifacts.Builder, - com.google.cloudbuild.v1.ArtifactsOrBuilder> - artifactsBuilder_; - /** - * - * - *
-     * Artifacts produced by the build that should be uploaded upon
-     * successful completion of all build steps.
-     * 
- * - * .google.devtools.cloudbuild.v1.Artifacts artifacts = 37; - * - * @return Whether the artifacts field is set. - */ - public boolean hasArtifacts() { - return artifactsBuilder_ != null || artifacts_ != null; - } - /** - * - * - *
-     * Artifacts produced by the build that should be uploaded upon
-     * successful completion of all build steps.
-     * 
- * - * .google.devtools.cloudbuild.v1.Artifacts artifacts = 37; - * - * @return The artifacts. - */ - public com.google.cloudbuild.v1.Artifacts getArtifacts() { - if (artifactsBuilder_ == null) { - return artifacts_ == null - ? com.google.cloudbuild.v1.Artifacts.getDefaultInstance() - : artifacts_; - } else { - return artifactsBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Artifacts produced by the build that should be uploaded upon
-     * successful completion of all build steps.
-     * 
- * - * .google.devtools.cloudbuild.v1.Artifacts artifacts = 37; - */ - public Builder setArtifacts(com.google.cloudbuild.v1.Artifacts value) { - if (artifactsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - artifacts_ = value; - onChanged(); - } else { - artifactsBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * Artifacts produced by the build that should be uploaded upon
-     * successful completion of all build steps.
-     * 
- * - * .google.devtools.cloudbuild.v1.Artifacts artifacts = 37; - */ - public Builder setArtifacts(com.google.cloudbuild.v1.Artifacts.Builder builderForValue) { - if (artifactsBuilder_ == null) { - artifacts_ = builderForValue.build(); - onChanged(); - } else { - artifactsBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Artifacts produced by the build that should be uploaded upon
-     * successful completion of all build steps.
-     * 
- * - * .google.devtools.cloudbuild.v1.Artifacts artifacts = 37; - */ - public Builder mergeArtifacts(com.google.cloudbuild.v1.Artifacts value) { - if (artifactsBuilder_ == null) { - if (artifacts_ != null) { - artifacts_ = - com.google.cloudbuild.v1.Artifacts.newBuilder(artifacts_) - .mergeFrom(value) - .buildPartial(); - } else { - artifacts_ = value; - } - onChanged(); - } else { - artifactsBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * Artifacts produced by the build that should be uploaded upon
-     * successful completion of all build steps.
-     * 
- * - * .google.devtools.cloudbuild.v1.Artifacts artifacts = 37; - */ - public Builder clearArtifacts() { - if (artifactsBuilder_ == null) { - artifacts_ = null; - onChanged(); - } else { - artifacts_ = null; - artifactsBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Artifacts produced by the build that should be uploaded upon
-     * successful completion of all build steps.
-     * 
- * - * .google.devtools.cloudbuild.v1.Artifacts artifacts = 37; - */ - public com.google.cloudbuild.v1.Artifacts.Builder getArtifactsBuilder() { - - onChanged(); - return getArtifactsFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Artifacts produced by the build that should be uploaded upon
-     * successful completion of all build steps.
-     * 
- * - * .google.devtools.cloudbuild.v1.Artifacts artifacts = 37; - */ - public com.google.cloudbuild.v1.ArtifactsOrBuilder getArtifactsOrBuilder() { - if (artifactsBuilder_ != null) { - return artifactsBuilder_.getMessageOrBuilder(); - } else { - return artifacts_ == null - ? com.google.cloudbuild.v1.Artifacts.getDefaultInstance() - : artifacts_; - } - } - /** - * - * - *
-     * Artifacts produced by the build that should be uploaded upon
-     * successful completion of all build steps.
-     * 
- * - * .google.devtools.cloudbuild.v1.Artifacts artifacts = 37; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.Artifacts, - com.google.cloudbuild.v1.Artifacts.Builder, - com.google.cloudbuild.v1.ArtifactsOrBuilder> - getArtifactsFieldBuilder() { - if (artifactsBuilder_ == null) { - artifactsBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.Artifacts, - com.google.cloudbuild.v1.Artifacts.Builder, - com.google.cloudbuild.v1.ArtifactsOrBuilder>( - getArtifacts(), getParentForChildren(), isClean()); - artifacts_ = null; - } - return artifactsBuilder_; - } - - private java.lang.Object logsBucket_ = ""; - /** - * - * - *
-     * Google Cloud Storage bucket where logs should be written (see
-     * [Bucket Name
-     * Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)).
-     * Logs file names will be of the format `${logs_bucket}/log-${build_id}.txt`.
-     * 
- * - * string logs_bucket = 19; - * - * @return The logsBucket. - */ - public java.lang.String getLogsBucket() { - java.lang.Object ref = logsBucket_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - logsBucket_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Google Cloud Storage bucket where logs should be written (see
-     * [Bucket Name
-     * Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)).
-     * Logs file names will be of the format `${logs_bucket}/log-${build_id}.txt`.
-     * 
- * - * string logs_bucket = 19; - * - * @return The bytes for logsBucket. - */ - public com.google.protobuf.ByteString getLogsBucketBytes() { - java.lang.Object ref = logsBucket_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - logsBucket_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Google Cloud Storage bucket where logs should be written (see
-     * [Bucket Name
-     * Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)).
-     * Logs file names will be of the format `${logs_bucket}/log-${build_id}.txt`.
-     * 
- * - * string logs_bucket = 19; - * - * @param value The logsBucket to set. - * @return This builder for chaining. - */ - public Builder setLogsBucket(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - logsBucket_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Google Cloud Storage bucket where logs should be written (see
-     * [Bucket Name
-     * Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)).
-     * Logs file names will be of the format `${logs_bucket}/log-${build_id}.txt`.
-     * 
- * - * string logs_bucket = 19; - * - * @return This builder for chaining. - */ - public Builder clearLogsBucket() { - - logsBucket_ = getDefaultInstance().getLogsBucket(); - onChanged(); - return this; - } - /** - * - * - *
-     * Google Cloud Storage bucket where logs should be written (see
-     * [Bucket Name
-     * Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)).
-     * Logs file names will be of the format `${logs_bucket}/log-${build_id}.txt`.
-     * 
- * - * string logs_bucket = 19; - * - * @param value The bytes for logsBucket to set. - * @return This builder for chaining. - */ - public Builder setLogsBucketBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - logsBucket_ = value; - onChanged(); - return this; - } - - private com.google.cloudbuild.v1.SourceProvenance sourceProvenance_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.SourceProvenance, - com.google.cloudbuild.v1.SourceProvenance.Builder, - com.google.cloudbuild.v1.SourceProvenanceOrBuilder> - sourceProvenanceBuilder_; - /** - * - * - *
-     * Output only. A permanent fixed identifier for source.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.SourceProvenance source_provenance = 21 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return Whether the sourceProvenance field is set. - */ - public boolean hasSourceProvenance() { - return sourceProvenanceBuilder_ != null || sourceProvenance_ != null; - } - /** - * - * - *
-     * Output only. A permanent fixed identifier for source.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.SourceProvenance source_provenance = 21 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The sourceProvenance. - */ - public com.google.cloudbuild.v1.SourceProvenance getSourceProvenance() { - if (sourceProvenanceBuilder_ == null) { - return sourceProvenance_ == null - ? com.google.cloudbuild.v1.SourceProvenance.getDefaultInstance() - : sourceProvenance_; - } else { - return sourceProvenanceBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Output only. A permanent fixed identifier for source.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.SourceProvenance source_provenance = 21 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder setSourceProvenance(com.google.cloudbuild.v1.SourceProvenance value) { - if (sourceProvenanceBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - sourceProvenance_ = value; - onChanged(); - } else { - sourceProvenanceBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * Output only. A permanent fixed identifier for source.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.SourceProvenance source_provenance = 21 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder setSourceProvenance( - com.google.cloudbuild.v1.SourceProvenance.Builder builderForValue) { - if (sourceProvenanceBuilder_ == null) { - sourceProvenance_ = builderForValue.build(); - onChanged(); - } else { - sourceProvenanceBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Output only. A permanent fixed identifier for source.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.SourceProvenance source_provenance = 21 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder mergeSourceProvenance(com.google.cloudbuild.v1.SourceProvenance value) { - if (sourceProvenanceBuilder_ == null) { - if (sourceProvenance_ != null) { - sourceProvenance_ = - com.google.cloudbuild.v1.SourceProvenance.newBuilder(sourceProvenance_) - .mergeFrom(value) - .buildPartial(); - } else { - sourceProvenance_ = value; - } - onChanged(); - } else { - sourceProvenanceBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * Output only. A permanent fixed identifier for source.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.SourceProvenance source_provenance = 21 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder clearSourceProvenance() { - if (sourceProvenanceBuilder_ == null) { - sourceProvenance_ = null; - onChanged(); - } else { - sourceProvenance_ = null; - sourceProvenanceBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Output only. A permanent fixed identifier for source.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.SourceProvenance source_provenance = 21 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public com.google.cloudbuild.v1.SourceProvenance.Builder getSourceProvenanceBuilder() { - - onChanged(); - return getSourceProvenanceFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Output only. A permanent fixed identifier for source.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.SourceProvenance source_provenance = 21 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public com.google.cloudbuild.v1.SourceProvenanceOrBuilder getSourceProvenanceOrBuilder() { - if (sourceProvenanceBuilder_ != null) { - return sourceProvenanceBuilder_.getMessageOrBuilder(); - } else { - return sourceProvenance_ == null - ? com.google.cloudbuild.v1.SourceProvenance.getDefaultInstance() - : sourceProvenance_; - } - } - /** - * - * - *
-     * Output only. A permanent fixed identifier for source.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.SourceProvenance source_provenance = 21 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.SourceProvenance, - com.google.cloudbuild.v1.SourceProvenance.Builder, - com.google.cloudbuild.v1.SourceProvenanceOrBuilder> - getSourceProvenanceFieldBuilder() { - if (sourceProvenanceBuilder_ == null) { - sourceProvenanceBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.SourceProvenance, - com.google.cloudbuild.v1.SourceProvenance.Builder, - com.google.cloudbuild.v1.SourceProvenanceOrBuilder>( - getSourceProvenance(), getParentForChildren(), isClean()); - sourceProvenance_ = null; - } - return sourceProvenanceBuilder_; - } - - private java.lang.Object buildTriggerId_ = ""; - /** - * - * - *
-     * Output only. The ID of the `BuildTrigger` that triggered this build, if it
-     * was triggered automatically.
-     * 
- * - * string build_trigger_id = 22 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The buildTriggerId. - */ - public java.lang.String getBuildTriggerId() { - java.lang.Object ref = buildTriggerId_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - buildTriggerId_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Output only. The ID of the `BuildTrigger` that triggered this build, if it
-     * was triggered automatically.
-     * 
- * - * string build_trigger_id = 22 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The bytes for buildTriggerId. - */ - public com.google.protobuf.ByteString getBuildTriggerIdBytes() { - java.lang.Object ref = buildTriggerId_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - buildTriggerId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Output only. The ID of the `BuildTrigger` that triggered this build, if it
-     * was triggered automatically.
-     * 
- * - * string build_trigger_id = 22 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @param value The buildTriggerId to set. - * @return This builder for chaining. - */ - public Builder setBuildTriggerId(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - buildTriggerId_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. The ID of the `BuildTrigger` that triggered this build, if it
-     * was triggered automatically.
-     * 
- * - * string build_trigger_id = 22 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return This builder for chaining. - */ - public Builder clearBuildTriggerId() { - - buildTriggerId_ = getDefaultInstance().getBuildTriggerId(); - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. The ID of the `BuildTrigger` that triggered this build, if it
-     * was triggered automatically.
-     * 
- * - * string build_trigger_id = 22 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @param value The bytes for buildTriggerId to set. - * @return This builder for chaining. - */ - public Builder setBuildTriggerIdBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - buildTriggerId_ = value; - onChanged(); - return this; - } - - private com.google.cloudbuild.v1.BuildOptions options_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.BuildOptions, - com.google.cloudbuild.v1.BuildOptions.Builder, - com.google.cloudbuild.v1.BuildOptionsOrBuilder> - optionsBuilder_; - /** - * - * - *
-     * Special options for this build.
-     * 
- * - * .google.devtools.cloudbuild.v1.BuildOptions options = 23; - * - * @return Whether the options field is set. - */ - public boolean hasOptions() { - return optionsBuilder_ != null || options_ != null; - } - /** - * - * - *
-     * Special options for this build.
-     * 
- * - * .google.devtools.cloudbuild.v1.BuildOptions options = 23; - * - * @return The options. - */ - public com.google.cloudbuild.v1.BuildOptions getOptions() { - if (optionsBuilder_ == null) { - return options_ == null - ? com.google.cloudbuild.v1.BuildOptions.getDefaultInstance() - : options_; - } else { - return optionsBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Special options for this build.
-     * 
- * - * .google.devtools.cloudbuild.v1.BuildOptions options = 23; - */ - public Builder setOptions(com.google.cloudbuild.v1.BuildOptions value) { - if (optionsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - options_ = value; - onChanged(); - } else { - optionsBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * Special options for this build.
-     * 
- * - * .google.devtools.cloudbuild.v1.BuildOptions options = 23; - */ - public Builder setOptions(com.google.cloudbuild.v1.BuildOptions.Builder builderForValue) { - if (optionsBuilder_ == null) { - options_ = builderForValue.build(); - onChanged(); - } else { - optionsBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Special options for this build.
-     * 
- * - * .google.devtools.cloudbuild.v1.BuildOptions options = 23; - */ - public Builder mergeOptions(com.google.cloudbuild.v1.BuildOptions value) { - if (optionsBuilder_ == null) { - if (options_ != null) { - options_ = - com.google.cloudbuild.v1.BuildOptions.newBuilder(options_) - .mergeFrom(value) - .buildPartial(); - } else { - options_ = value; - } - onChanged(); - } else { - optionsBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * Special options for this build.
-     * 
- * - * .google.devtools.cloudbuild.v1.BuildOptions options = 23; - */ - public Builder clearOptions() { - if (optionsBuilder_ == null) { - options_ = null; - onChanged(); - } else { - options_ = null; - optionsBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Special options for this build.
-     * 
- * - * .google.devtools.cloudbuild.v1.BuildOptions options = 23; - */ - public com.google.cloudbuild.v1.BuildOptions.Builder getOptionsBuilder() { - - onChanged(); - return getOptionsFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Special options for this build.
-     * 
- * - * .google.devtools.cloudbuild.v1.BuildOptions options = 23; - */ - public com.google.cloudbuild.v1.BuildOptionsOrBuilder getOptionsOrBuilder() { - if (optionsBuilder_ != null) { - return optionsBuilder_.getMessageOrBuilder(); - } else { - return options_ == null - ? com.google.cloudbuild.v1.BuildOptions.getDefaultInstance() - : options_; - } - } - /** - * - * - *
-     * Special options for this build.
-     * 
- * - * .google.devtools.cloudbuild.v1.BuildOptions options = 23; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.BuildOptions, - com.google.cloudbuild.v1.BuildOptions.Builder, - com.google.cloudbuild.v1.BuildOptionsOrBuilder> - getOptionsFieldBuilder() { - if (optionsBuilder_ == null) { - optionsBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.BuildOptions, - com.google.cloudbuild.v1.BuildOptions.Builder, - com.google.cloudbuild.v1.BuildOptionsOrBuilder>( - getOptions(), getParentForChildren(), isClean()); - options_ = null; - } - return optionsBuilder_; - } - - private java.lang.Object logUrl_ = ""; - /** - * - * - *
-     * Output only. URL to logs for this build in Google Cloud Console.
-     * 
- * - * string log_url = 25 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The logUrl. - */ - public java.lang.String getLogUrl() { - java.lang.Object ref = logUrl_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - logUrl_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Output only. URL to logs for this build in Google Cloud Console.
-     * 
- * - * string log_url = 25 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The bytes for logUrl. - */ - public com.google.protobuf.ByteString getLogUrlBytes() { - java.lang.Object ref = logUrl_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - logUrl_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Output only. URL to logs for this build in Google Cloud Console.
-     * 
- * - * string log_url = 25 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @param value The logUrl to set. - * @return This builder for chaining. - */ - public Builder setLogUrl(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - logUrl_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. URL to logs for this build in Google Cloud Console.
-     * 
- * - * string log_url = 25 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return This builder for chaining. - */ - public Builder clearLogUrl() { - - logUrl_ = getDefaultInstance().getLogUrl(); - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. URL to logs for this build in Google Cloud Console.
-     * 
- * - * string log_url = 25 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @param value The bytes for logUrl to set. - * @return This builder for chaining. - */ - public Builder setLogUrlBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - logUrl_ = value; - onChanged(); - return this; - } - - private com.google.protobuf.MapField substitutions_; - - private com.google.protobuf.MapField - internalGetSubstitutions() { - if (substitutions_ == null) { - return com.google.protobuf.MapField.emptyMapField( - SubstitutionsDefaultEntryHolder.defaultEntry); - } - return substitutions_; - } - - private com.google.protobuf.MapField - internalGetMutableSubstitutions() { - onChanged(); - ; - if (substitutions_ == null) { - substitutions_ = - com.google.protobuf.MapField.newMapField(SubstitutionsDefaultEntryHolder.defaultEntry); - } - if (!substitutions_.isMutable()) { - substitutions_ = substitutions_.copy(); - } - return substitutions_; - } - - public int getSubstitutionsCount() { - return internalGetSubstitutions().getMap().size(); - } - /** - * - * - *
-     * Substitutions data for `Build` resource.
-     * 
- * - * map<string, string> substitutions = 29; - */ - @java.lang.Override - public boolean containsSubstitutions(java.lang.String key) { - if (key == null) { - throw new NullPointerException("map key"); - } - return internalGetSubstitutions().getMap().containsKey(key); - } - /** Use {@link #getSubstitutionsMap()} instead. */ - @java.lang.Override - @java.lang.Deprecated - public java.util.Map getSubstitutions() { - return getSubstitutionsMap(); - } - /** - * - * - *
-     * Substitutions data for `Build` resource.
-     * 
- * - * map<string, string> substitutions = 29; - */ - @java.lang.Override - public java.util.Map getSubstitutionsMap() { - return internalGetSubstitutions().getMap(); - } - /** - * - * - *
-     * Substitutions data for `Build` resource.
-     * 
- * - * map<string, string> substitutions = 29; - */ - @java.lang.Override - public java.lang.String getSubstitutionsOrDefault( - java.lang.String key, java.lang.String defaultValue) { - if (key == null) { - throw new NullPointerException("map key"); - } - java.util.Map map = internalGetSubstitutions().getMap(); - return map.containsKey(key) ? map.get(key) : defaultValue; - } - /** - * - * - *
-     * Substitutions data for `Build` resource.
-     * 
- * - * map<string, string> substitutions = 29; - */ - @java.lang.Override - public java.lang.String getSubstitutionsOrThrow(java.lang.String key) { - if (key == null) { - throw new NullPointerException("map key"); - } - java.util.Map map = internalGetSubstitutions().getMap(); - if (!map.containsKey(key)) { - throw new java.lang.IllegalArgumentException(); - } - return map.get(key); - } - - public Builder clearSubstitutions() { - internalGetMutableSubstitutions().getMutableMap().clear(); - return this; - } - /** - * - * - *
-     * Substitutions data for `Build` resource.
-     * 
- * - * map<string, string> substitutions = 29; - */ - public Builder removeSubstitutions(java.lang.String key) { - if (key == null) { - throw new NullPointerException("map key"); - } - internalGetMutableSubstitutions().getMutableMap().remove(key); - return this; - } - /** Use alternate mutation accessors instead. */ - @java.lang.Deprecated - public java.util.Map getMutableSubstitutions() { - return internalGetMutableSubstitutions().getMutableMap(); - } - /** - * - * - *
-     * Substitutions data for `Build` resource.
-     * 
- * - * map<string, string> substitutions = 29; - */ - public Builder putSubstitutions(java.lang.String key, java.lang.String value) { - if (key == null) { - throw new NullPointerException("map key"); - } - if (value == null) { - throw new NullPointerException("map value"); - } - - internalGetMutableSubstitutions().getMutableMap().put(key, value); - return this; - } - /** - * - * - *
-     * Substitutions data for `Build` resource.
-     * 
- * - * map<string, string> substitutions = 29; - */ - public Builder putAllSubstitutions(java.util.Map values) { - internalGetMutableSubstitutions().getMutableMap().putAll(values); - return this; - } - - private com.google.protobuf.LazyStringList tags_ = - com.google.protobuf.LazyStringArrayList.EMPTY; - - private void ensureTagsIsMutable() { - if (!((bitField0_ & 0x00000008) != 0)) { - tags_ = new com.google.protobuf.LazyStringArrayList(tags_); - bitField0_ |= 0x00000008; - } - } - /** - * - * - *
-     * Tags for annotation of a `Build`. These are not docker tags.
-     * 
- * - * repeated string tags = 31; - * - * @return A list containing the tags. - */ - public com.google.protobuf.ProtocolStringList getTagsList() { - return tags_.getUnmodifiableView(); - } - /** - * - * - *
-     * Tags for annotation of a `Build`. These are not docker tags.
-     * 
- * - * repeated string tags = 31; - * - * @return The count of tags. - */ - public int getTagsCount() { - return tags_.size(); - } - /** - * - * - *
-     * Tags for annotation of a `Build`. These are not docker tags.
-     * 
- * - * repeated string tags = 31; - * - * @param index The index of the element to return. - * @return The tags at the given index. - */ - public java.lang.String getTags(int index) { - return tags_.get(index); - } - /** - * - * - *
-     * Tags for annotation of a `Build`. These are not docker tags.
-     * 
- * - * repeated string tags = 31; - * - * @param index The index of the value to return. - * @return The bytes of the tags at the given index. - */ - public com.google.protobuf.ByteString getTagsBytes(int index) { - return tags_.getByteString(index); - } - /** - * - * - *
-     * Tags for annotation of a `Build`. These are not docker tags.
-     * 
- * - * repeated string tags = 31; - * - * @param index The index to set the value at. - * @param value The tags to set. - * @return This builder for chaining. - */ - public Builder setTags(int index, java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureTagsIsMutable(); - tags_.set(index, value); - onChanged(); - return this; - } - /** - * - * - *
-     * Tags for annotation of a `Build`. These are not docker tags.
-     * 
- * - * repeated string tags = 31; - * - * @param value The tags to add. - * @return This builder for chaining. - */ - public Builder addTags(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureTagsIsMutable(); - tags_.add(value); - onChanged(); - return this; - } - /** - * - * - *
-     * Tags for annotation of a `Build`. These are not docker tags.
-     * 
- * - * repeated string tags = 31; - * - * @param values The tags to add. - * @return This builder for chaining. - */ - public Builder addAllTags(java.lang.Iterable values) { - ensureTagsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, tags_); - onChanged(); - return this; - } - /** - * - * - *
-     * Tags for annotation of a `Build`. These are not docker tags.
-     * 
- * - * repeated string tags = 31; - * - * @return This builder for chaining. - */ - public Builder clearTags() { - tags_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000008); - onChanged(); - return this; - } - /** - * - * - *
-     * Tags for annotation of a `Build`. These are not docker tags.
-     * 
- * - * repeated string tags = 31; - * - * @param value The bytes of the tags to add. - * @return This builder for chaining. - */ - public Builder addTagsBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - ensureTagsIsMutable(); - tags_.add(value); - onChanged(); - return this; - } - - private java.util.List secrets_ = - java.util.Collections.emptyList(); - - private void ensureSecretsIsMutable() { - if (!((bitField0_ & 0x00000010) != 0)) { - secrets_ = new java.util.ArrayList(secrets_); - bitField0_ |= 0x00000010; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloudbuild.v1.Secret, - com.google.cloudbuild.v1.Secret.Builder, - com.google.cloudbuild.v1.SecretOrBuilder> - secretsBuilder_; - - /** - * - * - *
-     * Secrets to decrypt using Cloud Key Management Service.
-     * Note: Secret Manager is the recommended technique
-     * for managing sensitive data with Cloud Build. Use `available_secrets` to
-     * configure builds to access secrets from Secret Manager. For instructions,
-     * see: https://cloud.google.com/cloud-build/docs/securing-builds/use-secrets
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Secret secrets = 32; - */ - public java.util.List getSecretsList() { - if (secretsBuilder_ == null) { - return java.util.Collections.unmodifiableList(secrets_); - } else { - return secretsBuilder_.getMessageList(); - } - } - /** - * - * - *
-     * Secrets to decrypt using Cloud Key Management Service.
-     * Note: Secret Manager is the recommended technique
-     * for managing sensitive data with Cloud Build. Use `available_secrets` to
-     * configure builds to access secrets from Secret Manager. For instructions,
-     * see: https://cloud.google.com/cloud-build/docs/securing-builds/use-secrets
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Secret secrets = 32; - */ - public int getSecretsCount() { - if (secretsBuilder_ == null) { - return secrets_.size(); - } else { - return secretsBuilder_.getCount(); - } - } - /** - * - * - *
-     * Secrets to decrypt using Cloud Key Management Service.
-     * Note: Secret Manager is the recommended technique
-     * for managing sensitive data with Cloud Build. Use `available_secrets` to
-     * configure builds to access secrets from Secret Manager. For instructions,
-     * see: https://cloud.google.com/cloud-build/docs/securing-builds/use-secrets
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Secret secrets = 32; - */ - public com.google.cloudbuild.v1.Secret getSecrets(int index) { - if (secretsBuilder_ == null) { - return secrets_.get(index); - } else { - return secretsBuilder_.getMessage(index); - } - } - /** - * - * - *
-     * Secrets to decrypt using Cloud Key Management Service.
-     * Note: Secret Manager is the recommended technique
-     * for managing sensitive data with Cloud Build. Use `available_secrets` to
-     * configure builds to access secrets from Secret Manager. For instructions,
-     * see: https://cloud.google.com/cloud-build/docs/securing-builds/use-secrets
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Secret secrets = 32; - */ - public Builder setSecrets(int index, com.google.cloudbuild.v1.Secret value) { - if (secretsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureSecretsIsMutable(); - secrets_.set(index, value); - onChanged(); - } else { - secretsBuilder_.setMessage(index, value); - } - return this; - } - /** - * - * - *
-     * Secrets to decrypt using Cloud Key Management Service.
-     * Note: Secret Manager is the recommended technique
-     * for managing sensitive data with Cloud Build. Use `available_secrets` to
-     * configure builds to access secrets from Secret Manager. For instructions,
-     * see: https://cloud.google.com/cloud-build/docs/securing-builds/use-secrets
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Secret secrets = 32; - */ - public Builder setSecrets(int index, com.google.cloudbuild.v1.Secret.Builder builderForValue) { - if (secretsBuilder_ == null) { - ensureSecretsIsMutable(); - secrets_.set(index, builderForValue.build()); - onChanged(); - } else { - secretsBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * Secrets to decrypt using Cloud Key Management Service.
-     * Note: Secret Manager is the recommended technique
-     * for managing sensitive data with Cloud Build. Use `available_secrets` to
-     * configure builds to access secrets from Secret Manager. For instructions,
-     * see: https://cloud.google.com/cloud-build/docs/securing-builds/use-secrets
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Secret secrets = 32; - */ - public Builder addSecrets(com.google.cloudbuild.v1.Secret value) { - if (secretsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureSecretsIsMutable(); - secrets_.add(value); - onChanged(); - } else { - secretsBuilder_.addMessage(value); - } - return this; - } - /** - * - * - *
-     * Secrets to decrypt using Cloud Key Management Service.
-     * Note: Secret Manager is the recommended technique
-     * for managing sensitive data with Cloud Build. Use `available_secrets` to
-     * configure builds to access secrets from Secret Manager. For instructions,
-     * see: https://cloud.google.com/cloud-build/docs/securing-builds/use-secrets
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Secret secrets = 32; - */ - public Builder addSecrets(int index, com.google.cloudbuild.v1.Secret value) { - if (secretsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureSecretsIsMutable(); - secrets_.add(index, value); - onChanged(); - } else { - secretsBuilder_.addMessage(index, value); - } - return this; - } - /** - * - * - *
-     * Secrets to decrypt using Cloud Key Management Service.
-     * Note: Secret Manager is the recommended technique
-     * for managing sensitive data with Cloud Build. Use `available_secrets` to
-     * configure builds to access secrets from Secret Manager. For instructions,
-     * see: https://cloud.google.com/cloud-build/docs/securing-builds/use-secrets
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Secret secrets = 32; - */ - public Builder addSecrets(com.google.cloudbuild.v1.Secret.Builder builderForValue) { - if (secretsBuilder_ == null) { - ensureSecretsIsMutable(); - secrets_.add(builderForValue.build()); - onChanged(); - } else { - secretsBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * Secrets to decrypt using Cloud Key Management Service.
-     * Note: Secret Manager is the recommended technique
-     * for managing sensitive data with Cloud Build. Use `available_secrets` to
-     * configure builds to access secrets from Secret Manager. For instructions,
-     * see: https://cloud.google.com/cloud-build/docs/securing-builds/use-secrets
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Secret secrets = 32; - */ - public Builder addSecrets(int index, com.google.cloudbuild.v1.Secret.Builder builderForValue) { - if (secretsBuilder_ == null) { - ensureSecretsIsMutable(); - secrets_.add(index, builderForValue.build()); - onChanged(); - } else { - secretsBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * Secrets to decrypt using Cloud Key Management Service.
-     * Note: Secret Manager is the recommended technique
-     * for managing sensitive data with Cloud Build. Use `available_secrets` to
-     * configure builds to access secrets from Secret Manager. For instructions,
-     * see: https://cloud.google.com/cloud-build/docs/securing-builds/use-secrets
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Secret secrets = 32; - */ - public Builder addAllSecrets( - java.lang.Iterable values) { - if (secretsBuilder_ == null) { - ensureSecretsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, secrets_); - onChanged(); - } else { - secretsBuilder_.addAllMessages(values); - } - return this; - } - /** - * - * - *
-     * Secrets to decrypt using Cloud Key Management Service.
-     * Note: Secret Manager is the recommended technique
-     * for managing sensitive data with Cloud Build. Use `available_secrets` to
-     * configure builds to access secrets from Secret Manager. For instructions,
-     * see: https://cloud.google.com/cloud-build/docs/securing-builds/use-secrets
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Secret secrets = 32; - */ - public Builder clearSecrets() { - if (secretsBuilder_ == null) { - secrets_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000010); - onChanged(); - } else { - secretsBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * Secrets to decrypt using Cloud Key Management Service.
-     * Note: Secret Manager is the recommended technique
-     * for managing sensitive data with Cloud Build. Use `available_secrets` to
-     * configure builds to access secrets from Secret Manager. For instructions,
-     * see: https://cloud.google.com/cloud-build/docs/securing-builds/use-secrets
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Secret secrets = 32; - */ - public Builder removeSecrets(int index) { - if (secretsBuilder_ == null) { - ensureSecretsIsMutable(); - secrets_.remove(index); - onChanged(); - } else { - secretsBuilder_.remove(index); - } - return this; - } - /** - * - * - *
-     * Secrets to decrypt using Cloud Key Management Service.
-     * Note: Secret Manager is the recommended technique
-     * for managing sensitive data with Cloud Build. Use `available_secrets` to
-     * configure builds to access secrets from Secret Manager. For instructions,
-     * see: https://cloud.google.com/cloud-build/docs/securing-builds/use-secrets
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Secret secrets = 32; - */ - public com.google.cloudbuild.v1.Secret.Builder getSecretsBuilder(int index) { - return getSecretsFieldBuilder().getBuilder(index); - } - /** - * - * - *
-     * Secrets to decrypt using Cloud Key Management Service.
-     * Note: Secret Manager is the recommended technique
-     * for managing sensitive data with Cloud Build. Use `available_secrets` to
-     * configure builds to access secrets from Secret Manager. For instructions,
-     * see: https://cloud.google.com/cloud-build/docs/securing-builds/use-secrets
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Secret secrets = 32; - */ - public com.google.cloudbuild.v1.SecretOrBuilder getSecretsOrBuilder(int index) { - if (secretsBuilder_ == null) { - return secrets_.get(index); - } else { - return secretsBuilder_.getMessageOrBuilder(index); - } - } - /** - * - * - *
-     * Secrets to decrypt using Cloud Key Management Service.
-     * Note: Secret Manager is the recommended technique
-     * for managing sensitive data with Cloud Build. Use `available_secrets` to
-     * configure builds to access secrets from Secret Manager. For instructions,
-     * see: https://cloud.google.com/cloud-build/docs/securing-builds/use-secrets
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Secret secrets = 32; - */ - public java.util.List - getSecretsOrBuilderList() { - if (secretsBuilder_ != null) { - return secretsBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(secrets_); - } - } - /** - * - * - *
-     * Secrets to decrypt using Cloud Key Management Service.
-     * Note: Secret Manager is the recommended technique
-     * for managing sensitive data with Cloud Build. Use `available_secrets` to
-     * configure builds to access secrets from Secret Manager. For instructions,
-     * see: https://cloud.google.com/cloud-build/docs/securing-builds/use-secrets
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Secret secrets = 32; - */ - public com.google.cloudbuild.v1.Secret.Builder addSecretsBuilder() { - return getSecretsFieldBuilder() - .addBuilder(com.google.cloudbuild.v1.Secret.getDefaultInstance()); - } - /** - * - * - *
-     * Secrets to decrypt using Cloud Key Management Service.
-     * Note: Secret Manager is the recommended technique
-     * for managing sensitive data with Cloud Build. Use `available_secrets` to
-     * configure builds to access secrets from Secret Manager. For instructions,
-     * see: https://cloud.google.com/cloud-build/docs/securing-builds/use-secrets
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Secret secrets = 32; - */ - public com.google.cloudbuild.v1.Secret.Builder addSecretsBuilder(int index) { - return getSecretsFieldBuilder() - .addBuilder(index, com.google.cloudbuild.v1.Secret.getDefaultInstance()); - } - /** - * - * - *
-     * Secrets to decrypt using Cloud Key Management Service.
-     * Note: Secret Manager is the recommended technique
-     * for managing sensitive data with Cloud Build. Use `available_secrets` to
-     * configure builds to access secrets from Secret Manager. For instructions,
-     * see: https://cloud.google.com/cloud-build/docs/securing-builds/use-secrets
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Secret secrets = 32; - */ - public java.util.List getSecretsBuilderList() { - return getSecretsFieldBuilder().getBuilderList(); - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloudbuild.v1.Secret, - com.google.cloudbuild.v1.Secret.Builder, - com.google.cloudbuild.v1.SecretOrBuilder> - getSecretsFieldBuilder() { - if (secretsBuilder_ == null) { - secretsBuilder_ = - new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloudbuild.v1.Secret, - com.google.cloudbuild.v1.Secret.Builder, - com.google.cloudbuild.v1.SecretOrBuilder>( - secrets_, ((bitField0_ & 0x00000010) != 0), getParentForChildren(), isClean()); - secrets_ = null; - } - return secretsBuilder_; - } - - private com.google.protobuf.MapField - timing_; - - private com.google.protobuf.MapField - internalGetTiming() { - if (timing_ == null) { - return com.google.protobuf.MapField.emptyMapField(TimingDefaultEntryHolder.defaultEntry); - } - return timing_; - } - - private com.google.protobuf.MapField - internalGetMutableTiming() { - onChanged(); - ; - if (timing_ == null) { - timing_ = com.google.protobuf.MapField.newMapField(TimingDefaultEntryHolder.defaultEntry); - } - if (!timing_.isMutable()) { - timing_ = timing_.copy(); - } - return timing_; - } - - public int getTimingCount() { - return internalGetTiming().getMap().size(); - } - /** - * - * - *
-     * Output only. Stores timing information for phases of the build. Valid keys
-     * are:
-     * * BUILD: time to execute all build steps.
-     * * PUSH: time to push all specified images.
-     * * FETCHSOURCE: time to fetch source.
-     * * SETUPBUILD: time to set up build.
-     * If the build does not specify source or images,
-     * these keys will not be included.
-     * 
- * - * - * map<string, .google.devtools.cloudbuild.v1.TimeSpan> timing = 33 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - @java.lang.Override - public boolean containsTiming(java.lang.String key) { - if (key == null) { - throw new NullPointerException("map key"); - } - return internalGetTiming().getMap().containsKey(key); - } - /** Use {@link #getTimingMap()} instead. */ - @java.lang.Override - @java.lang.Deprecated - public java.util.Map getTiming() { - return getTimingMap(); - } - /** - * - * - *
-     * Output only. Stores timing information for phases of the build. Valid keys
-     * are:
-     * * BUILD: time to execute all build steps.
-     * * PUSH: time to push all specified images.
-     * * FETCHSOURCE: time to fetch source.
-     * * SETUPBUILD: time to set up build.
-     * If the build does not specify source or images,
-     * these keys will not be included.
-     * 
- * - * - * map<string, .google.devtools.cloudbuild.v1.TimeSpan> timing = 33 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - @java.lang.Override - public java.util.Map getTimingMap() { - return internalGetTiming().getMap(); - } - /** - * - * - *
-     * Output only. Stores timing information for phases of the build. Valid keys
-     * are:
-     * * BUILD: time to execute all build steps.
-     * * PUSH: time to push all specified images.
-     * * FETCHSOURCE: time to fetch source.
-     * * SETUPBUILD: time to set up build.
-     * If the build does not specify source or images,
-     * these keys will not be included.
-     * 
- * - * - * map<string, .google.devtools.cloudbuild.v1.TimeSpan> timing = 33 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - @java.lang.Override - public com.google.cloudbuild.v1.TimeSpan getTimingOrDefault( - java.lang.String key, com.google.cloudbuild.v1.TimeSpan defaultValue) { - if (key == null) { - throw new NullPointerException("map key"); - } - java.util.Map map = - internalGetTiming().getMap(); - return map.containsKey(key) ? map.get(key) : defaultValue; - } - /** - * - * - *
-     * Output only. Stores timing information for phases of the build. Valid keys
-     * are:
-     * * BUILD: time to execute all build steps.
-     * * PUSH: time to push all specified images.
-     * * FETCHSOURCE: time to fetch source.
-     * * SETUPBUILD: time to set up build.
-     * If the build does not specify source or images,
-     * these keys will not be included.
-     * 
- * - * - * map<string, .google.devtools.cloudbuild.v1.TimeSpan> timing = 33 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - @java.lang.Override - public com.google.cloudbuild.v1.TimeSpan getTimingOrThrow(java.lang.String key) { - if (key == null) { - throw new NullPointerException("map key"); - } - java.util.Map map = - internalGetTiming().getMap(); - if (!map.containsKey(key)) { - throw new java.lang.IllegalArgumentException(); - } - return map.get(key); - } - - public Builder clearTiming() { - internalGetMutableTiming().getMutableMap().clear(); - return this; - } - /** - * - * - *
-     * Output only. Stores timing information for phases of the build. Valid keys
-     * are:
-     * * BUILD: time to execute all build steps.
-     * * PUSH: time to push all specified images.
-     * * FETCHSOURCE: time to fetch source.
-     * * SETUPBUILD: time to set up build.
-     * If the build does not specify source or images,
-     * these keys will not be included.
-     * 
- * - * - * map<string, .google.devtools.cloudbuild.v1.TimeSpan> timing = 33 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder removeTiming(java.lang.String key) { - if (key == null) { - throw new NullPointerException("map key"); - } - internalGetMutableTiming().getMutableMap().remove(key); - return this; - } - /** Use alternate mutation accessors instead. */ - @java.lang.Deprecated - public java.util.Map getMutableTiming() { - return internalGetMutableTiming().getMutableMap(); - } - /** - * - * - *
-     * Output only. Stores timing information for phases of the build. Valid keys
-     * are:
-     * * BUILD: time to execute all build steps.
-     * * PUSH: time to push all specified images.
-     * * FETCHSOURCE: time to fetch source.
-     * * SETUPBUILD: time to set up build.
-     * If the build does not specify source or images,
-     * these keys will not be included.
-     * 
- * - * - * map<string, .google.devtools.cloudbuild.v1.TimeSpan> timing = 33 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder putTiming(java.lang.String key, com.google.cloudbuild.v1.TimeSpan value) { - if (key == null) { - throw new NullPointerException("map key"); - } - if (value == null) { - throw new NullPointerException("map value"); - } - - internalGetMutableTiming().getMutableMap().put(key, value); - return this; - } - /** - * - * - *
-     * Output only. Stores timing information for phases of the build. Valid keys
-     * are:
-     * * BUILD: time to execute all build steps.
-     * * PUSH: time to push all specified images.
-     * * FETCHSOURCE: time to fetch source.
-     * * SETUPBUILD: time to set up build.
-     * If the build does not specify source or images,
-     * these keys will not be included.
-     * 
- * - * - * map<string, .google.devtools.cloudbuild.v1.TimeSpan> timing = 33 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder putAllTiming( - java.util.Map values) { - internalGetMutableTiming().getMutableMap().putAll(values); - return this; - } - - private com.google.cloudbuild.v1.BuildApproval approval_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.BuildApproval, - com.google.cloudbuild.v1.BuildApproval.Builder, - com.google.cloudbuild.v1.BuildApprovalOrBuilder> - approvalBuilder_; - /** - * - * - *
-     * Output only. Describes this build's approval configuration, status,
-     * and result.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.BuildApproval approval = 44 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return Whether the approval field is set. - */ - public boolean hasApproval() { - return approvalBuilder_ != null || approval_ != null; - } - /** - * - * - *
-     * Output only. Describes this build's approval configuration, status,
-     * and result.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.BuildApproval approval = 44 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The approval. - */ - public com.google.cloudbuild.v1.BuildApproval getApproval() { - if (approvalBuilder_ == null) { - return approval_ == null - ? com.google.cloudbuild.v1.BuildApproval.getDefaultInstance() - : approval_; - } else { - return approvalBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Output only. Describes this build's approval configuration, status,
-     * and result.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.BuildApproval approval = 44 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder setApproval(com.google.cloudbuild.v1.BuildApproval value) { - if (approvalBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - approval_ = value; - onChanged(); - } else { - approvalBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * Output only. Describes this build's approval configuration, status,
-     * and result.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.BuildApproval approval = 44 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder setApproval(com.google.cloudbuild.v1.BuildApproval.Builder builderForValue) { - if (approvalBuilder_ == null) { - approval_ = builderForValue.build(); - onChanged(); - } else { - approvalBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Output only. Describes this build's approval configuration, status,
-     * and result.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.BuildApproval approval = 44 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder mergeApproval(com.google.cloudbuild.v1.BuildApproval value) { - if (approvalBuilder_ == null) { - if (approval_ != null) { - approval_ = - com.google.cloudbuild.v1.BuildApproval.newBuilder(approval_) - .mergeFrom(value) - .buildPartial(); - } else { - approval_ = value; - } - onChanged(); - } else { - approvalBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * Output only. Describes this build's approval configuration, status,
-     * and result.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.BuildApproval approval = 44 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder clearApproval() { - if (approvalBuilder_ == null) { - approval_ = null; - onChanged(); - } else { - approval_ = null; - approvalBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Output only. Describes this build's approval configuration, status,
-     * and result.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.BuildApproval approval = 44 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public com.google.cloudbuild.v1.BuildApproval.Builder getApprovalBuilder() { - - onChanged(); - return getApprovalFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Output only. Describes this build's approval configuration, status,
-     * and result.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.BuildApproval approval = 44 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public com.google.cloudbuild.v1.BuildApprovalOrBuilder getApprovalOrBuilder() { - if (approvalBuilder_ != null) { - return approvalBuilder_.getMessageOrBuilder(); - } else { - return approval_ == null - ? com.google.cloudbuild.v1.BuildApproval.getDefaultInstance() - : approval_; - } - } - /** - * - * - *
-     * Output only. Describes this build's approval configuration, status,
-     * and result.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.BuildApproval approval = 44 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.BuildApproval, - com.google.cloudbuild.v1.BuildApproval.Builder, - com.google.cloudbuild.v1.BuildApprovalOrBuilder> - getApprovalFieldBuilder() { - if (approvalBuilder_ == null) { - approvalBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.BuildApproval, - com.google.cloudbuild.v1.BuildApproval.Builder, - com.google.cloudbuild.v1.BuildApprovalOrBuilder>( - getApproval(), getParentForChildren(), isClean()); - approval_ = null; - } - return approvalBuilder_; - } - - private java.lang.Object serviceAccount_ = ""; - /** - * - * - *
-     * IAM service account whose credentials will be used at build runtime.
-     * Must be of the format `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`.
-     * ACCOUNT can be email address or uniqueId of the service account.
-     * 
- * - * string service_account = 42 [(.google.api.resource_reference) = { ... } - * - * @return The serviceAccount. - */ - public java.lang.String getServiceAccount() { - java.lang.Object ref = serviceAccount_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - serviceAccount_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * IAM service account whose credentials will be used at build runtime.
-     * Must be of the format `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`.
-     * ACCOUNT can be email address or uniqueId of the service account.
-     * 
- * - * string service_account = 42 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for serviceAccount. - */ - public com.google.protobuf.ByteString getServiceAccountBytes() { - java.lang.Object ref = serviceAccount_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - serviceAccount_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * IAM service account whose credentials will be used at build runtime.
-     * Must be of the format `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`.
-     * ACCOUNT can be email address or uniqueId of the service account.
-     * 
- * - * string service_account = 42 [(.google.api.resource_reference) = { ... } - * - * @param value The serviceAccount to set. - * @return This builder for chaining. - */ - public Builder setServiceAccount(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - serviceAccount_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * IAM service account whose credentials will be used at build runtime.
-     * Must be of the format `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`.
-     * ACCOUNT can be email address or uniqueId of the service account.
-     * 
- * - * string service_account = 42 [(.google.api.resource_reference) = { ... } - * - * @return This builder for chaining. - */ - public Builder clearServiceAccount() { - - serviceAccount_ = getDefaultInstance().getServiceAccount(); - onChanged(); - return this; - } - /** - * - * - *
-     * IAM service account whose credentials will be used at build runtime.
-     * Must be of the format `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`.
-     * ACCOUNT can be email address or uniqueId of the service account.
-     * 
- * - * string service_account = 42 [(.google.api.resource_reference) = { ... } - * - * @param value The bytes for serviceAccount to set. - * @return This builder for chaining. - */ - public Builder setServiceAccountBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - serviceAccount_ = value; - onChanged(); - return this; - } - - private com.google.cloudbuild.v1.Secrets availableSecrets_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.Secrets, - com.google.cloudbuild.v1.Secrets.Builder, - com.google.cloudbuild.v1.SecretsOrBuilder> - availableSecretsBuilder_; - /** - * - * - *
-     * Secrets and secret environment variables.
-     * 
- * - * .google.devtools.cloudbuild.v1.Secrets available_secrets = 47; - * - * @return Whether the availableSecrets field is set. - */ - public boolean hasAvailableSecrets() { - return availableSecretsBuilder_ != null || availableSecrets_ != null; - } - /** - * - * - *
-     * Secrets and secret environment variables.
-     * 
- * - * .google.devtools.cloudbuild.v1.Secrets available_secrets = 47; - * - * @return The availableSecrets. - */ - public com.google.cloudbuild.v1.Secrets getAvailableSecrets() { - if (availableSecretsBuilder_ == null) { - return availableSecrets_ == null - ? com.google.cloudbuild.v1.Secrets.getDefaultInstance() - : availableSecrets_; - } else { - return availableSecretsBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Secrets and secret environment variables.
-     * 
- * - * .google.devtools.cloudbuild.v1.Secrets available_secrets = 47; - */ - public Builder setAvailableSecrets(com.google.cloudbuild.v1.Secrets value) { - if (availableSecretsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - availableSecrets_ = value; - onChanged(); - } else { - availableSecretsBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * Secrets and secret environment variables.
-     * 
- * - * .google.devtools.cloudbuild.v1.Secrets available_secrets = 47; - */ - public Builder setAvailableSecrets(com.google.cloudbuild.v1.Secrets.Builder builderForValue) { - if (availableSecretsBuilder_ == null) { - availableSecrets_ = builderForValue.build(); - onChanged(); - } else { - availableSecretsBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Secrets and secret environment variables.
-     * 
- * - * .google.devtools.cloudbuild.v1.Secrets available_secrets = 47; - */ - public Builder mergeAvailableSecrets(com.google.cloudbuild.v1.Secrets value) { - if (availableSecretsBuilder_ == null) { - if (availableSecrets_ != null) { - availableSecrets_ = - com.google.cloudbuild.v1.Secrets.newBuilder(availableSecrets_) - .mergeFrom(value) - .buildPartial(); - } else { - availableSecrets_ = value; - } - onChanged(); - } else { - availableSecretsBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * Secrets and secret environment variables.
-     * 
- * - * .google.devtools.cloudbuild.v1.Secrets available_secrets = 47; - */ - public Builder clearAvailableSecrets() { - if (availableSecretsBuilder_ == null) { - availableSecrets_ = null; - onChanged(); - } else { - availableSecrets_ = null; - availableSecretsBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Secrets and secret environment variables.
-     * 
- * - * .google.devtools.cloudbuild.v1.Secrets available_secrets = 47; - */ - public com.google.cloudbuild.v1.Secrets.Builder getAvailableSecretsBuilder() { - - onChanged(); - return getAvailableSecretsFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Secrets and secret environment variables.
-     * 
- * - * .google.devtools.cloudbuild.v1.Secrets available_secrets = 47; - */ - public com.google.cloudbuild.v1.SecretsOrBuilder getAvailableSecretsOrBuilder() { - if (availableSecretsBuilder_ != null) { - return availableSecretsBuilder_.getMessageOrBuilder(); - } else { - return availableSecrets_ == null - ? com.google.cloudbuild.v1.Secrets.getDefaultInstance() - : availableSecrets_; - } - } - /** - * - * - *
-     * Secrets and secret environment variables.
-     * 
- * - * .google.devtools.cloudbuild.v1.Secrets available_secrets = 47; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.Secrets, - com.google.cloudbuild.v1.Secrets.Builder, - com.google.cloudbuild.v1.SecretsOrBuilder> - getAvailableSecretsFieldBuilder() { - if (availableSecretsBuilder_ == null) { - availableSecretsBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.Secrets, - com.google.cloudbuild.v1.Secrets.Builder, - com.google.cloudbuild.v1.SecretsOrBuilder>( - getAvailableSecrets(), getParentForChildren(), isClean()); - availableSecrets_ = null; - } - return availableSecretsBuilder_; - } - - private java.util.List warnings_ = - java.util.Collections.emptyList(); - - private void ensureWarningsIsMutable() { - if (!((bitField0_ & 0x00000040) != 0)) { - warnings_ = new java.util.ArrayList(warnings_); - bitField0_ |= 0x00000040; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloudbuild.v1.Build.Warning, - com.google.cloudbuild.v1.Build.Warning.Builder, - com.google.cloudbuild.v1.Build.WarningOrBuilder> - warningsBuilder_; - - /** - * - * - *
-     * Output only. Non-fatal problems encountered during the execution of the
-     * build.
-     * 
- * - * - * repeated .google.devtools.cloudbuild.v1.Build.Warning warnings = 49 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public java.util.List getWarningsList() { - if (warningsBuilder_ == null) { - return java.util.Collections.unmodifiableList(warnings_); - } else { - return warningsBuilder_.getMessageList(); - } - } - /** - * - * - *
-     * Output only. Non-fatal problems encountered during the execution of the
-     * build.
-     * 
- * - * - * repeated .google.devtools.cloudbuild.v1.Build.Warning warnings = 49 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public int getWarningsCount() { - if (warningsBuilder_ == null) { - return warnings_.size(); - } else { - return warningsBuilder_.getCount(); - } - } - /** - * - * - *
-     * Output only. Non-fatal problems encountered during the execution of the
-     * build.
-     * 
- * - * - * repeated .google.devtools.cloudbuild.v1.Build.Warning warnings = 49 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public com.google.cloudbuild.v1.Build.Warning getWarnings(int index) { - if (warningsBuilder_ == null) { - return warnings_.get(index); - } else { - return warningsBuilder_.getMessage(index); - } - } - /** - * - * - *
-     * Output only. Non-fatal problems encountered during the execution of the
-     * build.
-     * 
- * - * - * repeated .google.devtools.cloudbuild.v1.Build.Warning warnings = 49 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder setWarnings(int index, com.google.cloudbuild.v1.Build.Warning value) { - if (warningsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureWarningsIsMutable(); - warnings_.set(index, value); - onChanged(); - } else { - warningsBuilder_.setMessage(index, value); - } - return this; - } - /** - * - * - *
-     * Output only. Non-fatal problems encountered during the execution of the
-     * build.
-     * 
- * - * - * repeated .google.devtools.cloudbuild.v1.Build.Warning warnings = 49 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder setWarnings( - int index, com.google.cloudbuild.v1.Build.Warning.Builder builderForValue) { - if (warningsBuilder_ == null) { - ensureWarningsIsMutable(); - warnings_.set(index, builderForValue.build()); - onChanged(); - } else { - warningsBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * Output only. Non-fatal problems encountered during the execution of the
-     * build.
-     * 
- * - * - * repeated .google.devtools.cloudbuild.v1.Build.Warning warnings = 49 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder addWarnings(com.google.cloudbuild.v1.Build.Warning value) { - if (warningsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureWarningsIsMutable(); - warnings_.add(value); - onChanged(); - } else { - warningsBuilder_.addMessage(value); - } - return this; - } - /** - * - * - *
-     * Output only. Non-fatal problems encountered during the execution of the
-     * build.
-     * 
- * - * - * repeated .google.devtools.cloudbuild.v1.Build.Warning warnings = 49 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder addWarnings(int index, com.google.cloudbuild.v1.Build.Warning value) { - if (warningsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureWarningsIsMutable(); - warnings_.add(index, value); - onChanged(); - } else { - warningsBuilder_.addMessage(index, value); - } - return this; - } - /** - * - * - *
-     * Output only. Non-fatal problems encountered during the execution of the
-     * build.
-     * 
- * - * - * repeated .google.devtools.cloudbuild.v1.Build.Warning warnings = 49 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder addWarnings(com.google.cloudbuild.v1.Build.Warning.Builder builderForValue) { - if (warningsBuilder_ == null) { - ensureWarningsIsMutable(); - warnings_.add(builderForValue.build()); - onChanged(); - } else { - warningsBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * Output only. Non-fatal problems encountered during the execution of the
-     * build.
-     * 
- * - * - * repeated .google.devtools.cloudbuild.v1.Build.Warning warnings = 49 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder addWarnings( - int index, com.google.cloudbuild.v1.Build.Warning.Builder builderForValue) { - if (warningsBuilder_ == null) { - ensureWarningsIsMutable(); - warnings_.add(index, builderForValue.build()); - onChanged(); - } else { - warningsBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * Output only. Non-fatal problems encountered during the execution of the
-     * build.
-     * 
- * - * - * repeated .google.devtools.cloudbuild.v1.Build.Warning warnings = 49 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder addAllWarnings( - java.lang.Iterable values) { - if (warningsBuilder_ == null) { - ensureWarningsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, warnings_); - onChanged(); - } else { - warningsBuilder_.addAllMessages(values); - } - return this; - } - /** - * - * - *
-     * Output only. Non-fatal problems encountered during the execution of the
-     * build.
-     * 
- * - * - * repeated .google.devtools.cloudbuild.v1.Build.Warning warnings = 49 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder clearWarnings() { - if (warningsBuilder_ == null) { - warnings_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000040); - onChanged(); - } else { - warningsBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * Output only. Non-fatal problems encountered during the execution of the
-     * build.
-     * 
- * - * - * repeated .google.devtools.cloudbuild.v1.Build.Warning warnings = 49 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder removeWarnings(int index) { - if (warningsBuilder_ == null) { - ensureWarningsIsMutable(); - warnings_.remove(index); - onChanged(); - } else { - warningsBuilder_.remove(index); - } - return this; - } - /** - * - * - *
-     * Output only. Non-fatal problems encountered during the execution of the
-     * build.
-     * 
- * - * - * repeated .google.devtools.cloudbuild.v1.Build.Warning warnings = 49 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public com.google.cloudbuild.v1.Build.Warning.Builder getWarningsBuilder(int index) { - return getWarningsFieldBuilder().getBuilder(index); - } - /** - * - * - *
-     * Output only. Non-fatal problems encountered during the execution of the
-     * build.
-     * 
- * - * - * repeated .google.devtools.cloudbuild.v1.Build.Warning warnings = 49 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public com.google.cloudbuild.v1.Build.WarningOrBuilder getWarningsOrBuilder(int index) { - if (warningsBuilder_ == null) { - return warnings_.get(index); - } else { - return warningsBuilder_.getMessageOrBuilder(index); - } - } - /** - * - * - *
-     * Output only. Non-fatal problems encountered during the execution of the
-     * build.
-     * 
- * - * - * repeated .google.devtools.cloudbuild.v1.Build.Warning warnings = 49 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public java.util.List - getWarningsOrBuilderList() { - if (warningsBuilder_ != null) { - return warningsBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(warnings_); - } - } - /** - * - * - *
-     * Output only. Non-fatal problems encountered during the execution of the
-     * build.
-     * 
- * - * - * repeated .google.devtools.cloudbuild.v1.Build.Warning warnings = 49 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public com.google.cloudbuild.v1.Build.Warning.Builder addWarningsBuilder() { - return getWarningsFieldBuilder() - .addBuilder(com.google.cloudbuild.v1.Build.Warning.getDefaultInstance()); - } - /** - * - * - *
-     * Output only. Non-fatal problems encountered during the execution of the
-     * build.
-     * 
- * - * - * repeated .google.devtools.cloudbuild.v1.Build.Warning warnings = 49 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public com.google.cloudbuild.v1.Build.Warning.Builder addWarningsBuilder(int index) { - return getWarningsFieldBuilder() - .addBuilder(index, com.google.cloudbuild.v1.Build.Warning.getDefaultInstance()); - } - /** - * - * - *
-     * Output only. Non-fatal problems encountered during the execution of the
-     * build.
-     * 
- * - * - * repeated .google.devtools.cloudbuild.v1.Build.Warning warnings = 49 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public java.util.List getWarningsBuilderList() { - return getWarningsFieldBuilder().getBuilderList(); - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloudbuild.v1.Build.Warning, - com.google.cloudbuild.v1.Build.Warning.Builder, - com.google.cloudbuild.v1.Build.WarningOrBuilder> - getWarningsFieldBuilder() { - if (warningsBuilder_ == null) { - warningsBuilder_ = - new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloudbuild.v1.Build.Warning, - com.google.cloudbuild.v1.Build.Warning.Builder, - com.google.cloudbuild.v1.Build.WarningOrBuilder>( - warnings_, ((bitField0_ & 0x00000040) != 0), getParentForChildren(), isClean()); - warnings_ = null; - } - return warningsBuilder_; - } - - private com.google.cloudbuild.v1.Build.FailureInfo failureInfo_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.Build.FailureInfo, - com.google.cloudbuild.v1.Build.FailureInfo.Builder, - com.google.cloudbuild.v1.Build.FailureInfoOrBuilder> - failureInfoBuilder_; - /** - * - * - *
-     * Output only. Contains information about the build when status=FAILURE.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.Build.FailureInfo failure_info = 51 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return Whether the failureInfo field is set. - */ - public boolean hasFailureInfo() { - return failureInfoBuilder_ != null || failureInfo_ != null; - } - /** - * - * - *
-     * Output only. Contains information about the build when status=FAILURE.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.Build.FailureInfo failure_info = 51 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The failureInfo. - */ - public com.google.cloudbuild.v1.Build.FailureInfo getFailureInfo() { - if (failureInfoBuilder_ == null) { - return failureInfo_ == null - ? com.google.cloudbuild.v1.Build.FailureInfo.getDefaultInstance() - : failureInfo_; - } else { - return failureInfoBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Output only. Contains information about the build when status=FAILURE.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.Build.FailureInfo failure_info = 51 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder setFailureInfo(com.google.cloudbuild.v1.Build.FailureInfo value) { - if (failureInfoBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - failureInfo_ = value; - onChanged(); - } else { - failureInfoBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * Output only. Contains information about the build when status=FAILURE.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.Build.FailureInfo failure_info = 51 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder setFailureInfo( - com.google.cloudbuild.v1.Build.FailureInfo.Builder builderForValue) { - if (failureInfoBuilder_ == null) { - failureInfo_ = builderForValue.build(); - onChanged(); - } else { - failureInfoBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Output only. Contains information about the build when status=FAILURE.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.Build.FailureInfo failure_info = 51 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder mergeFailureInfo(com.google.cloudbuild.v1.Build.FailureInfo value) { - if (failureInfoBuilder_ == null) { - if (failureInfo_ != null) { - failureInfo_ = - com.google.cloudbuild.v1.Build.FailureInfo.newBuilder(failureInfo_) - .mergeFrom(value) - .buildPartial(); - } else { - failureInfo_ = value; - } - onChanged(); - } else { - failureInfoBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * Output only. Contains information about the build when status=FAILURE.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.Build.FailureInfo failure_info = 51 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder clearFailureInfo() { - if (failureInfoBuilder_ == null) { - failureInfo_ = null; - onChanged(); - } else { - failureInfo_ = null; - failureInfoBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Output only. Contains information about the build when status=FAILURE.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.Build.FailureInfo failure_info = 51 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public com.google.cloudbuild.v1.Build.FailureInfo.Builder getFailureInfoBuilder() { - - onChanged(); - return getFailureInfoFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Output only. Contains information about the build when status=FAILURE.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.Build.FailureInfo failure_info = 51 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public com.google.cloudbuild.v1.Build.FailureInfoOrBuilder getFailureInfoOrBuilder() { - if (failureInfoBuilder_ != null) { - return failureInfoBuilder_.getMessageOrBuilder(); - } else { - return failureInfo_ == null - ? com.google.cloudbuild.v1.Build.FailureInfo.getDefaultInstance() - : failureInfo_; - } - } - /** - * - * - *
-     * Output only. Contains information about the build when status=FAILURE.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.Build.FailureInfo failure_info = 51 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.Build.FailureInfo, - com.google.cloudbuild.v1.Build.FailureInfo.Builder, - com.google.cloudbuild.v1.Build.FailureInfoOrBuilder> - getFailureInfoFieldBuilder() { - if (failureInfoBuilder_ == null) { - failureInfoBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.Build.FailureInfo, - com.google.cloudbuild.v1.Build.FailureInfo.Builder, - com.google.cloudbuild.v1.Build.FailureInfoOrBuilder>( - getFailureInfo(), getParentForChildren(), isClean()); - failureInfo_ = null; - } - return failureInfoBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.Build) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.Build) - private static final com.google.cloudbuild.v1.Build DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.Build(); - } - - public static com.google.cloudbuild.v1.Build getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public Build parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.Build getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildApproval.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildApproval.java deleted file mode 100644 index b1944729..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildApproval.java +++ /dev/null @@ -1,1379 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * BuildApproval describes a build's approval configuration, state, and
- * result.
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.BuildApproval} - */ -public final class BuildApproval extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.BuildApproval) - BuildApprovalOrBuilder { - private static final long serialVersionUID = 0L; - // Use BuildApproval.newBuilder() to construct. - private BuildApproval(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private BuildApproval() { - state_ = 0; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new BuildApproval(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_BuildApproval_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_BuildApproval_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.BuildApproval.class, - com.google.cloudbuild.v1.BuildApproval.Builder.class); - } - - /** - * - * - *
-   * Specifies the current state of a build's approval.
-   * 
- * - * Protobuf enum {@code google.devtools.cloudbuild.v1.BuildApproval.State} - */ - public enum State implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
-     * Default enum type. This should not be used.
-     * 
- * - * STATE_UNSPECIFIED = 0; - */ - STATE_UNSPECIFIED(0), - /** - * - * - *
-     * Build approval is pending.
-     * 
- * - * PENDING = 1; - */ - PENDING(1), - /** - * - * - *
-     * Build approval has been approved.
-     * 
- * - * APPROVED = 2; - */ - APPROVED(2), - /** - * - * - *
-     * Build approval has been rejected.
-     * 
- * - * REJECTED = 3; - */ - REJECTED(3), - /** - * - * - *
-     * Build was cancelled while it was still pending approval.
-     * 
- * - * CANCELLED = 5; - */ - CANCELLED(5), - UNRECOGNIZED(-1), - ; - - /** - * - * - *
-     * Default enum type. This should not be used.
-     * 
- * - * STATE_UNSPECIFIED = 0; - */ - public static final int STATE_UNSPECIFIED_VALUE = 0; - /** - * - * - *
-     * Build approval is pending.
-     * 
- * - * PENDING = 1; - */ - public static final int PENDING_VALUE = 1; - /** - * - * - *
-     * Build approval has been approved.
-     * 
- * - * APPROVED = 2; - */ - public static final int APPROVED_VALUE = 2; - /** - * - * - *
-     * Build approval has been rejected.
-     * 
- * - * REJECTED = 3; - */ - public static final int REJECTED_VALUE = 3; - /** - * - * - *
-     * Build was cancelled while it was still pending approval.
-     * 
- * - * CANCELLED = 5; - */ - public static final int CANCELLED_VALUE = 5; - - public final int getNumber() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalArgumentException( - "Can't get the number of an unknown enum value."); - } - return value; - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static State valueOf(int value) { - return forNumber(value); - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - */ - public static State forNumber(int value) { - switch (value) { - case 0: - return STATE_UNSPECIFIED; - case 1: - return PENDING; - case 2: - return APPROVED; - case 3: - return REJECTED; - case 5: - return CANCELLED; - default: - return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { - return internalValueMap; - } - - private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public State findValueByNumber(int number) { - return State.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalStateException( - "Can't get the descriptor of an unrecognized enum value."); - } - return getDescriptor().getValues().get(ordinal()); - } - - public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { - return getDescriptor(); - } - - public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return com.google.cloudbuild.v1.BuildApproval.getDescriptor().getEnumTypes().get(0); - } - - private static final State[] VALUES = values(); - - public static State valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); - } - if (desc.getIndex() == -1) { - return UNRECOGNIZED; - } - return VALUES[desc.getIndex()]; - } - - private final int value; - - private State(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:google.devtools.cloudbuild.v1.BuildApproval.State) - } - - public static final int STATE_FIELD_NUMBER = 1; - private int state_; - /** - * - * - *
-   * Output only. The state of this build's approval.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.BuildApproval.State state = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The enum numeric value on the wire for state. - */ - @java.lang.Override - public int getStateValue() { - return state_; - } - /** - * - * - *
-   * Output only. The state of this build's approval.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.BuildApproval.State state = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The state. - */ - @java.lang.Override - public com.google.cloudbuild.v1.BuildApproval.State getState() { - @SuppressWarnings("deprecation") - com.google.cloudbuild.v1.BuildApproval.State result = - com.google.cloudbuild.v1.BuildApproval.State.valueOf(state_); - return result == null ? com.google.cloudbuild.v1.BuildApproval.State.UNRECOGNIZED : result; - } - - public static final int CONFIG_FIELD_NUMBER = 2; - private com.google.cloudbuild.v1.ApprovalConfig config_; - /** - * - * - *
-   * Output only. Configuration for manual approval of this build.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.ApprovalConfig config = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return Whether the config field is set. - */ - @java.lang.Override - public boolean hasConfig() { - return config_ != null; - } - /** - * - * - *
-   * Output only. Configuration for manual approval of this build.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.ApprovalConfig config = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The config. - */ - @java.lang.Override - public com.google.cloudbuild.v1.ApprovalConfig getConfig() { - return config_ == null ? com.google.cloudbuild.v1.ApprovalConfig.getDefaultInstance() : config_; - } - /** - * - * - *
-   * Output only. Configuration for manual approval of this build.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.ApprovalConfig config = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - @java.lang.Override - public com.google.cloudbuild.v1.ApprovalConfigOrBuilder getConfigOrBuilder() { - return getConfig(); - } - - public static final int RESULT_FIELD_NUMBER = 3; - private com.google.cloudbuild.v1.ApprovalResult result_; - /** - * - * - *
-   * Output only. Result of manual approval for this Build.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.ApprovalResult result = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return Whether the result field is set. - */ - @java.lang.Override - public boolean hasResult() { - return result_ != null; - } - /** - * - * - *
-   * Output only. Result of manual approval for this Build.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.ApprovalResult result = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The result. - */ - @java.lang.Override - public com.google.cloudbuild.v1.ApprovalResult getResult() { - return result_ == null ? com.google.cloudbuild.v1.ApprovalResult.getDefaultInstance() : result_; - } - /** - * - * - *
-   * Output only. Result of manual approval for this Build.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.ApprovalResult result = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - @java.lang.Override - public com.google.cloudbuild.v1.ApprovalResultOrBuilder getResultOrBuilder() { - return getResult(); - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (state_ != com.google.cloudbuild.v1.BuildApproval.State.STATE_UNSPECIFIED.getNumber()) { - output.writeEnum(1, state_); - } - if (config_ != null) { - output.writeMessage(2, getConfig()); - } - if (result_ != null) { - output.writeMessage(3, getResult()); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (state_ != com.google.cloudbuild.v1.BuildApproval.State.STATE_UNSPECIFIED.getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, state_); - } - if (config_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getConfig()); - } - if (result_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getResult()); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.BuildApproval)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.BuildApproval other = (com.google.cloudbuild.v1.BuildApproval) obj; - - if (state_ != other.state_) return false; - if (hasConfig() != other.hasConfig()) return false; - if (hasConfig()) { - if (!getConfig().equals(other.getConfig())) return false; - } - if (hasResult() != other.hasResult()) return false; - if (hasResult()) { - if (!getResult().equals(other.getResult())) return false; - } - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + STATE_FIELD_NUMBER; - hash = (53 * hash) + state_; - if (hasConfig()) { - hash = (37 * hash) + CONFIG_FIELD_NUMBER; - hash = (53 * hash) + getConfig().hashCode(); - } - if (hasResult()) { - hash = (37 * hash) + RESULT_FIELD_NUMBER; - hash = (53 * hash) + getResult().hashCode(); - } - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.BuildApproval parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.BuildApproval parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.BuildApproval parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.BuildApproval parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.BuildApproval parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.BuildApproval parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.BuildApproval parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.BuildApproval parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.BuildApproval parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.BuildApproval parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.BuildApproval parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.BuildApproval parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.BuildApproval prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * BuildApproval describes a build's approval configuration, state, and
-   * result.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.BuildApproval} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.BuildApproval) - com.google.cloudbuild.v1.BuildApprovalOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_BuildApproval_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_BuildApproval_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.BuildApproval.class, - com.google.cloudbuild.v1.BuildApproval.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.BuildApproval.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - state_ = 0; - - if (configBuilder_ == null) { - config_ = null; - } else { - config_ = null; - configBuilder_ = null; - } - if (resultBuilder_ == null) { - result_ = null; - } else { - result_ = null; - resultBuilder_ = null; - } - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_BuildApproval_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.BuildApproval getDefaultInstanceForType() { - return com.google.cloudbuild.v1.BuildApproval.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.BuildApproval build() { - com.google.cloudbuild.v1.BuildApproval result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.BuildApproval buildPartial() { - com.google.cloudbuild.v1.BuildApproval result = - new com.google.cloudbuild.v1.BuildApproval(this); - result.state_ = state_; - if (configBuilder_ == null) { - result.config_ = config_; - } else { - result.config_ = configBuilder_.build(); - } - if (resultBuilder_ == null) { - result.result_ = result_; - } else { - result.result_ = resultBuilder_.build(); - } - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.BuildApproval) { - return mergeFrom((com.google.cloudbuild.v1.BuildApproval) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.BuildApproval other) { - if (other == com.google.cloudbuild.v1.BuildApproval.getDefaultInstance()) return this; - if (other.state_ != 0) { - setStateValue(other.getStateValue()); - } - if (other.hasConfig()) { - mergeConfig(other.getConfig()); - } - if (other.hasResult()) { - mergeResult(other.getResult()); - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 8: - { - state_ = input.readEnum(); - - break; - } // case 8 - case 18: - { - input.readMessage(getConfigFieldBuilder().getBuilder(), extensionRegistry); - - break; - } // case 18 - case 26: - { - input.readMessage(getResultFieldBuilder().getBuilder(), extensionRegistry); - - break; - } // case 26 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private int state_ = 0; - /** - * - * - *
-     * Output only. The state of this build's approval.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.BuildApproval.State state = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The enum numeric value on the wire for state. - */ - @java.lang.Override - public int getStateValue() { - return state_; - } - /** - * - * - *
-     * Output only. The state of this build's approval.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.BuildApproval.State state = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @param value The enum numeric value on the wire for state to set. - * @return This builder for chaining. - */ - public Builder setStateValue(int value) { - - state_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. The state of this build's approval.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.BuildApproval.State state = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The state. - */ - @java.lang.Override - public com.google.cloudbuild.v1.BuildApproval.State getState() { - @SuppressWarnings("deprecation") - com.google.cloudbuild.v1.BuildApproval.State result = - com.google.cloudbuild.v1.BuildApproval.State.valueOf(state_); - return result == null ? com.google.cloudbuild.v1.BuildApproval.State.UNRECOGNIZED : result; - } - /** - * - * - *
-     * Output only. The state of this build's approval.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.BuildApproval.State state = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @param value The state to set. - * @return This builder for chaining. - */ - public Builder setState(com.google.cloudbuild.v1.BuildApproval.State value) { - if (value == null) { - throw new NullPointerException(); - } - - state_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. The state of this build's approval.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.BuildApproval.State state = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return This builder for chaining. - */ - public Builder clearState() { - - state_ = 0; - onChanged(); - return this; - } - - private com.google.cloudbuild.v1.ApprovalConfig config_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.ApprovalConfig, - com.google.cloudbuild.v1.ApprovalConfig.Builder, - com.google.cloudbuild.v1.ApprovalConfigOrBuilder> - configBuilder_; - /** - * - * - *
-     * Output only. Configuration for manual approval of this build.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.ApprovalConfig config = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return Whether the config field is set. - */ - public boolean hasConfig() { - return configBuilder_ != null || config_ != null; - } - /** - * - * - *
-     * Output only. Configuration for manual approval of this build.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.ApprovalConfig config = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The config. - */ - public com.google.cloudbuild.v1.ApprovalConfig getConfig() { - if (configBuilder_ == null) { - return config_ == null - ? com.google.cloudbuild.v1.ApprovalConfig.getDefaultInstance() - : config_; - } else { - return configBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Output only. Configuration for manual approval of this build.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.ApprovalConfig config = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder setConfig(com.google.cloudbuild.v1.ApprovalConfig value) { - if (configBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - config_ = value; - onChanged(); - } else { - configBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * Output only. Configuration for manual approval of this build.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.ApprovalConfig config = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder setConfig(com.google.cloudbuild.v1.ApprovalConfig.Builder builderForValue) { - if (configBuilder_ == null) { - config_ = builderForValue.build(); - onChanged(); - } else { - configBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Output only. Configuration for manual approval of this build.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.ApprovalConfig config = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder mergeConfig(com.google.cloudbuild.v1.ApprovalConfig value) { - if (configBuilder_ == null) { - if (config_ != null) { - config_ = - com.google.cloudbuild.v1.ApprovalConfig.newBuilder(config_) - .mergeFrom(value) - .buildPartial(); - } else { - config_ = value; - } - onChanged(); - } else { - configBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * Output only. Configuration for manual approval of this build.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.ApprovalConfig config = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder clearConfig() { - if (configBuilder_ == null) { - config_ = null; - onChanged(); - } else { - config_ = null; - configBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Output only. Configuration for manual approval of this build.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.ApprovalConfig config = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public com.google.cloudbuild.v1.ApprovalConfig.Builder getConfigBuilder() { - - onChanged(); - return getConfigFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Output only. Configuration for manual approval of this build.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.ApprovalConfig config = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public com.google.cloudbuild.v1.ApprovalConfigOrBuilder getConfigOrBuilder() { - if (configBuilder_ != null) { - return configBuilder_.getMessageOrBuilder(); - } else { - return config_ == null - ? com.google.cloudbuild.v1.ApprovalConfig.getDefaultInstance() - : config_; - } - } - /** - * - * - *
-     * Output only. Configuration for manual approval of this build.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.ApprovalConfig config = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.ApprovalConfig, - com.google.cloudbuild.v1.ApprovalConfig.Builder, - com.google.cloudbuild.v1.ApprovalConfigOrBuilder> - getConfigFieldBuilder() { - if (configBuilder_ == null) { - configBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.ApprovalConfig, - com.google.cloudbuild.v1.ApprovalConfig.Builder, - com.google.cloudbuild.v1.ApprovalConfigOrBuilder>( - getConfig(), getParentForChildren(), isClean()); - config_ = null; - } - return configBuilder_; - } - - private com.google.cloudbuild.v1.ApprovalResult result_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.ApprovalResult, - com.google.cloudbuild.v1.ApprovalResult.Builder, - com.google.cloudbuild.v1.ApprovalResultOrBuilder> - resultBuilder_; - /** - * - * - *
-     * Output only. Result of manual approval for this Build.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.ApprovalResult result = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return Whether the result field is set. - */ - public boolean hasResult() { - return resultBuilder_ != null || result_ != null; - } - /** - * - * - *
-     * Output only. Result of manual approval for this Build.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.ApprovalResult result = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The result. - */ - public com.google.cloudbuild.v1.ApprovalResult getResult() { - if (resultBuilder_ == null) { - return result_ == null - ? com.google.cloudbuild.v1.ApprovalResult.getDefaultInstance() - : result_; - } else { - return resultBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Output only. Result of manual approval for this Build.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.ApprovalResult result = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder setResult(com.google.cloudbuild.v1.ApprovalResult value) { - if (resultBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - result_ = value; - onChanged(); - } else { - resultBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * Output only. Result of manual approval for this Build.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.ApprovalResult result = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder setResult(com.google.cloudbuild.v1.ApprovalResult.Builder builderForValue) { - if (resultBuilder_ == null) { - result_ = builderForValue.build(); - onChanged(); - } else { - resultBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Output only. Result of manual approval for this Build.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.ApprovalResult result = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder mergeResult(com.google.cloudbuild.v1.ApprovalResult value) { - if (resultBuilder_ == null) { - if (result_ != null) { - result_ = - com.google.cloudbuild.v1.ApprovalResult.newBuilder(result_) - .mergeFrom(value) - .buildPartial(); - } else { - result_ = value; - } - onChanged(); - } else { - resultBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * Output only. Result of manual approval for this Build.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.ApprovalResult result = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder clearResult() { - if (resultBuilder_ == null) { - result_ = null; - onChanged(); - } else { - result_ = null; - resultBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Output only. Result of manual approval for this Build.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.ApprovalResult result = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public com.google.cloudbuild.v1.ApprovalResult.Builder getResultBuilder() { - - onChanged(); - return getResultFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Output only. Result of manual approval for this Build.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.ApprovalResult result = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public com.google.cloudbuild.v1.ApprovalResultOrBuilder getResultOrBuilder() { - if (resultBuilder_ != null) { - return resultBuilder_.getMessageOrBuilder(); - } else { - return result_ == null - ? com.google.cloudbuild.v1.ApprovalResult.getDefaultInstance() - : result_; - } - } - /** - * - * - *
-     * Output only. Result of manual approval for this Build.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.ApprovalResult result = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.ApprovalResult, - com.google.cloudbuild.v1.ApprovalResult.Builder, - com.google.cloudbuild.v1.ApprovalResultOrBuilder> - getResultFieldBuilder() { - if (resultBuilder_ == null) { - resultBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.ApprovalResult, - com.google.cloudbuild.v1.ApprovalResult.Builder, - com.google.cloudbuild.v1.ApprovalResultOrBuilder>( - getResult(), getParentForChildren(), isClean()); - result_ = null; - } - return resultBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.BuildApproval) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.BuildApproval) - private static final com.google.cloudbuild.v1.BuildApproval DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.BuildApproval(); - } - - public static com.google.cloudbuild.v1.BuildApproval getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public BuildApproval parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.BuildApproval getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildApprovalOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildApprovalOrBuilder.java deleted file mode 100644 index 15ed1012..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildApprovalOrBuilder.java +++ /dev/null @@ -1,136 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface BuildApprovalOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.BuildApproval) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * Output only. The state of this build's approval.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.BuildApproval.State state = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The enum numeric value on the wire for state. - */ - int getStateValue(); - /** - * - * - *
-   * Output only. The state of this build's approval.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.BuildApproval.State state = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The state. - */ - com.google.cloudbuild.v1.BuildApproval.State getState(); - - /** - * - * - *
-   * Output only. Configuration for manual approval of this build.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.ApprovalConfig config = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return Whether the config field is set. - */ - boolean hasConfig(); - /** - * - * - *
-   * Output only. Configuration for manual approval of this build.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.ApprovalConfig config = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The config. - */ - com.google.cloudbuild.v1.ApprovalConfig getConfig(); - /** - * - * - *
-   * Output only. Configuration for manual approval of this build.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.ApprovalConfig config = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - com.google.cloudbuild.v1.ApprovalConfigOrBuilder getConfigOrBuilder(); - - /** - * - * - *
-   * Output only. Result of manual approval for this Build.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.ApprovalResult result = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return Whether the result field is set. - */ - boolean hasResult(); - /** - * - * - *
-   * Output only. Result of manual approval for this Build.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.ApprovalResult result = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The result. - */ - com.google.cloudbuild.v1.ApprovalResult getResult(); - /** - * - * - *
-   * Output only. Result of manual approval for this Build.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.ApprovalResult result = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - com.google.cloudbuild.v1.ApprovalResultOrBuilder getResultOrBuilder(); -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildName.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildName.java deleted file mode 100644 index 37379a34..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildName.java +++ /dev/null @@ -1,313 +0,0 @@ -/* - * Copyright 2022 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package com.google.cloudbuild.v1; - -import com.google.api.core.BetaApi; -import com.google.api.pathtemplate.PathTemplate; -import com.google.api.pathtemplate.ValidationException; -import com.google.api.resourcenames.ResourceName; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; -import java.util.Objects; -import javax.annotation.Generated; - -// AUTO-GENERATED DOCUMENTATION AND CLASS. -@Generated("by gapic-generator-java") -public class BuildName implements ResourceName { - private static final PathTemplate PROJECT_BUILD = - PathTemplate.createWithoutUrlEncoding("projects/{project}/builds/{build}"); - private static final PathTemplate PROJECT_LOCATION_BUILD = - PathTemplate.createWithoutUrlEncoding( - "projects/{project}/locations/{location}/builds/{build}"); - private volatile Map fieldValuesMap; - private PathTemplate pathTemplate; - private String fixedValue; - private final String project; - private final String build; - private final String location; - - @Deprecated - protected BuildName() { - project = null; - build = null; - location = null; - } - - private BuildName(Builder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - build = Preconditions.checkNotNull(builder.getBuild()); - location = null; - pathTemplate = PROJECT_BUILD; - } - - private BuildName(ProjectLocationBuildBuilder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - location = Preconditions.checkNotNull(builder.getLocation()); - build = Preconditions.checkNotNull(builder.getBuild()); - pathTemplate = PROJECT_LOCATION_BUILD; - } - - public String getProject() { - return project; - } - - public String getBuild() { - return build; - } - - public String getLocation() { - return location; - } - - public static Builder newBuilder() { - return new Builder(); - } - - @BetaApi("The per-pattern Builders are not stable yet and may be changed in the future.") - public static Builder newProjectBuildBuilder() { - return new Builder(); - } - - @BetaApi("The per-pattern Builders are not stable yet and may be changed in the future.") - public static ProjectLocationBuildBuilder newProjectLocationBuildBuilder() { - return new ProjectLocationBuildBuilder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - public static BuildName of(String project, String build) { - return newBuilder().setProject(project).setBuild(build).build(); - } - - @BetaApi("The static create methods are not stable yet and may be changed in the future.") - public static BuildName ofProjectBuildName(String project, String build) { - return newBuilder().setProject(project).setBuild(build).build(); - } - - @BetaApi("The static create methods are not stable yet and may be changed in the future.") - public static BuildName ofProjectLocationBuildName( - String project, String location, String build) { - return newProjectLocationBuildBuilder() - .setProject(project) - .setLocation(location) - .setBuild(build) - .build(); - } - - public static String format(String project, String build) { - return newBuilder().setProject(project).setBuild(build).build().toString(); - } - - @BetaApi("The static format methods are not stable yet and may be changed in the future.") - public static String formatProjectBuildName(String project, String build) { - return newBuilder().setProject(project).setBuild(build).build().toString(); - } - - @BetaApi("The static format methods are not stable yet and may be changed in the future.") - public static String formatProjectLocationBuildName( - String project, String location, String build) { - return newProjectLocationBuildBuilder() - .setProject(project) - .setLocation(location) - .setBuild(build) - .build() - .toString(); - } - - public static BuildName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - if (PROJECT_BUILD.matches(formattedString)) { - Map matchMap = PROJECT_BUILD.match(formattedString); - return ofProjectBuildName(matchMap.get("project"), matchMap.get("build")); - } else if (PROJECT_LOCATION_BUILD.matches(formattedString)) { - Map matchMap = PROJECT_LOCATION_BUILD.match(formattedString); - return ofProjectLocationBuildName( - matchMap.get("project"), matchMap.get("location"), matchMap.get("build")); - } - throw new ValidationException("BuildName.parse: formattedString not in valid format"); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList<>(values.size()); - for (BuildName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PROJECT_BUILD.matches(formattedString) - || PROJECT_LOCATION_BUILD.matches(formattedString); - } - - @Override - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - if (project != null) { - fieldMapBuilder.put("project", project); - } - if (build != null) { - fieldMapBuilder.put("build", build); - } - if (location != null) { - fieldMapBuilder.put("location", location); - } - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - @Override - public String toString() { - return fixedValue != null ? fixedValue : pathTemplate.instantiate(getFieldValuesMap()); - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o != null || getClass() == o.getClass()) { - BuildName that = ((BuildName) o); - return Objects.equals(this.project, that.project) - && Objects.equals(this.build, that.build) - && Objects.equals(this.location, that.location); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= Objects.hashCode(fixedValue); - h *= 1000003; - h ^= Objects.hashCode(project); - h *= 1000003; - h ^= Objects.hashCode(build); - h *= 1000003; - h ^= Objects.hashCode(location); - return h; - } - - /** Builder for projects/{project}/builds/{build}. */ - public static class Builder { - private String project; - private String build; - - protected Builder() {} - - public String getProject() { - return project; - } - - public String getBuild() { - return build; - } - - public Builder setProject(String project) { - this.project = project; - return this; - } - - public Builder setBuild(String build) { - this.build = build; - return this; - } - - private Builder(BuildName buildName) { - Preconditions.checkArgument( - Objects.equals(buildName.pathTemplate, PROJECT_BUILD), - "toBuilder is only supported when BuildName has the pattern of projects/{project}/builds/{build}"); - this.project = buildName.project; - this.build = buildName.build; - } - - public BuildName build() { - return new BuildName(this); - } - } - - /** Builder for projects/{project}/locations/{location}/builds/{build}. */ - @BetaApi("The per-pattern Builders are not stable yet and may be changed in the future.") - public static class ProjectLocationBuildBuilder { - private String project; - private String location; - private String build; - - protected ProjectLocationBuildBuilder() {} - - public String getProject() { - return project; - } - - public String getLocation() { - return location; - } - - public String getBuild() { - return build; - } - - public ProjectLocationBuildBuilder setProject(String project) { - this.project = project; - return this; - } - - public ProjectLocationBuildBuilder setLocation(String location) { - this.location = location; - return this; - } - - public ProjectLocationBuildBuilder setBuild(String build) { - this.build = build; - return this; - } - - public BuildName build() { - return new BuildName(this); - } - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildOperationMetadata.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildOperationMetadata.java deleted file mode 100644 index 8b45f99b..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildOperationMetadata.java +++ /dev/null @@ -1,695 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * Metadata for build operations.
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.BuildOperationMetadata} - */ -public final class BuildOperationMetadata extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.BuildOperationMetadata) - BuildOperationMetadataOrBuilder { - private static final long serialVersionUID = 0L; - // Use BuildOperationMetadata.newBuilder() to construct. - private BuildOperationMetadata(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private BuildOperationMetadata() {} - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new BuildOperationMetadata(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_BuildOperationMetadata_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_BuildOperationMetadata_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.BuildOperationMetadata.class, - com.google.cloudbuild.v1.BuildOperationMetadata.Builder.class); - } - - public static final int BUILD_FIELD_NUMBER = 1; - private com.google.cloudbuild.v1.Build build_; - /** - * - * - *
-   * The build that the operation is tracking.
-   * 
- * - * .google.devtools.cloudbuild.v1.Build build = 1; - * - * @return Whether the build field is set. - */ - @java.lang.Override - public boolean hasBuild() { - return build_ != null; - } - /** - * - * - *
-   * The build that the operation is tracking.
-   * 
- * - * .google.devtools.cloudbuild.v1.Build build = 1; - * - * @return The build. - */ - @java.lang.Override - public com.google.cloudbuild.v1.Build getBuild() { - return build_ == null ? com.google.cloudbuild.v1.Build.getDefaultInstance() : build_; - } - /** - * - * - *
-   * The build that the operation is tracking.
-   * 
- * - * .google.devtools.cloudbuild.v1.Build build = 1; - */ - @java.lang.Override - public com.google.cloudbuild.v1.BuildOrBuilder getBuildOrBuilder() { - return getBuild(); - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (build_ != null) { - output.writeMessage(1, getBuild()); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (build_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getBuild()); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.BuildOperationMetadata)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.BuildOperationMetadata other = - (com.google.cloudbuild.v1.BuildOperationMetadata) obj; - - if (hasBuild() != other.hasBuild()) return false; - if (hasBuild()) { - if (!getBuild().equals(other.getBuild())) return false; - } - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasBuild()) { - hash = (37 * hash) + BUILD_FIELD_NUMBER; - hash = (53 * hash) + getBuild().hashCode(); - } - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.BuildOperationMetadata parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.BuildOperationMetadata parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.BuildOperationMetadata parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.BuildOperationMetadata parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.BuildOperationMetadata parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.BuildOperationMetadata parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.BuildOperationMetadata parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.BuildOperationMetadata parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.BuildOperationMetadata parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.BuildOperationMetadata parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.BuildOperationMetadata parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.BuildOperationMetadata parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.BuildOperationMetadata prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * Metadata for build operations.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.BuildOperationMetadata} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.BuildOperationMetadata) - com.google.cloudbuild.v1.BuildOperationMetadataOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_BuildOperationMetadata_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_BuildOperationMetadata_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.BuildOperationMetadata.class, - com.google.cloudbuild.v1.BuildOperationMetadata.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.BuildOperationMetadata.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - if (buildBuilder_ == null) { - build_ = null; - } else { - build_ = null; - buildBuilder_ = null; - } - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_BuildOperationMetadata_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.BuildOperationMetadata getDefaultInstanceForType() { - return com.google.cloudbuild.v1.BuildOperationMetadata.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.BuildOperationMetadata build() { - com.google.cloudbuild.v1.BuildOperationMetadata result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.BuildOperationMetadata buildPartial() { - com.google.cloudbuild.v1.BuildOperationMetadata result = - new com.google.cloudbuild.v1.BuildOperationMetadata(this); - if (buildBuilder_ == null) { - result.build_ = build_; - } else { - result.build_ = buildBuilder_.build(); - } - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.BuildOperationMetadata) { - return mergeFrom((com.google.cloudbuild.v1.BuildOperationMetadata) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.BuildOperationMetadata other) { - if (other == com.google.cloudbuild.v1.BuildOperationMetadata.getDefaultInstance()) - return this; - if (other.hasBuild()) { - mergeBuild(other.getBuild()); - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - input.readMessage(getBuildFieldBuilder().getBuilder(), extensionRegistry); - - break; - } // case 10 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private com.google.cloudbuild.v1.Build build_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.Build, - com.google.cloudbuild.v1.Build.Builder, - com.google.cloudbuild.v1.BuildOrBuilder> - buildBuilder_; - /** - * - * - *
-     * The build that the operation is tracking.
-     * 
- * - * .google.devtools.cloudbuild.v1.Build build = 1; - * - * @return Whether the build field is set. - */ - public boolean hasBuild() { - return buildBuilder_ != null || build_ != null; - } - /** - * - * - *
-     * The build that the operation is tracking.
-     * 
- * - * .google.devtools.cloudbuild.v1.Build build = 1; - * - * @return The build. - */ - public com.google.cloudbuild.v1.Build getBuild() { - if (buildBuilder_ == null) { - return build_ == null ? com.google.cloudbuild.v1.Build.getDefaultInstance() : build_; - } else { - return buildBuilder_.getMessage(); - } - } - /** - * - * - *
-     * The build that the operation is tracking.
-     * 
- * - * .google.devtools.cloudbuild.v1.Build build = 1; - */ - public Builder setBuild(com.google.cloudbuild.v1.Build value) { - if (buildBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - build_ = value; - onChanged(); - } else { - buildBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * The build that the operation is tracking.
-     * 
- * - * .google.devtools.cloudbuild.v1.Build build = 1; - */ - public Builder setBuild(com.google.cloudbuild.v1.Build.Builder builderForValue) { - if (buildBuilder_ == null) { - build_ = builderForValue.build(); - onChanged(); - } else { - buildBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * The build that the operation is tracking.
-     * 
- * - * .google.devtools.cloudbuild.v1.Build build = 1; - */ - public Builder mergeBuild(com.google.cloudbuild.v1.Build value) { - if (buildBuilder_ == null) { - if (build_ != null) { - build_ = - com.google.cloudbuild.v1.Build.newBuilder(build_).mergeFrom(value).buildPartial(); - } else { - build_ = value; - } - onChanged(); - } else { - buildBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * The build that the operation is tracking.
-     * 
- * - * .google.devtools.cloudbuild.v1.Build build = 1; - */ - public Builder clearBuild() { - if (buildBuilder_ == null) { - build_ = null; - onChanged(); - } else { - build_ = null; - buildBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * The build that the operation is tracking.
-     * 
- * - * .google.devtools.cloudbuild.v1.Build build = 1; - */ - public com.google.cloudbuild.v1.Build.Builder getBuildBuilder() { - - onChanged(); - return getBuildFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * The build that the operation is tracking.
-     * 
- * - * .google.devtools.cloudbuild.v1.Build build = 1; - */ - public com.google.cloudbuild.v1.BuildOrBuilder getBuildOrBuilder() { - if (buildBuilder_ != null) { - return buildBuilder_.getMessageOrBuilder(); - } else { - return build_ == null ? com.google.cloudbuild.v1.Build.getDefaultInstance() : build_; - } - } - /** - * - * - *
-     * The build that the operation is tracking.
-     * 
- * - * .google.devtools.cloudbuild.v1.Build build = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.Build, - com.google.cloudbuild.v1.Build.Builder, - com.google.cloudbuild.v1.BuildOrBuilder> - getBuildFieldBuilder() { - if (buildBuilder_ == null) { - buildBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.Build, - com.google.cloudbuild.v1.Build.Builder, - com.google.cloudbuild.v1.BuildOrBuilder>( - getBuild(), getParentForChildren(), isClean()); - build_ = null; - } - return buildBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.BuildOperationMetadata) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.BuildOperationMetadata) - private static final com.google.cloudbuild.v1.BuildOperationMetadata DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.BuildOperationMetadata(); - } - - public static com.google.cloudbuild.v1.BuildOperationMetadata getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public BuildOperationMetadata parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.BuildOperationMetadata getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildOperationMetadataOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildOperationMetadataOrBuilder.java deleted file mode 100644 index ef5b1a87..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildOperationMetadataOrBuilder.java +++ /dev/null @@ -1,60 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface BuildOperationMetadataOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.BuildOperationMetadata) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The build that the operation is tracking.
-   * 
- * - * .google.devtools.cloudbuild.v1.Build build = 1; - * - * @return Whether the build field is set. - */ - boolean hasBuild(); - /** - * - * - *
-   * The build that the operation is tracking.
-   * 
- * - * .google.devtools.cloudbuild.v1.Build build = 1; - * - * @return The build. - */ - com.google.cloudbuild.v1.Build getBuild(); - /** - * - * - *
-   * The build that the operation is tracking.
-   * 
- * - * .google.devtools.cloudbuild.v1.Build build = 1; - */ - com.google.cloudbuild.v1.BuildOrBuilder getBuildOrBuilder(); -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildOptions.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildOptions.java deleted file mode 100644 index 9585805a..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildOptions.java +++ /dev/null @@ -1,5191 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * Optional arguments to enable specific features of builds.
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.BuildOptions} - */ -public final class BuildOptions extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.BuildOptions) - BuildOptionsOrBuilder { - private static final long serialVersionUID = 0L; - // Use BuildOptions.newBuilder() to construct. - private BuildOptions(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private BuildOptions() { - sourceProvenanceHash_ = java.util.Collections.emptyList(); - requestedVerifyOption_ = 0; - machineType_ = 0; - substitutionOption_ = 0; - logStreamingOption_ = 0; - workerPool_ = ""; - logging_ = 0; - env_ = com.google.protobuf.LazyStringArrayList.EMPTY; - secretEnv_ = com.google.protobuf.LazyStringArrayList.EMPTY; - volumes_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new BuildOptions(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_BuildOptions_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_BuildOptions_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.BuildOptions.class, - com.google.cloudbuild.v1.BuildOptions.Builder.class); - } - - /** - * - * - *
-   * Specifies the manner in which the build should be verified, if at all.
-   * 
- * - * Protobuf enum {@code google.devtools.cloudbuild.v1.BuildOptions.VerifyOption} - */ - public enum VerifyOption implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
-     * Not a verifiable build. (default)
-     * 
- * - * NOT_VERIFIED = 0; - */ - NOT_VERIFIED(0), - /** - * - * - *
-     * Verified build.
-     * 
- * - * VERIFIED = 1; - */ - VERIFIED(1), - UNRECOGNIZED(-1), - ; - - /** - * - * - *
-     * Not a verifiable build. (default)
-     * 
- * - * NOT_VERIFIED = 0; - */ - public static final int NOT_VERIFIED_VALUE = 0; - /** - * - * - *
-     * Verified build.
-     * 
- * - * VERIFIED = 1; - */ - public static final int VERIFIED_VALUE = 1; - - public final int getNumber() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalArgumentException( - "Can't get the number of an unknown enum value."); - } - return value; - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static VerifyOption valueOf(int value) { - return forNumber(value); - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - */ - public static VerifyOption forNumber(int value) { - switch (value) { - case 0: - return NOT_VERIFIED; - case 1: - return VERIFIED; - default: - return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { - return internalValueMap; - } - - private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public VerifyOption findValueByNumber(int number) { - return VerifyOption.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalStateException( - "Can't get the descriptor of an unrecognized enum value."); - } - return getDescriptor().getValues().get(ordinal()); - } - - public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { - return getDescriptor(); - } - - public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return com.google.cloudbuild.v1.BuildOptions.getDescriptor().getEnumTypes().get(0); - } - - private static final VerifyOption[] VALUES = values(); - - public static VerifyOption valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); - } - if (desc.getIndex() == -1) { - return UNRECOGNIZED; - } - return VALUES[desc.getIndex()]; - } - - private final int value; - - private VerifyOption(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:google.devtools.cloudbuild.v1.BuildOptions.VerifyOption) - } - - /** - * - * - *
-   * Supported Compute Engine machine types.
-   * For more information, see [Machine
-   * types](https://cloud.google.com/compute/docs/machine-types).
-   * 
- * - * Protobuf enum {@code google.devtools.cloudbuild.v1.BuildOptions.MachineType} - */ - public enum MachineType implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
-     * Standard machine type.
-     * 
- * - * UNSPECIFIED = 0; - */ - UNSPECIFIED(0), - /** - * - * - *
-     * Highcpu machine with 8 CPUs.
-     * 
- * - * N1_HIGHCPU_8 = 1; - */ - N1_HIGHCPU_8(1), - /** - * - * - *
-     * Highcpu machine with 32 CPUs.
-     * 
- * - * N1_HIGHCPU_32 = 2; - */ - N1_HIGHCPU_32(2), - /** - * - * - *
-     * Highcpu e2 machine with 8 CPUs.
-     * 
- * - * E2_HIGHCPU_8 = 5; - */ - E2_HIGHCPU_8(5), - /** - * - * - *
-     * Highcpu e2 machine with 32 CPUs.
-     * 
- * - * E2_HIGHCPU_32 = 6; - */ - E2_HIGHCPU_32(6), - UNRECOGNIZED(-1), - ; - - /** - * - * - *
-     * Standard machine type.
-     * 
- * - * UNSPECIFIED = 0; - */ - public static final int UNSPECIFIED_VALUE = 0; - /** - * - * - *
-     * Highcpu machine with 8 CPUs.
-     * 
- * - * N1_HIGHCPU_8 = 1; - */ - public static final int N1_HIGHCPU_8_VALUE = 1; - /** - * - * - *
-     * Highcpu machine with 32 CPUs.
-     * 
- * - * N1_HIGHCPU_32 = 2; - */ - public static final int N1_HIGHCPU_32_VALUE = 2; - /** - * - * - *
-     * Highcpu e2 machine with 8 CPUs.
-     * 
- * - * E2_HIGHCPU_8 = 5; - */ - public static final int E2_HIGHCPU_8_VALUE = 5; - /** - * - * - *
-     * Highcpu e2 machine with 32 CPUs.
-     * 
- * - * E2_HIGHCPU_32 = 6; - */ - public static final int E2_HIGHCPU_32_VALUE = 6; - - public final int getNumber() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalArgumentException( - "Can't get the number of an unknown enum value."); - } - return value; - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static MachineType valueOf(int value) { - return forNumber(value); - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - */ - public static MachineType forNumber(int value) { - switch (value) { - case 0: - return UNSPECIFIED; - case 1: - return N1_HIGHCPU_8; - case 2: - return N1_HIGHCPU_32; - case 5: - return E2_HIGHCPU_8; - case 6: - return E2_HIGHCPU_32; - default: - return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { - return internalValueMap; - } - - private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public MachineType findValueByNumber(int number) { - return MachineType.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalStateException( - "Can't get the descriptor of an unrecognized enum value."); - } - return getDescriptor().getValues().get(ordinal()); - } - - public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { - return getDescriptor(); - } - - public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return com.google.cloudbuild.v1.BuildOptions.getDescriptor().getEnumTypes().get(1); - } - - private static final MachineType[] VALUES = values(); - - public static MachineType valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); - } - if (desc.getIndex() == -1) { - return UNRECOGNIZED; - } - return VALUES[desc.getIndex()]; - } - - private final int value; - - private MachineType(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:google.devtools.cloudbuild.v1.BuildOptions.MachineType) - } - - /** - * - * - *
-   * Specifies the behavior when there is an error in the substitution checks.
-   * 
- * - * Protobuf enum {@code google.devtools.cloudbuild.v1.BuildOptions.SubstitutionOption} - */ - public enum SubstitutionOption implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
-     * Fails the build if error in substitutions checks, like missing
-     * a substitution in the template or in the map.
-     * 
- * - * MUST_MATCH = 0; - */ - MUST_MATCH(0), - /** - * - * - *
-     * Do not fail the build if error in substitutions checks.
-     * 
- * - * ALLOW_LOOSE = 1; - */ - ALLOW_LOOSE(1), - UNRECOGNIZED(-1), - ; - - /** - * - * - *
-     * Fails the build if error in substitutions checks, like missing
-     * a substitution in the template or in the map.
-     * 
- * - * MUST_MATCH = 0; - */ - public static final int MUST_MATCH_VALUE = 0; - /** - * - * - *
-     * Do not fail the build if error in substitutions checks.
-     * 
- * - * ALLOW_LOOSE = 1; - */ - public static final int ALLOW_LOOSE_VALUE = 1; - - public final int getNumber() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalArgumentException( - "Can't get the number of an unknown enum value."); - } - return value; - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static SubstitutionOption valueOf(int value) { - return forNumber(value); - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - */ - public static SubstitutionOption forNumber(int value) { - switch (value) { - case 0: - return MUST_MATCH; - case 1: - return ALLOW_LOOSE; - default: - return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap - internalGetValueMap() { - return internalValueMap; - } - - private static final com.google.protobuf.Internal.EnumLiteMap - internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public SubstitutionOption findValueByNumber(int number) { - return SubstitutionOption.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalStateException( - "Can't get the descriptor of an unrecognized enum value."); - } - return getDescriptor().getValues().get(ordinal()); - } - - public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { - return getDescriptor(); - } - - public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return com.google.cloudbuild.v1.BuildOptions.getDescriptor().getEnumTypes().get(2); - } - - private static final SubstitutionOption[] VALUES = values(); - - public static SubstitutionOption valueOf( - com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); - } - if (desc.getIndex() == -1) { - return UNRECOGNIZED; - } - return VALUES[desc.getIndex()]; - } - - private final int value; - - private SubstitutionOption(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:google.devtools.cloudbuild.v1.BuildOptions.SubstitutionOption) - } - - /** - * - * - *
-   * Specifies the behavior when writing build logs to Google Cloud Storage.
-   * 
- * - * Protobuf enum {@code google.devtools.cloudbuild.v1.BuildOptions.LogStreamingOption} - */ - public enum LogStreamingOption implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
-     * Service may automatically determine build log streaming behavior.
-     * 
- * - * STREAM_DEFAULT = 0; - */ - STREAM_DEFAULT(0), - /** - * - * - *
-     * Build logs should be streamed to Google Cloud Storage.
-     * 
- * - * STREAM_ON = 1; - */ - STREAM_ON(1), - /** - * - * - *
-     * Build logs should not be streamed to Google Cloud Storage; they will be
-     * written when the build is completed.
-     * 
- * - * STREAM_OFF = 2; - */ - STREAM_OFF(2), - UNRECOGNIZED(-1), - ; - - /** - * - * - *
-     * Service may automatically determine build log streaming behavior.
-     * 
- * - * STREAM_DEFAULT = 0; - */ - public static final int STREAM_DEFAULT_VALUE = 0; - /** - * - * - *
-     * Build logs should be streamed to Google Cloud Storage.
-     * 
- * - * STREAM_ON = 1; - */ - public static final int STREAM_ON_VALUE = 1; - /** - * - * - *
-     * Build logs should not be streamed to Google Cloud Storage; they will be
-     * written when the build is completed.
-     * 
- * - * STREAM_OFF = 2; - */ - public static final int STREAM_OFF_VALUE = 2; - - public final int getNumber() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalArgumentException( - "Can't get the number of an unknown enum value."); - } - return value; - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static LogStreamingOption valueOf(int value) { - return forNumber(value); - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - */ - public static LogStreamingOption forNumber(int value) { - switch (value) { - case 0: - return STREAM_DEFAULT; - case 1: - return STREAM_ON; - case 2: - return STREAM_OFF; - default: - return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap - internalGetValueMap() { - return internalValueMap; - } - - private static final com.google.protobuf.Internal.EnumLiteMap - internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public LogStreamingOption findValueByNumber(int number) { - return LogStreamingOption.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalStateException( - "Can't get the descriptor of an unrecognized enum value."); - } - return getDescriptor().getValues().get(ordinal()); - } - - public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { - return getDescriptor(); - } - - public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return com.google.cloudbuild.v1.BuildOptions.getDescriptor().getEnumTypes().get(3); - } - - private static final LogStreamingOption[] VALUES = values(); - - public static LogStreamingOption valueOf( - com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); - } - if (desc.getIndex() == -1) { - return UNRECOGNIZED; - } - return VALUES[desc.getIndex()]; - } - - private final int value; - - private LogStreamingOption(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:google.devtools.cloudbuild.v1.BuildOptions.LogStreamingOption) - } - - /** - * - * - *
-   * Specifies the logging mode.
-   * 
- * - * Protobuf enum {@code google.devtools.cloudbuild.v1.BuildOptions.LoggingMode} - */ - public enum LoggingMode implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
-     * The service determines the logging mode. The default is `LEGACY`. Do not
-     * rely on the default logging behavior as it may change in the future.
-     * 
- * - * LOGGING_UNSPECIFIED = 0; - */ - LOGGING_UNSPECIFIED(0), - /** - * - * - *
-     * Cloud Logging and Cloud Storage logging are enabled.
-     * 
- * - * LEGACY = 1; - */ - LEGACY(1), - /** - * - * - *
-     * Only Cloud Storage logging is enabled.
-     * 
- * - * GCS_ONLY = 2; - */ - GCS_ONLY(2), - /** - * - * - *
-     * This option is the same as CLOUD_LOGGING_ONLY.
-     * 
- * - * STACKDRIVER_ONLY = 3 [deprecated = true]; - */ - @java.lang.Deprecated - STACKDRIVER_ONLY(3), - /** - * - * - *
-     * Only Cloud Logging is enabled. Note that logs for both the Cloud Console
-     * UI and Cloud SDK are based on Cloud Storage logs, so neither will provide
-     * logs if this option is chosen.
-     * 
- * - * CLOUD_LOGGING_ONLY = 5; - */ - CLOUD_LOGGING_ONLY(5), - /** - * - * - *
-     * Turn off all logging. No build logs will be captured.
-     * 
- * - * NONE = 4; - */ - NONE(4), - UNRECOGNIZED(-1), - ; - - /** - * - * - *
-     * The service determines the logging mode. The default is `LEGACY`. Do not
-     * rely on the default logging behavior as it may change in the future.
-     * 
- * - * LOGGING_UNSPECIFIED = 0; - */ - public static final int LOGGING_UNSPECIFIED_VALUE = 0; - /** - * - * - *
-     * Cloud Logging and Cloud Storage logging are enabled.
-     * 
- * - * LEGACY = 1; - */ - public static final int LEGACY_VALUE = 1; - /** - * - * - *
-     * Only Cloud Storage logging is enabled.
-     * 
- * - * GCS_ONLY = 2; - */ - public static final int GCS_ONLY_VALUE = 2; - /** - * - * - *
-     * This option is the same as CLOUD_LOGGING_ONLY.
-     * 
- * - * STACKDRIVER_ONLY = 3 [deprecated = true]; - */ - @java.lang.Deprecated public static final int STACKDRIVER_ONLY_VALUE = 3; - /** - * - * - *
-     * Only Cloud Logging is enabled. Note that logs for both the Cloud Console
-     * UI and Cloud SDK are based on Cloud Storage logs, so neither will provide
-     * logs if this option is chosen.
-     * 
- * - * CLOUD_LOGGING_ONLY = 5; - */ - public static final int CLOUD_LOGGING_ONLY_VALUE = 5; - /** - * - * - *
-     * Turn off all logging. No build logs will be captured.
-     * 
- * - * NONE = 4; - */ - public static final int NONE_VALUE = 4; - - public final int getNumber() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalArgumentException( - "Can't get the number of an unknown enum value."); - } - return value; - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static LoggingMode valueOf(int value) { - return forNumber(value); - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - */ - public static LoggingMode forNumber(int value) { - switch (value) { - case 0: - return LOGGING_UNSPECIFIED; - case 1: - return LEGACY; - case 2: - return GCS_ONLY; - case 3: - return STACKDRIVER_ONLY; - case 5: - return CLOUD_LOGGING_ONLY; - case 4: - return NONE; - default: - return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { - return internalValueMap; - } - - private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public LoggingMode findValueByNumber(int number) { - return LoggingMode.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalStateException( - "Can't get the descriptor of an unrecognized enum value."); - } - return getDescriptor().getValues().get(ordinal()); - } - - public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { - return getDescriptor(); - } - - public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return com.google.cloudbuild.v1.BuildOptions.getDescriptor().getEnumTypes().get(4); - } - - private static final LoggingMode[] VALUES = values(); - - public static LoggingMode valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); - } - if (desc.getIndex() == -1) { - return UNRECOGNIZED; - } - return VALUES[desc.getIndex()]; - } - - private final int value; - - private LoggingMode(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:google.devtools.cloudbuild.v1.BuildOptions.LoggingMode) - } - - public interface PoolOptionOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.BuildOptions.PoolOption) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-     * The `WorkerPool` resource to execute the build on.
-     * You must have `cloudbuild.workerpools.use` on the project hosting the
-     * WorkerPool.
-     * Format projects/{project}/locations/{location}/workerPools/{workerPoolId}
-     * 
- * - * string name = 1 [(.google.api.resource_reference) = { ... } - * - * @return The name. - */ - java.lang.String getName(); - /** - * - * - *
-     * The `WorkerPool` resource to execute the build on.
-     * You must have `cloudbuild.workerpools.use` on the project hosting the
-     * WorkerPool.
-     * Format projects/{project}/locations/{location}/workerPools/{workerPoolId}
-     * 
- * - * string name = 1 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for name. - */ - com.google.protobuf.ByteString getNameBytes(); - } - /** - * - * - *
-   * Details about how a build should be executed on a `WorkerPool`.
-   * See [running builds in a private
-   * pool](https://cloud.google.com/build/docs/private-pools/run-builds-in-private-pool)
-   * for more information.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.BuildOptions.PoolOption} - */ - public static final class PoolOption extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.BuildOptions.PoolOption) - PoolOptionOrBuilder { - private static final long serialVersionUID = 0L; - // Use PoolOption.newBuilder() to construct. - private PoolOption(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private PoolOption() { - name_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new PoolOption(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_BuildOptions_PoolOption_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_BuildOptions_PoolOption_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.BuildOptions.PoolOption.class, - com.google.cloudbuild.v1.BuildOptions.PoolOption.Builder.class); - } - - public static final int NAME_FIELD_NUMBER = 1; - private volatile java.lang.Object name_; - /** - * - * - *
-     * The `WorkerPool` resource to execute the build on.
-     * You must have `cloudbuild.workerpools.use` on the project hosting the
-     * WorkerPool.
-     * Format projects/{project}/locations/{location}/workerPools/{workerPoolId}
-     * 
- * - * string name = 1 [(.google.api.resource_reference) = { ... } - * - * @return The name. - */ - @java.lang.Override - public java.lang.String getName() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - name_ = s; - return s; - } - } - /** - * - * - *
-     * The `WorkerPool` resource to execute the build on.
-     * You must have `cloudbuild.workerpools.use` on the project hosting the
-     * WorkerPool.
-     * Format projects/{project}/locations/{location}/workerPools/{workerPoolId}
-     * 
- * - * string name = 1 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for name. - */ - @java.lang.Override - public com.google.protobuf.ByteString getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.BuildOptions.PoolOption)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.BuildOptions.PoolOption other = - (com.google.cloudbuild.v1.BuildOptions.PoolOption) obj; - - if (!getName().equals(other.getName())) return false; - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + NAME_FIELD_NUMBER; - hash = (53 * hash) + getName().hashCode(); - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.BuildOptions.PoolOption parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.BuildOptions.PoolOption parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.BuildOptions.PoolOption parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.BuildOptions.PoolOption parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.BuildOptions.PoolOption parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.BuildOptions.PoolOption parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.BuildOptions.PoolOption parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.BuildOptions.PoolOption parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.BuildOptions.PoolOption parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.BuildOptions.PoolOption parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.BuildOptions.PoolOption parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.BuildOptions.PoolOption parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.BuildOptions.PoolOption prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-     * Details about how a build should be executed on a `WorkerPool`.
-     * See [running builds in a private
-     * pool](https://cloud.google.com/build/docs/private-pools/run-builds-in-private-pool)
-     * for more information.
-     * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.BuildOptions.PoolOption} - */ - public static final class Builder - extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.BuildOptions.PoolOption) - com.google.cloudbuild.v1.BuildOptions.PoolOptionOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_BuildOptions_PoolOption_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_BuildOptions_PoolOption_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.BuildOptions.PoolOption.class, - com.google.cloudbuild.v1.BuildOptions.PoolOption.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.BuildOptions.PoolOption.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - name_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_BuildOptions_PoolOption_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.BuildOptions.PoolOption getDefaultInstanceForType() { - return com.google.cloudbuild.v1.BuildOptions.PoolOption.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.BuildOptions.PoolOption build() { - com.google.cloudbuild.v1.BuildOptions.PoolOption result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.BuildOptions.PoolOption buildPartial() { - com.google.cloudbuild.v1.BuildOptions.PoolOption result = - new com.google.cloudbuild.v1.BuildOptions.PoolOption(this); - result.name_ = name_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, - java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.BuildOptions.PoolOption) { - return mergeFrom((com.google.cloudbuild.v1.BuildOptions.PoolOption) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.BuildOptions.PoolOption other) { - if (other == com.google.cloudbuild.v1.BuildOptions.PoolOption.getDefaultInstance()) - return this; - if (!other.getName().isEmpty()) { - name_ = other.name_; - onChanged(); - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - name_ = input.readStringRequireUtf8(); - - break; - } // case 10 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private java.lang.Object name_ = ""; - /** - * - * - *
-       * The `WorkerPool` resource to execute the build on.
-       * You must have `cloudbuild.workerpools.use` on the project hosting the
-       * WorkerPool.
-       * Format projects/{project}/locations/{location}/workerPools/{workerPoolId}
-       * 
- * - * string name = 1 [(.google.api.resource_reference) = { ... } - * - * @return The name. - */ - public java.lang.String getName() { - java.lang.Object ref = name_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - name_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-       * The `WorkerPool` resource to execute the build on.
-       * You must have `cloudbuild.workerpools.use` on the project hosting the
-       * WorkerPool.
-       * Format projects/{project}/locations/{location}/workerPools/{workerPoolId}
-       * 
- * - * string name = 1 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for name. - */ - public com.google.protobuf.ByteString getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-       * The `WorkerPool` resource to execute the build on.
-       * You must have `cloudbuild.workerpools.use` on the project hosting the
-       * WorkerPool.
-       * Format projects/{project}/locations/{location}/workerPools/{workerPoolId}
-       * 
- * - * string name = 1 [(.google.api.resource_reference) = { ... } - * - * @param value The name to set. - * @return This builder for chaining. - */ - public Builder setName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - name_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * The `WorkerPool` resource to execute the build on.
-       * You must have `cloudbuild.workerpools.use` on the project hosting the
-       * WorkerPool.
-       * Format projects/{project}/locations/{location}/workerPools/{workerPoolId}
-       * 
- * - * string name = 1 [(.google.api.resource_reference) = { ... } - * - * @return This builder for chaining. - */ - public Builder clearName() { - - name_ = getDefaultInstance().getName(); - onChanged(); - return this; - } - /** - * - * - *
-       * The `WorkerPool` resource to execute the build on.
-       * You must have `cloudbuild.workerpools.use` on the project hosting the
-       * WorkerPool.
-       * Format projects/{project}/locations/{location}/workerPools/{workerPoolId}
-       * 
- * - * string name = 1 [(.google.api.resource_reference) = { ... } - * - * @param value The bytes for name to set. - * @return This builder for chaining. - */ - public Builder setNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - name_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.BuildOptions.PoolOption) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.BuildOptions.PoolOption) - private static final com.google.cloudbuild.v1.BuildOptions.PoolOption DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.BuildOptions.PoolOption(); - } - - public static com.google.cloudbuild.v1.BuildOptions.PoolOption getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public PoolOption parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException() - .setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.BuildOptions.PoolOption getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - } - - public static final int SOURCE_PROVENANCE_HASH_FIELD_NUMBER = 1; - private java.util.List sourceProvenanceHash_; - private static final com.google.protobuf.Internal.ListAdapter.Converter< - java.lang.Integer, com.google.cloudbuild.v1.Hash.HashType> - sourceProvenanceHash_converter_ = - new com.google.protobuf.Internal.ListAdapter.Converter< - java.lang.Integer, com.google.cloudbuild.v1.Hash.HashType>() { - public com.google.cloudbuild.v1.Hash.HashType convert(java.lang.Integer from) { - @SuppressWarnings("deprecation") - com.google.cloudbuild.v1.Hash.HashType result = - com.google.cloudbuild.v1.Hash.HashType.valueOf(from); - return result == null ? com.google.cloudbuild.v1.Hash.HashType.UNRECOGNIZED : result; - } - }; - /** - * - * - *
-   * Requested hash for SourceProvenance.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Hash.HashType source_provenance_hash = 1; - * - * @return A list containing the sourceProvenanceHash. - */ - @java.lang.Override - public java.util.List getSourceProvenanceHashList() { - return new com.google.protobuf.Internal.ListAdapter< - java.lang.Integer, com.google.cloudbuild.v1.Hash.HashType>( - sourceProvenanceHash_, sourceProvenanceHash_converter_); - } - /** - * - * - *
-   * Requested hash for SourceProvenance.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Hash.HashType source_provenance_hash = 1; - * - * @return The count of sourceProvenanceHash. - */ - @java.lang.Override - public int getSourceProvenanceHashCount() { - return sourceProvenanceHash_.size(); - } - /** - * - * - *
-   * Requested hash for SourceProvenance.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Hash.HashType source_provenance_hash = 1; - * - * @param index The index of the element to return. - * @return The sourceProvenanceHash at the given index. - */ - @java.lang.Override - public com.google.cloudbuild.v1.Hash.HashType getSourceProvenanceHash(int index) { - return sourceProvenanceHash_converter_.convert(sourceProvenanceHash_.get(index)); - } - /** - * - * - *
-   * Requested hash for SourceProvenance.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Hash.HashType source_provenance_hash = 1; - * - * @return A list containing the enum numeric values on the wire for sourceProvenanceHash. - */ - @java.lang.Override - public java.util.List getSourceProvenanceHashValueList() { - return sourceProvenanceHash_; - } - /** - * - * - *
-   * Requested hash for SourceProvenance.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Hash.HashType source_provenance_hash = 1; - * - * @param index The index of the value to return. - * @return The enum numeric value on the wire of sourceProvenanceHash at the given index. - */ - @java.lang.Override - public int getSourceProvenanceHashValue(int index) { - return sourceProvenanceHash_.get(index); - } - - private int sourceProvenanceHashMemoizedSerializedSize; - - public static final int REQUESTED_VERIFY_OPTION_FIELD_NUMBER = 2; - private int requestedVerifyOption_; - /** - * - * - *
-   * Requested verifiability options.
-   * 
- * - * .google.devtools.cloudbuild.v1.BuildOptions.VerifyOption requested_verify_option = 2; - * - * - * @return The enum numeric value on the wire for requestedVerifyOption. - */ - @java.lang.Override - public int getRequestedVerifyOptionValue() { - return requestedVerifyOption_; - } - /** - * - * - *
-   * Requested verifiability options.
-   * 
- * - * .google.devtools.cloudbuild.v1.BuildOptions.VerifyOption requested_verify_option = 2; - * - * - * @return The requestedVerifyOption. - */ - @java.lang.Override - public com.google.cloudbuild.v1.BuildOptions.VerifyOption getRequestedVerifyOption() { - @SuppressWarnings("deprecation") - com.google.cloudbuild.v1.BuildOptions.VerifyOption result = - com.google.cloudbuild.v1.BuildOptions.VerifyOption.valueOf(requestedVerifyOption_); - return result == null - ? com.google.cloudbuild.v1.BuildOptions.VerifyOption.UNRECOGNIZED - : result; - } - - public static final int MACHINE_TYPE_FIELD_NUMBER = 3; - private int machineType_; - /** - * - * - *
-   * Compute Engine machine type on which to run the build.
-   * 
- * - * .google.devtools.cloudbuild.v1.BuildOptions.MachineType machine_type = 3; - * - * @return The enum numeric value on the wire for machineType. - */ - @java.lang.Override - public int getMachineTypeValue() { - return machineType_; - } - /** - * - * - *
-   * Compute Engine machine type on which to run the build.
-   * 
- * - * .google.devtools.cloudbuild.v1.BuildOptions.MachineType machine_type = 3; - * - * @return The machineType. - */ - @java.lang.Override - public com.google.cloudbuild.v1.BuildOptions.MachineType getMachineType() { - @SuppressWarnings("deprecation") - com.google.cloudbuild.v1.BuildOptions.MachineType result = - com.google.cloudbuild.v1.BuildOptions.MachineType.valueOf(machineType_); - return result == null ? com.google.cloudbuild.v1.BuildOptions.MachineType.UNRECOGNIZED : result; - } - - public static final int DISK_SIZE_GB_FIELD_NUMBER = 6; - private long diskSizeGb_; - /** - * - * - *
-   * Requested disk size for the VM that runs the build. Note that this is *NOT*
-   * "disk free"; some of the space will be used by the operating system and
-   * build utilities. Also note that this is the minimum disk size that will be
-   * allocated for the build -- the build may run with a larger disk than
-   * requested. At present, the maximum disk size is 1000GB; builds that request
-   * more than the maximum are rejected with an error.
-   * 
- * - * int64 disk_size_gb = 6; - * - * @return The diskSizeGb. - */ - @java.lang.Override - public long getDiskSizeGb() { - return diskSizeGb_; - } - - public static final int SUBSTITUTION_OPTION_FIELD_NUMBER = 4; - private int substitutionOption_; - /** - * - * - *
-   * Option to specify behavior when there is an error in the substitution
-   * checks.
-   * NOTE: this is always set to ALLOW_LOOSE for triggered builds and cannot
-   * be overridden in the build configuration file.
-   * 
- * - * .google.devtools.cloudbuild.v1.BuildOptions.SubstitutionOption substitution_option = 4; - * - * - * @return The enum numeric value on the wire for substitutionOption. - */ - @java.lang.Override - public int getSubstitutionOptionValue() { - return substitutionOption_; - } - /** - * - * - *
-   * Option to specify behavior when there is an error in the substitution
-   * checks.
-   * NOTE: this is always set to ALLOW_LOOSE for triggered builds and cannot
-   * be overridden in the build configuration file.
-   * 
- * - * .google.devtools.cloudbuild.v1.BuildOptions.SubstitutionOption substitution_option = 4; - * - * - * @return The substitutionOption. - */ - @java.lang.Override - public com.google.cloudbuild.v1.BuildOptions.SubstitutionOption getSubstitutionOption() { - @SuppressWarnings("deprecation") - com.google.cloudbuild.v1.BuildOptions.SubstitutionOption result = - com.google.cloudbuild.v1.BuildOptions.SubstitutionOption.valueOf(substitutionOption_); - return result == null - ? com.google.cloudbuild.v1.BuildOptions.SubstitutionOption.UNRECOGNIZED - : result; - } - - public static final int DYNAMIC_SUBSTITUTIONS_FIELD_NUMBER = 17; - private boolean dynamicSubstitutions_; - /** - * - * - *
-   * Option to specify whether or not to apply bash style string
-   * operations to the substitutions.
-   * NOTE: this is always enabled for triggered builds and cannot be
-   * overridden in the build configuration file.
-   * 
- * - * bool dynamic_substitutions = 17; - * - * @return The dynamicSubstitutions. - */ - @java.lang.Override - public boolean getDynamicSubstitutions() { - return dynamicSubstitutions_; - } - - public static final int LOG_STREAMING_OPTION_FIELD_NUMBER = 5; - private int logStreamingOption_; - /** - * - * - *
-   * Option to define build log streaming behavior to Google Cloud
-   * Storage.
-   * 
- * - * .google.devtools.cloudbuild.v1.BuildOptions.LogStreamingOption log_streaming_option = 5; - * - * - * @return The enum numeric value on the wire for logStreamingOption. - */ - @java.lang.Override - public int getLogStreamingOptionValue() { - return logStreamingOption_; - } - /** - * - * - *
-   * Option to define build log streaming behavior to Google Cloud
-   * Storage.
-   * 
- * - * .google.devtools.cloudbuild.v1.BuildOptions.LogStreamingOption log_streaming_option = 5; - * - * - * @return The logStreamingOption. - */ - @java.lang.Override - public com.google.cloudbuild.v1.BuildOptions.LogStreamingOption getLogStreamingOption() { - @SuppressWarnings("deprecation") - com.google.cloudbuild.v1.BuildOptions.LogStreamingOption result = - com.google.cloudbuild.v1.BuildOptions.LogStreamingOption.valueOf(logStreamingOption_); - return result == null - ? com.google.cloudbuild.v1.BuildOptions.LogStreamingOption.UNRECOGNIZED - : result; - } - - public static final int WORKER_POOL_FIELD_NUMBER = 7; - private volatile java.lang.Object workerPool_; - /** - * - * - *
-   * This field deprecated; please use `pool.name` instead.
-   * 
- * - * string worker_pool = 7 [deprecated = true]; - * - * @deprecated google.devtools.cloudbuild.v1.BuildOptions.worker_pool is deprecated. See - * google/devtools/cloudbuild/v1/cloudbuild.proto;l=1769 - * @return The workerPool. - */ - @java.lang.Override - @java.lang.Deprecated - public java.lang.String getWorkerPool() { - java.lang.Object ref = workerPool_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - workerPool_ = s; - return s; - } - } - /** - * - * - *
-   * This field deprecated; please use `pool.name` instead.
-   * 
- * - * string worker_pool = 7 [deprecated = true]; - * - * @deprecated google.devtools.cloudbuild.v1.BuildOptions.worker_pool is deprecated. See - * google/devtools/cloudbuild/v1/cloudbuild.proto;l=1769 - * @return The bytes for workerPool. - */ - @java.lang.Override - @java.lang.Deprecated - public com.google.protobuf.ByteString getWorkerPoolBytes() { - java.lang.Object ref = workerPool_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - workerPool_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int POOL_FIELD_NUMBER = 19; - private com.google.cloudbuild.v1.BuildOptions.PoolOption pool_; - /** - * - * - *
-   * Optional. Specification for execution on a `WorkerPool`.
-   * See [running builds in a private
-   * pool](https://cloud.google.com/build/docs/private-pools/run-builds-in-private-pool)
-   * for more information.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.BuildOptions.PoolOption pool = 19 [(.google.api.field_behavior) = OPTIONAL]; - * - * - * @return Whether the pool field is set. - */ - @java.lang.Override - public boolean hasPool() { - return pool_ != null; - } - /** - * - * - *
-   * Optional. Specification for execution on a `WorkerPool`.
-   * See [running builds in a private
-   * pool](https://cloud.google.com/build/docs/private-pools/run-builds-in-private-pool)
-   * for more information.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.BuildOptions.PoolOption pool = 19 [(.google.api.field_behavior) = OPTIONAL]; - * - * - * @return The pool. - */ - @java.lang.Override - public com.google.cloudbuild.v1.BuildOptions.PoolOption getPool() { - return pool_ == null - ? com.google.cloudbuild.v1.BuildOptions.PoolOption.getDefaultInstance() - : pool_; - } - /** - * - * - *
-   * Optional. Specification for execution on a `WorkerPool`.
-   * See [running builds in a private
-   * pool](https://cloud.google.com/build/docs/private-pools/run-builds-in-private-pool)
-   * for more information.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.BuildOptions.PoolOption pool = 19 [(.google.api.field_behavior) = OPTIONAL]; - * - */ - @java.lang.Override - public com.google.cloudbuild.v1.BuildOptions.PoolOptionOrBuilder getPoolOrBuilder() { - return getPool(); - } - - public static final int LOGGING_FIELD_NUMBER = 11; - private int logging_; - /** - * - * - *
-   * Option to specify the logging mode, which determines if and where build
-   * logs are stored.
-   * 
- * - * .google.devtools.cloudbuild.v1.BuildOptions.LoggingMode logging = 11; - * - * @return The enum numeric value on the wire for logging. - */ - @java.lang.Override - public int getLoggingValue() { - return logging_; - } - /** - * - * - *
-   * Option to specify the logging mode, which determines if and where build
-   * logs are stored.
-   * 
- * - * .google.devtools.cloudbuild.v1.BuildOptions.LoggingMode logging = 11; - * - * @return The logging. - */ - @java.lang.Override - public com.google.cloudbuild.v1.BuildOptions.LoggingMode getLogging() { - @SuppressWarnings("deprecation") - com.google.cloudbuild.v1.BuildOptions.LoggingMode result = - com.google.cloudbuild.v1.BuildOptions.LoggingMode.valueOf(logging_); - return result == null ? com.google.cloudbuild.v1.BuildOptions.LoggingMode.UNRECOGNIZED : result; - } - - public static final int ENV_FIELD_NUMBER = 12; - private com.google.protobuf.LazyStringList env_; - /** - * - * - *
-   * A list of global environment variable definitions that will exist for all
-   * build steps in this build. If a variable is defined in both globally and in
-   * a build step, the variable will use the build step value.
-   * The elements are of the form "KEY=VALUE" for the environment variable "KEY"
-   * being given the value "VALUE".
-   * 
- * - * repeated string env = 12; - * - * @return A list containing the env. - */ - public com.google.protobuf.ProtocolStringList getEnvList() { - return env_; - } - /** - * - * - *
-   * A list of global environment variable definitions that will exist for all
-   * build steps in this build. If a variable is defined in both globally and in
-   * a build step, the variable will use the build step value.
-   * The elements are of the form "KEY=VALUE" for the environment variable "KEY"
-   * being given the value "VALUE".
-   * 
- * - * repeated string env = 12; - * - * @return The count of env. - */ - public int getEnvCount() { - return env_.size(); - } - /** - * - * - *
-   * A list of global environment variable definitions that will exist for all
-   * build steps in this build. If a variable is defined in both globally and in
-   * a build step, the variable will use the build step value.
-   * The elements are of the form "KEY=VALUE" for the environment variable "KEY"
-   * being given the value "VALUE".
-   * 
- * - * repeated string env = 12; - * - * @param index The index of the element to return. - * @return The env at the given index. - */ - public java.lang.String getEnv(int index) { - return env_.get(index); - } - /** - * - * - *
-   * A list of global environment variable definitions that will exist for all
-   * build steps in this build. If a variable is defined in both globally and in
-   * a build step, the variable will use the build step value.
-   * The elements are of the form "KEY=VALUE" for the environment variable "KEY"
-   * being given the value "VALUE".
-   * 
- * - * repeated string env = 12; - * - * @param index The index of the value to return. - * @return The bytes of the env at the given index. - */ - public com.google.protobuf.ByteString getEnvBytes(int index) { - return env_.getByteString(index); - } - - public static final int SECRET_ENV_FIELD_NUMBER = 13; - private com.google.protobuf.LazyStringList secretEnv_; - /** - * - * - *
-   * A list of global environment variables, which are encrypted using a Cloud
-   * Key Management Service crypto key. These values must be specified in the
-   * build's `Secret`. These variables will be available to all build steps
-   * in this build.
-   * 
- * - * repeated string secret_env = 13; - * - * @return A list containing the secretEnv. - */ - public com.google.protobuf.ProtocolStringList getSecretEnvList() { - return secretEnv_; - } - /** - * - * - *
-   * A list of global environment variables, which are encrypted using a Cloud
-   * Key Management Service crypto key. These values must be specified in the
-   * build's `Secret`. These variables will be available to all build steps
-   * in this build.
-   * 
- * - * repeated string secret_env = 13; - * - * @return The count of secretEnv. - */ - public int getSecretEnvCount() { - return secretEnv_.size(); - } - /** - * - * - *
-   * A list of global environment variables, which are encrypted using a Cloud
-   * Key Management Service crypto key. These values must be specified in the
-   * build's `Secret`. These variables will be available to all build steps
-   * in this build.
-   * 
- * - * repeated string secret_env = 13; - * - * @param index The index of the element to return. - * @return The secretEnv at the given index. - */ - public java.lang.String getSecretEnv(int index) { - return secretEnv_.get(index); - } - /** - * - * - *
-   * A list of global environment variables, which are encrypted using a Cloud
-   * Key Management Service crypto key. These values must be specified in the
-   * build's `Secret`. These variables will be available to all build steps
-   * in this build.
-   * 
- * - * repeated string secret_env = 13; - * - * @param index The index of the value to return. - * @return The bytes of the secretEnv at the given index. - */ - public com.google.protobuf.ByteString getSecretEnvBytes(int index) { - return secretEnv_.getByteString(index); - } - - public static final int VOLUMES_FIELD_NUMBER = 14; - private java.util.List volumes_; - /** - * - * - *
-   * Global list of volumes to mount for ALL build steps
-   * Each volume is created as an empty volume prior to starting the build
-   * process. Upon completion of the build, volumes and their contents are
-   * discarded. Global volume names and paths cannot conflict with the volumes
-   * defined a build step.
-   * Using a global volume in a build with only one step is not valid as
-   * it is indicative of a build request with an incorrect configuration.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 14; - */ - @java.lang.Override - public java.util.List getVolumesList() { - return volumes_; - } - /** - * - * - *
-   * Global list of volumes to mount for ALL build steps
-   * Each volume is created as an empty volume prior to starting the build
-   * process. Upon completion of the build, volumes and their contents are
-   * discarded. Global volume names and paths cannot conflict with the volumes
-   * defined a build step.
-   * Using a global volume in a build with only one step is not valid as
-   * it is indicative of a build request with an incorrect configuration.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 14; - */ - @java.lang.Override - public java.util.List - getVolumesOrBuilderList() { - return volumes_; - } - /** - * - * - *
-   * Global list of volumes to mount for ALL build steps
-   * Each volume is created as an empty volume prior to starting the build
-   * process. Upon completion of the build, volumes and their contents are
-   * discarded. Global volume names and paths cannot conflict with the volumes
-   * defined a build step.
-   * Using a global volume in a build with only one step is not valid as
-   * it is indicative of a build request with an incorrect configuration.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 14; - */ - @java.lang.Override - public int getVolumesCount() { - return volumes_.size(); - } - /** - * - * - *
-   * Global list of volumes to mount for ALL build steps
-   * Each volume is created as an empty volume prior to starting the build
-   * process. Upon completion of the build, volumes and their contents are
-   * discarded. Global volume names and paths cannot conflict with the volumes
-   * defined a build step.
-   * Using a global volume in a build with only one step is not valid as
-   * it is indicative of a build request with an incorrect configuration.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 14; - */ - @java.lang.Override - public com.google.cloudbuild.v1.Volume getVolumes(int index) { - return volumes_.get(index); - } - /** - * - * - *
-   * Global list of volumes to mount for ALL build steps
-   * Each volume is created as an empty volume prior to starting the build
-   * process. Upon completion of the build, volumes and their contents are
-   * discarded. Global volume names and paths cannot conflict with the volumes
-   * defined a build step.
-   * Using a global volume in a build with only one step is not valid as
-   * it is indicative of a build request with an incorrect configuration.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 14; - */ - @java.lang.Override - public com.google.cloudbuild.v1.VolumeOrBuilder getVolumesOrBuilder(int index) { - return volumes_.get(index); - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - getSerializedSize(); - if (getSourceProvenanceHashList().size() > 0) { - output.writeUInt32NoTag(10); - output.writeUInt32NoTag(sourceProvenanceHashMemoizedSerializedSize); - } - for (int i = 0; i < sourceProvenanceHash_.size(); i++) { - output.writeEnumNoTag(sourceProvenanceHash_.get(i)); - } - if (requestedVerifyOption_ - != com.google.cloudbuild.v1.BuildOptions.VerifyOption.NOT_VERIFIED.getNumber()) { - output.writeEnum(2, requestedVerifyOption_); - } - if (machineType_ != com.google.cloudbuild.v1.BuildOptions.MachineType.UNSPECIFIED.getNumber()) { - output.writeEnum(3, machineType_); - } - if (substitutionOption_ - != com.google.cloudbuild.v1.BuildOptions.SubstitutionOption.MUST_MATCH.getNumber()) { - output.writeEnum(4, substitutionOption_); - } - if (logStreamingOption_ - != com.google.cloudbuild.v1.BuildOptions.LogStreamingOption.STREAM_DEFAULT.getNumber()) { - output.writeEnum(5, logStreamingOption_); - } - if (diskSizeGb_ != 0L) { - output.writeInt64(6, diskSizeGb_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(workerPool_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 7, workerPool_); - } - if (logging_ - != com.google.cloudbuild.v1.BuildOptions.LoggingMode.LOGGING_UNSPECIFIED.getNumber()) { - output.writeEnum(11, logging_); - } - for (int i = 0; i < env_.size(); i++) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 12, env_.getRaw(i)); - } - for (int i = 0; i < secretEnv_.size(); i++) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 13, secretEnv_.getRaw(i)); - } - for (int i = 0; i < volumes_.size(); i++) { - output.writeMessage(14, volumes_.get(i)); - } - if (dynamicSubstitutions_ != false) { - output.writeBool(17, dynamicSubstitutions_); - } - if (pool_ != null) { - output.writeMessage(19, getPool()); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - { - int dataSize = 0; - for (int i = 0; i < sourceProvenanceHash_.size(); i++) { - dataSize += - com.google.protobuf.CodedOutputStream.computeEnumSizeNoTag( - sourceProvenanceHash_.get(i)); - } - size += dataSize; - if (!getSourceProvenanceHashList().isEmpty()) { - size += 1; - size += com.google.protobuf.CodedOutputStream.computeUInt32SizeNoTag(dataSize); - } - sourceProvenanceHashMemoizedSerializedSize = dataSize; - } - if (requestedVerifyOption_ - != com.google.cloudbuild.v1.BuildOptions.VerifyOption.NOT_VERIFIED.getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(2, requestedVerifyOption_); - } - if (machineType_ != com.google.cloudbuild.v1.BuildOptions.MachineType.UNSPECIFIED.getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(3, machineType_); - } - if (substitutionOption_ - != com.google.cloudbuild.v1.BuildOptions.SubstitutionOption.MUST_MATCH.getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(4, substitutionOption_); - } - if (logStreamingOption_ - != com.google.cloudbuild.v1.BuildOptions.LogStreamingOption.STREAM_DEFAULT.getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(5, logStreamingOption_); - } - if (diskSizeGb_ != 0L) { - size += com.google.protobuf.CodedOutputStream.computeInt64Size(6, diskSizeGb_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(workerPool_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(7, workerPool_); - } - if (logging_ - != com.google.cloudbuild.v1.BuildOptions.LoggingMode.LOGGING_UNSPECIFIED.getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(11, logging_); - } - { - int dataSize = 0; - for (int i = 0; i < env_.size(); i++) { - dataSize += computeStringSizeNoTag(env_.getRaw(i)); - } - size += dataSize; - size += 1 * getEnvList().size(); - } - { - int dataSize = 0; - for (int i = 0; i < secretEnv_.size(); i++) { - dataSize += computeStringSizeNoTag(secretEnv_.getRaw(i)); - } - size += dataSize; - size += 1 * getSecretEnvList().size(); - } - for (int i = 0; i < volumes_.size(); i++) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(14, volumes_.get(i)); - } - if (dynamicSubstitutions_ != false) { - size += com.google.protobuf.CodedOutputStream.computeBoolSize(17, dynamicSubstitutions_); - } - if (pool_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(19, getPool()); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.BuildOptions)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.BuildOptions other = (com.google.cloudbuild.v1.BuildOptions) obj; - - if (!sourceProvenanceHash_.equals(other.sourceProvenanceHash_)) return false; - if (requestedVerifyOption_ != other.requestedVerifyOption_) return false; - if (machineType_ != other.machineType_) return false; - if (getDiskSizeGb() != other.getDiskSizeGb()) return false; - if (substitutionOption_ != other.substitutionOption_) return false; - if (getDynamicSubstitutions() != other.getDynamicSubstitutions()) return false; - if (logStreamingOption_ != other.logStreamingOption_) return false; - if (!getWorkerPool().equals(other.getWorkerPool())) return false; - if (hasPool() != other.hasPool()) return false; - if (hasPool()) { - if (!getPool().equals(other.getPool())) return false; - } - if (logging_ != other.logging_) return false; - if (!getEnvList().equals(other.getEnvList())) return false; - if (!getSecretEnvList().equals(other.getSecretEnvList())) return false; - if (!getVolumesList().equals(other.getVolumesList())) return false; - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (getSourceProvenanceHashCount() > 0) { - hash = (37 * hash) + SOURCE_PROVENANCE_HASH_FIELD_NUMBER; - hash = (53 * hash) + sourceProvenanceHash_.hashCode(); - } - hash = (37 * hash) + REQUESTED_VERIFY_OPTION_FIELD_NUMBER; - hash = (53 * hash) + requestedVerifyOption_; - hash = (37 * hash) + MACHINE_TYPE_FIELD_NUMBER; - hash = (53 * hash) + machineType_; - hash = (37 * hash) + DISK_SIZE_GB_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getDiskSizeGb()); - hash = (37 * hash) + SUBSTITUTION_OPTION_FIELD_NUMBER; - hash = (53 * hash) + substitutionOption_; - hash = (37 * hash) + DYNAMIC_SUBSTITUTIONS_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getDynamicSubstitutions()); - hash = (37 * hash) + LOG_STREAMING_OPTION_FIELD_NUMBER; - hash = (53 * hash) + logStreamingOption_; - hash = (37 * hash) + WORKER_POOL_FIELD_NUMBER; - hash = (53 * hash) + getWorkerPool().hashCode(); - if (hasPool()) { - hash = (37 * hash) + POOL_FIELD_NUMBER; - hash = (53 * hash) + getPool().hashCode(); - } - hash = (37 * hash) + LOGGING_FIELD_NUMBER; - hash = (53 * hash) + logging_; - if (getEnvCount() > 0) { - hash = (37 * hash) + ENV_FIELD_NUMBER; - hash = (53 * hash) + getEnvList().hashCode(); - } - if (getSecretEnvCount() > 0) { - hash = (37 * hash) + SECRET_ENV_FIELD_NUMBER; - hash = (53 * hash) + getSecretEnvList().hashCode(); - } - if (getVolumesCount() > 0) { - hash = (37 * hash) + VOLUMES_FIELD_NUMBER; - hash = (53 * hash) + getVolumesList().hashCode(); - } - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.BuildOptions parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.BuildOptions parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.BuildOptions parseFrom(com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.BuildOptions parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.BuildOptions parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.BuildOptions parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.BuildOptions parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.BuildOptions parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.BuildOptions parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.BuildOptions parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.BuildOptions parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.BuildOptions parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.BuildOptions prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * Optional arguments to enable specific features of builds.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.BuildOptions} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.BuildOptions) - com.google.cloudbuild.v1.BuildOptionsOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_BuildOptions_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_BuildOptions_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.BuildOptions.class, - com.google.cloudbuild.v1.BuildOptions.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.BuildOptions.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - sourceProvenanceHash_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - requestedVerifyOption_ = 0; - - machineType_ = 0; - - diskSizeGb_ = 0L; - - substitutionOption_ = 0; - - dynamicSubstitutions_ = false; - - logStreamingOption_ = 0; - - workerPool_ = ""; - - if (poolBuilder_ == null) { - pool_ = null; - } else { - pool_ = null; - poolBuilder_ = null; - } - logging_ = 0; - - env_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000002); - secretEnv_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000004); - if (volumesBuilder_ == null) { - volumes_ = java.util.Collections.emptyList(); - } else { - volumes_ = null; - volumesBuilder_.clear(); - } - bitField0_ = (bitField0_ & ~0x00000008); - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_BuildOptions_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.BuildOptions getDefaultInstanceForType() { - return com.google.cloudbuild.v1.BuildOptions.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.BuildOptions build() { - com.google.cloudbuild.v1.BuildOptions result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.BuildOptions buildPartial() { - com.google.cloudbuild.v1.BuildOptions result = - new com.google.cloudbuild.v1.BuildOptions(this); - int from_bitField0_ = bitField0_; - if (((bitField0_ & 0x00000001) != 0)) { - sourceProvenanceHash_ = java.util.Collections.unmodifiableList(sourceProvenanceHash_); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.sourceProvenanceHash_ = sourceProvenanceHash_; - result.requestedVerifyOption_ = requestedVerifyOption_; - result.machineType_ = machineType_; - result.diskSizeGb_ = diskSizeGb_; - result.substitutionOption_ = substitutionOption_; - result.dynamicSubstitutions_ = dynamicSubstitutions_; - result.logStreamingOption_ = logStreamingOption_; - result.workerPool_ = workerPool_; - if (poolBuilder_ == null) { - result.pool_ = pool_; - } else { - result.pool_ = poolBuilder_.build(); - } - result.logging_ = logging_; - if (((bitField0_ & 0x00000002) != 0)) { - env_ = env_.getUnmodifiableView(); - bitField0_ = (bitField0_ & ~0x00000002); - } - result.env_ = env_; - if (((bitField0_ & 0x00000004) != 0)) { - secretEnv_ = secretEnv_.getUnmodifiableView(); - bitField0_ = (bitField0_ & ~0x00000004); - } - result.secretEnv_ = secretEnv_; - if (volumesBuilder_ == null) { - if (((bitField0_ & 0x00000008) != 0)) { - volumes_ = java.util.Collections.unmodifiableList(volumes_); - bitField0_ = (bitField0_ & ~0x00000008); - } - result.volumes_ = volumes_; - } else { - result.volumes_ = volumesBuilder_.build(); - } - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.BuildOptions) { - return mergeFrom((com.google.cloudbuild.v1.BuildOptions) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.BuildOptions other) { - if (other == com.google.cloudbuild.v1.BuildOptions.getDefaultInstance()) return this; - if (!other.sourceProvenanceHash_.isEmpty()) { - if (sourceProvenanceHash_.isEmpty()) { - sourceProvenanceHash_ = other.sourceProvenanceHash_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureSourceProvenanceHashIsMutable(); - sourceProvenanceHash_.addAll(other.sourceProvenanceHash_); - } - onChanged(); - } - if (other.requestedVerifyOption_ != 0) { - setRequestedVerifyOptionValue(other.getRequestedVerifyOptionValue()); - } - if (other.machineType_ != 0) { - setMachineTypeValue(other.getMachineTypeValue()); - } - if (other.getDiskSizeGb() != 0L) { - setDiskSizeGb(other.getDiskSizeGb()); - } - if (other.substitutionOption_ != 0) { - setSubstitutionOptionValue(other.getSubstitutionOptionValue()); - } - if (other.getDynamicSubstitutions() != false) { - setDynamicSubstitutions(other.getDynamicSubstitutions()); - } - if (other.logStreamingOption_ != 0) { - setLogStreamingOptionValue(other.getLogStreamingOptionValue()); - } - if (!other.getWorkerPool().isEmpty()) { - workerPool_ = other.workerPool_; - onChanged(); - } - if (other.hasPool()) { - mergePool(other.getPool()); - } - if (other.logging_ != 0) { - setLoggingValue(other.getLoggingValue()); - } - if (!other.env_.isEmpty()) { - if (env_.isEmpty()) { - env_ = other.env_; - bitField0_ = (bitField0_ & ~0x00000002); - } else { - ensureEnvIsMutable(); - env_.addAll(other.env_); - } - onChanged(); - } - if (!other.secretEnv_.isEmpty()) { - if (secretEnv_.isEmpty()) { - secretEnv_ = other.secretEnv_; - bitField0_ = (bitField0_ & ~0x00000004); - } else { - ensureSecretEnvIsMutable(); - secretEnv_.addAll(other.secretEnv_); - } - onChanged(); - } - if (volumesBuilder_ == null) { - if (!other.volumes_.isEmpty()) { - if (volumes_.isEmpty()) { - volumes_ = other.volumes_; - bitField0_ = (bitField0_ & ~0x00000008); - } else { - ensureVolumesIsMutable(); - volumes_.addAll(other.volumes_); - } - onChanged(); - } - } else { - if (!other.volumes_.isEmpty()) { - if (volumesBuilder_.isEmpty()) { - volumesBuilder_.dispose(); - volumesBuilder_ = null; - volumes_ = other.volumes_; - bitField0_ = (bitField0_ & ~0x00000008); - volumesBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders - ? getVolumesFieldBuilder() - : null; - } else { - volumesBuilder_.addAllMessages(other.volumes_); - } - } - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 8: - { - int tmpRaw = input.readEnum(); - ensureSourceProvenanceHashIsMutable(); - sourceProvenanceHash_.add(tmpRaw); - break; - } // case 8 - case 10: - { - int length = input.readRawVarint32(); - int oldLimit = input.pushLimit(length); - while (input.getBytesUntilLimit() > 0) { - int tmpRaw = input.readEnum(); - ensureSourceProvenanceHashIsMutable(); - sourceProvenanceHash_.add(tmpRaw); - } - input.popLimit(oldLimit); - break; - } // case 10 - case 16: - { - requestedVerifyOption_ = input.readEnum(); - - break; - } // case 16 - case 24: - { - machineType_ = input.readEnum(); - - break; - } // case 24 - case 32: - { - substitutionOption_ = input.readEnum(); - - break; - } // case 32 - case 40: - { - logStreamingOption_ = input.readEnum(); - - break; - } // case 40 - case 48: - { - diskSizeGb_ = input.readInt64(); - - break; - } // case 48 - case 58: - { - workerPool_ = input.readStringRequireUtf8(); - - break; - } // case 58 - case 88: - { - logging_ = input.readEnum(); - - break; - } // case 88 - case 98: - { - java.lang.String s = input.readStringRequireUtf8(); - ensureEnvIsMutable(); - env_.add(s); - break; - } // case 98 - case 106: - { - java.lang.String s = input.readStringRequireUtf8(); - ensureSecretEnvIsMutable(); - secretEnv_.add(s); - break; - } // case 106 - case 114: - { - com.google.cloudbuild.v1.Volume m = - input.readMessage(com.google.cloudbuild.v1.Volume.parser(), extensionRegistry); - if (volumesBuilder_ == null) { - ensureVolumesIsMutable(); - volumes_.add(m); - } else { - volumesBuilder_.addMessage(m); - } - break; - } // case 114 - case 136: - { - dynamicSubstitutions_ = input.readBool(); - - break; - } // case 136 - case 154: - { - input.readMessage(getPoolFieldBuilder().getBuilder(), extensionRegistry); - - break; - } // case 154 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private int bitField0_; - - private java.util.List sourceProvenanceHash_ = - java.util.Collections.emptyList(); - - private void ensureSourceProvenanceHashIsMutable() { - if (!((bitField0_ & 0x00000001) != 0)) { - sourceProvenanceHash_ = new java.util.ArrayList(sourceProvenanceHash_); - bitField0_ |= 0x00000001; - } - } - /** - * - * - *
-     * Requested hash for SourceProvenance.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Hash.HashType source_provenance_hash = 1; - * - * - * @return A list containing the sourceProvenanceHash. - */ - public java.util.List getSourceProvenanceHashList() { - return new com.google.protobuf.Internal.ListAdapter< - java.lang.Integer, com.google.cloudbuild.v1.Hash.HashType>( - sourceProvenanceHash_, sourceProvenanceHash_converter_); - } - /** - * - * - *
-     * Requested hash for SourceProvenance.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Hash.HashType source_provenance_hash = 1; - * - * - * @return The count of sourceProvenanceHash. - */ - public int getSourceProvenanceHashCount() { - return sourceProvenanceHash_.size(); - } - /** - * - * - *
-     * Requested hash for SourceProvenance.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Hash.HashType source_provenance_hash = 1; - * - * - * @param index The index of the element to return. - * @return The sourceProvenanceHash at the given index. - */ - public com.google.cloudbuild.v1.Hash.HashType getSourceProvenanceHash(int index) { - return sourceProvenanceHash_converter_.convert(sourceProvenanceHash_.get(index)); - } - /** - * - * - *
-     * Requested hash for SourceProvenance.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Hash.HashType source_provenance_hash = 1; - * - * - * @param index The index to set the value at. - * @param value The sourceProvenanceHash to set. - * @return This builder for chaining. - */ - public Builder setSourceProvenanceHash( - int index, com.google.cloudbuild.v1.Hash.HashType value) { - if (value == null) { - throw new NullPointerException(); - } - ensureSourceProvenanceHashIsMutable(); - sourceProvenanceHash_.set(index, value.getNumber()); - onChanged(); - return this; - } - /** - * - * - *
-     * Requested hash for SourceProvenance.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Hash.HashType source_provenance_hash = 1; - * - * - * @param value The sourceProvenanceHash to add. - * @return This builder for chaining. - */ - public Builder addSourceProvenanceHash(com.google.cloudbuild.v1.Hash.HashType value) { - if (value == null) { - throw new NullPointerException(); - } - ensureSourceProvenanceHashIsMutable(); - sourceProvenanceHash_.add(value.getNumber()); - onChanged(); - return this; - } - /** - * - * - *
-     * Requested hash for SourceProvenance.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Hash.HashType source_provenance_hash = 1; - * - * - * @param values The sourceProvenanceHash to add. - * @return This builder for chaining. - */ - public Builder addAllSourceProvenanceHash( - java.lang.Iterable values) { - ensureSourceProvenanceHashIsMutable(); - for (com.google.cloudbuild.v1.Hash.HashType value : values) { - sourceProvenanceHash_.add(value.getNumber()); - } - onChanged(); - return this; - } - /** - * - * - *
-     * Requested hash for SourceProvenance.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Hash.HashType source_provenance_hash = 1; - * - * - * @return This builder for chaining. - */ - public Builder clearSourceProvenanceHash() { - sourceProvenanceHash_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - return this; - } - /** - * - * - *
-     * Requested hash for SourceProvenance.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Hash.HashType source_provenance_hash = 1; - * - * - * @return A list containing the enum numeric values on the wire for sourceProvenanceHash. - */ - public java.util.List getSourceProvenanceHashValueList() { - return java.util.Collections.unmodifiableList(sourceProvenanceHash_); - } - /** - * - * - *
-     * Requested hash for SourceProvenance.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Hash.HashType source_provenance_hash = 1; - * - * - * @param index The index of the value to return. - * @return The enum numeric value on the wire of sourceProvenanceHash at the given index. - */ - public int getSourceProvenanceHashValue(int index) { - return sourceProvenanceHash_.get(index); - } - /** - * - * - *
-     * Requested hash for SourceProvenance.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Hash.HashType source_provenance_hash = 1; - * - * - * @param index The index to set the value at. - * @param value The enum numeric value on the wire for sourceProvenanceHash to set. - * @return This builder for chaining. - */ - public Builder setSourceProvenanceHashValue(int index, int value) { - ensureSourceProvenanceHashIsMutable(); - sourceProvenanceHash_.set(index, value); - onChanged(); - return this; - } - /** - * - * - *
-     * Requested hash for SourceProvenance.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Hash.HashType source_provenance_hash = 1; - * - * - * @param value The enum numeric value on the wire for sourceProvenanceHash to add. - * @return This builder for chaining. - */ - public Builder addSourceProvenanceHashValue(int value) { - ensureSourceProvenanceHashIsMutable(); - sourceProvenanceHash_.add(value); - onChanged(); - return this; - } - /** - * - * - *
-     * Requested hash for SourceProvenance.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Hash.HashType source_provenance_hash = 1; - * - * - * @param values The enum numeric values on the wire for sourceProvenanceHash to add. - * @return This builder for chaining. - */ - public Builder addAllSourceProvenanceHashValue(java.lang.Iterable values) { - ensureSourceProvenanceHashIsMutable(); - for (int value : values) { - sourceProvenanceHash_.add(value); - } - onChanged(); - return this; - } - - private int requestedVerifyOption_ = 0; - /** - * - * - *
-     * Requested verifiability options.
-     * 
- * - * .google.devtools.cloudbuild.v1.BuildOptions.VerifyOption requested_verify_option = 2; - * - * - * @return The enum numeric value on the wire for requestedVerifyOption. - */ - @java.lang.Override - public int getRequestedVerifyOptionValue() { - return requestedVerifyOption_; - } - /** - * - * - *
-     * Requested verifiability options.
-     * 
- * - * .google.devtools.cloudbuild.v1.BuildOptions.VerifyOption requested_verify_option = 2; - * - * - * @param value The enum numeric value on the wire for requestedVerifyOption to set. - * @return This builder for chaining. - */ - public Builder setRequestedVerifyOptionValue(int value) { - - requestedVerifyOption_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Requested verifiability options.
-     * 
- * - * .google.devtools.cloudbuild.v1.BuildOptions.VerifyOption requested_verify_option = 2; - * - * - * @return The requestedVerifyOption. - */ - @java.lang.Override - public com.google.cloudbuild.v1.BuildOptions.VerifyOption getRequestedVerifyOption() { - @SuppressWarnings("deprecation") - com.google.cloudbuild.v1.BuildOptions.VerifyOption result = - com.google.cloudbuild.v1.BuildOptions.VerifyOption.valueOf(requestedVerifyOption_); - return result == null - ? com.google.cloudbuild.v1.BuildOptions.VerifyOption.UNRECOGNIZED - : result; - } - /** - * - * - *
-     * Requested verifiability options.
-     * 
- * - * .google.devtools.cloudbuild.v1.BuildOptions.VerifyOption requested_verify_option = 2; - * - * - * @param value The requestedVerifyOption to set. - * @return This builder for chaining. - */ - public Builder setRequestedVerifyOption( - com.google.cloudbuild.v1.BuildOptions.VerifyOption value) { - if (value == null) { - throw new NullPointerException(); - } - - requestedVerifyOption_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-     * Requested verifiability options.
-     * 
- * - * .google.devtools.cloudbuild.v1.BuildOptions.VerifyOption requested_verify_option = 2; - * - * - * @return This builder for chaining. - */ - public Builder clearRequestedVerifyOption() { - - requestedVerifyOption_ = 0; - onChanged(); - return this; - } - - private int machineType_ = 0; - /** - * - * - *
-     * Compute Engine machine type on which to run the build.
-     * 
- * - * .google.devtools.cloudbuild.v1.BuildOptions.MachineType machine_type = 3; - * - * @return The enum numeric value on the wire for machineType. - */ - @java.lang.Override - public int getMachineTypeValue() { - return machineType_; - } - /** - * - * - *
-     * Compute Engine machine type on which to run the build.
-     * 
- * - * .google.devtools.cloudbuild.v1.BuildOptions.MachineType machine_type = 3; - * - * @param value The enum numeric value on the wire for machineType to set. - * @return This builder for chaining. - */ - public Builder setMachineTypeValue(int value) { - - machineType_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Compute Engine machine type on which to run the build.
-     * 
- * - * .google.devtools.cloudbuild.v1.BuildOptions.MachineType machine_type = 3; - * - * @return The machineType. - */ - @java.lang.Override - public com.google.cloudbuild.v1.BuildOptions.MachineType getMachineType() { - @SuppressWarnings("deprecation") - com.google.cloudbuild.v1.BuildOptions.MachineType result = - com.google.cloudbuild.v1.BuildOptions.MachineType.valueOf(machineType_); - return result == null - ? com.google.cloudbuild.v1.BuildOptions.MachineType.UNRECOGNIZED - : result; - } - /** - * - * - *
-     * Compute Engine machine type on which to run the build.
-     * 
- * - * .google.devtools.cloudbuild.v1.BuildOptions.MachineType machine_type = 3; - * - * @param value The machineType to set. - * @return This builder for chaining. - */ - public Builder setMachineType(com.google.cloudbuild.v1.BuildOptions.MachineType value) { - if (value == null) { - throw new NullPointerException(); - } - - machineType_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-     * Compute Engine machine type on which to run the build.
-     * 
- * - * .google.devtools.cloudbuild.v1.BuildOptions.MachineType machine_type = 3; - * - * @return This builder for chaining. - */ - public Builder clearMachineType() { - - machineType_ = 0; - onChanged(); - return this; - } - - private long diskSizeGb_; - /** - * - * - *
-     * Requested disk size for the VM that runs the build. Note that this is *NOT*
-     * "disk free"; some of the space will be used by the operating system and
-     * build utilities. Also note that this is the minimum disk size that will be
-     * allocated for the build -- the build may run with a larger disk than
-     * requested. At present, the maximum disk size is 1000GB; builds that request
-     * more than the maximum are rejected with an error.
-     * 
- * - * int64 disk_size_gb = 6; - * - * @return The diskSizeGb. - */ - @java.lang.Override - public long getDiskSizeGb() { - return diskSizeGb_; - } - /** - * - * - *
-     * Requested disk size for the VM that runs the build. Note that this is *NOT*
-     * "disk free"; some of the space will be used by the operating system and
-     * build utilities. Also note that this is the minimum disk size that will be
-     * allocated for the build -- the build may run with a larger disk than
-     * requested. At present, the maximum disk size is 1000GB; builds that request
-     * more than the maximum are rejected with an error.
-     * 
- * - * int64 disk_size_gb = 6; - * - * @param value The diskSizeGb to set. - * @return This builder for chaining. - */ - public Builder setDiskSizeGb(long value) { - - diskSizeGb_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Requested disk size for the VM that runs the build. Note that this is *NOT*
-     * "disk free"; some of the space will be used by the operating system and
-     * build utilities. Also note that this is the minimum disk size that will be
-     * allocated for the build -- the build may run with a larger disk than
-     * requested. At present, the maximum disk size is 1000GB; builds that request
-     * more than the maximum are rejected with an error.
-     * 
- * - * int64 disk_size_gb = 6; - * - * @return This builder for chaining. - */ - public Builder clearDiskSizeGb() { - - diskSizeGb_ = 0L; - onChanged(); - return this; - } - - private int substitutionOption_ = 0; - /** - * - * - *
-     * Option to specify behavior when there is an error in the substitution
-     * checks.
-     * NOTE: this is always set to ALLOW_LOOSE for triggered builds and cannot
-     * be overridden in the build configuration file.
-     * 
- * - * .google.devtools.cloudbuild.v1.BuildOptions.SubstitutionOption substitution_option = 4; - * - * - * @return The enum numeric value on the wire for substitutionOption. - */ - @java.lang.Override - public int getSubstitutionOptionValue() { - return substitutionOption_; - } - /** - * - * - *
-     * Option to specify behavior when there is an error in the substitution
-     * checks.
-     * NOTE: this is always set to ALLOW_LOOSE for triggered builds and cannot
-     * be overridden in the build configuration file.
-     * 
- * - * .google.devtools.cloudbuild.v1.BuildOptions.SubstitutionOption substitution_option = 4; - * - * - * @param value The enum numeric value on the wire for substitutionOption to set. - * @return This builder for chaining. - */ - public Builder setSubstitutionOptionValue(int value) { - - substitutionOption_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Option to specify behavior when there is an error in the substitution
-     * checks.
-     * NOTE: this is always set to ALLOW_LOOSE for triggered builds and cannot
-     * be overridden in the build configuration file.
-     * 
- * - * .google.devtools.cloudbuild.v1.BuildOptions.SubstitutionOption substitution_option = 4; - * - * - * @return The substitutionOption. - */ - @java.lang.Override - public com.google.cloudbuild.v1.BuildOptions.SubstitutionOption getSubstitutionOption() { - @SuppressWarnings("deprecation") - com.google.cloudbuild.v1.BuildOptions.SubstitutionOption result = - com.google.cloudbuild.v1.BuildOptions.SubstitutionOption.valueOf(substitutionOption_); - return result == null - ? com.google.cloudbuild.v1.BuildOptions.SubstitutionOption.UNRECOGNIZED - : result; - } - /** - * - * - *
-     * Option to specify behavior when there is an error in the substitution
-     * checks.
-     * NOTE: this is always set to ALLOW_LOOSE for triggered builds and cannot
-     * be overridden in the build configuration file.
-     * 
- * - * .google.devtools.cloudbuild.v1.BuildOptions.SubstitutionOption substitution_option = 4; - * - * - * @param value The substitutionOption to set. - * @return This builder for chaining. - */ - public Builder setSubstitutionOption( - com.google.cloudbuild.v1.BuildOptions.SubstitutionOption value) { - if (value == null) { - throw new NullPointerException(); - } - - substitutionOption_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-     * Option to specify behavior when there is an error in the substitution
-     * checks.
-     * NOTE: this is always set to ALLOW_LOOSE for triggered builds and cannot
-     * be overridden in the build configuration file.
-     * 
- * - * .google.devtools.cloudbuild.v1.BuildOptions.SubstitutionOption substitution_option = 4; - * - * - * @return This builder for chaining. - */ - public Builder clearSubstitutionOption() { - - substitutionOption_ = 0; - onChanged(); - return this; - } - - private boolean dynamicSubstitutions_; - /** - * - * - *
-     * Option to specify whether or not to apply bash style string
-     * operations to the substitutions.
-     * NOTE: this is always enabled for triggered builds and cannot be
-     * overridden in the build configuration file.
-     * 
- * - * bool dynamic_substitutions = 17; - * - * @return The dynamicSubstitutions. - */ - @java.lang.Override - public boolean getDynamicSubstitutions() { - return dynamicSubstitutions_; - } - /** - * - * - *
-     * Option to specify whether or not to apply bash style string
-     * operations to the substitutions.
-     * NOTE: this is always enabled for triggered builds and cannot be
-     * overridden in the build configuration file.
-     * 
- * - * bool dynamic_substitutions = 17; - * - * @param value The dynamicSubstitutions to set. - * @return This builder for chaining. - */ - public Builder setDynamicSubstitutions(boolean value) { - - dynamicSubstitutions_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Option to specify whether or not to apply bash style string
-     * operations to the substitutions.
-     * NOTE: this is always enabled for triggered builds and cannot be
-     * overridden in the build configuration file.
-     * 
- * - * bool dynamic_substitutions = 17; - * - * @return This builder for chaining. - */ - public Builder clearDynamicSubstitutions() { - - dynamicSubstitutions_ = false; - onChanged(); - return this; - } - - private int logStreamingOption_ = 0; - /** - * - * - *
-     * Option to define build log streaming behavior to Google Cloud
-     * Storage.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.BuildOptions.LogStreamingOption log_streaming_option = 5; - * - * - * @return The enum numeric value on the wire for logStreamingOption. - */ - @java.lang.Override - public int getLogStreamingOptionValue() { - return logStreamingOption_; - } - /** - * - * - *
-     * Option to define build log streaming behavior to Google Cloud
-     * Storage.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.BuildOptions.LogStreamingOption log_streaming_option = 5; - * - * - * @param value The enum numeric value on the wire for logStreamingOption to set. - * @return This builder for chaining. - */ - public Builder setLogStreamingOptionValue(int value) { - - logStreamingOption_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Option to define build log streaming behavior to Google Cloud
-     * Storage.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.BuildOptions.LogStreamingOption log_streaming_option = 5; - * - * - * @return The logStreamingOption. - */ - @java.lang.Override - public com.google.cloudbuild.v1.BuildOptions.LogStreamingOption getLogStreamingOption() { - @SuppressWarnings("deprecation") - com.google.cloudbuild.v1.BuildOptions.LogStreamingOption result = - com.google.cloudbuild.v1.BuildOptions.LogStreamingOption.valueOf(logStreamingOption_); - return result == null - ? com.google.cloudbuild.v1.BuildOptions.LogStreamingOption.UNRECOGNIZED - : result; - } - /** - * - * - *
-     * Option to define build log streaming behavior to Google Cloud
-     * Storage.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.BuildOptions.LogStreamingOption log_streaming_option = 5; - * - * - * @param value The logStreamingOption to set. - * @return This builder for chaining. - */ - public Builder setLogStreamingOption( - com.google.cloudbuild.v1.BuildOptions.LogStreamingOption value) { - if (value == null) { - throw new NullPointerException(); - } - - logStreamingOption_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-     * Option to define build log streaming behavior to Google Cloud
-     * Storage.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.BuildOptions.LogStreamingOption log_streaming_option = 5; - * - * - * @return This builder for chaining. - */ - public Builder clearLogStreamingOption() { - - logStreamingOption_ = 0; - onChanged(); - return this; - } - - private java.lang.Object workerPool_ = ""; - /** - * - * - *
-     * This field deprecated; please use `pool.name` instead.
-     * 
- * - * string worker_pool = 7 [deprecated = true]; - * - * @deprecated google.devtools.cloudbuild.v1.BuildOptions.worker_pool is deprecated. See - * google/devtools/cloudbuild/v1/cloudbuild.proto;l=1769 - * @return The workerPool. - */ - @java.lang.Deprecated - public java.lang.String getWorkerPool() { - java.lang.Object ref = workerPool_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - workerPool_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * This field deprecated; please use `pool.name` instead.
-     * 
- * - * string worker_pool = 7 [deprecated = true]; - * - * @deprecated google.devtools.cloudbuild.v1.BuildOptions.worker_pool is deprecated. See - * google/devtools/cloudbuild/v1/cloudbuild.proto;l=1769 - * @return The bytes for workerPool. - */ - @java.lang.Deprecated - public com.google.protobuf.ByteString getWorkerPoolBytes() { - java.lang.Object ref = workerPool_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - workerPool_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * This field deprecated; please use `pool.name` instead.
-     * 
- * - * string worker_pool = 7 [deprecated = true]; - * - * @deprecated google.devtools.cloudbuild.v1.BuildOptions.worker_pool is deprecated. See - * google/devtools/cloudbuild/v1/cloudbuild.proto;l=1769 - * @param value The workerPool to set. - * @return This builder for chaining. - */ - @java.lang.Deprecated - public Builder setWorkerPool(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - workerPool_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * This field deprecated; please use `pool.name` instead.
-     * 
- * - * string worker_pool = 7 [deprecated = true]; - * - * @deprecated google.devtools.cloudbuild.v1.BuildOptions.worker_pool is deprecated. See - * google/devtools/cloudbuild/v1/cloudbuild.proto;l=1769 - * @return This builder for chaining. - */ - @java.lang.Deprecated - public Builder clearWorkerPool() { - - workerPool_ = getDefaultInstance().getWorkerPool(); - onChanged(); - return this; - } - /** - * - * - *
-     * This field deprecated; please use `pool.name` instead.
-     * 
- * - * string worker_pool = 7 [deprecated = true]; - * - * @deprecated google.devtools.cloudbuild.v1.BuildOptions.worker_pool is deprecated. See - * google/devtools/cloudbuild/v1/cloudbuild.proto;l=1769 - * @param value The bytes for workerPool to set. - * @return This builder for chaining. - */ - @java.lang.Deprecated - public Builder setWorkerPoolBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - workerPool_ = value; - onChanged(); - return this; - } - - private com.google.cloudbuild.v1.BuildOptions.PoolOption pool_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.BuildOptions.PoolOption, - com.google.cloudbuild.v1.BuildOptions.PoolOption.Builder, - com.google.cloudbuild.v1.BuildOptions.PoolOptionOrBuilder> - poolBuilder_; - /** - * - * - *
-     * Optional. Specification for execution on a `WorkerPool`.
-     * See [running builds in a private
-     * pool](https://cloud.google.com/build/docs/private-pools/run-builds-in-private-pool)
-     * for more information.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.BuildOptions.PoolOption pool = 19 [(.google.api.field_behavior) = OPTIONAL]; - * - * - * @return Whether the pool field is set. - */ - public boolean hasPool() { - return poolBuilder_ != null || pool_ != null; - } - /** - * - * - *
-     * Optional. Specification for execution on a `WorkerPool`.
-     * See [running builds in a private
-     * pool](https://cloud.google.com/build/docs/private-pools/run-builds-in-private-pool)
-     * for more information.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.BuildOptions.PoolOption pool = 19 [(.google.api.field_behavior) = OPTIONAL]; - * - * - * @return The pool. - */ - public com.google.cloudbuild.v1.BuildOptions.PoolOption getPool() { - if (poolBuilder_ == null) { - return pool_ == null - ? com.google.cloudbuild.v1.BuildOptions.PoolOption.getDefaultInstance() - : pool_; - } else { - return poolBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Optional. Specification for execution on a `WorkerPool`.
-     * See [running builds in a private
-     * pool](https://cloud.google.com/build/docs/private-pools/run-builds-in-private-pool)
-     * for more information.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.BuildOptions.PoolOption pool = 19 [(.google.api.field_behavior) = OPTIONAL]; - * - */ - public Builder setPool(com.google.cloudbuild.v1.BuildOptions.PoolOption value) { - if (poolBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - pool_ = value; - onChanged(); - } else { - poolBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * Optional. Specification for execution on a `WorkerPool`.
-     * See [running builds in a private
-     * pool](https://cloud.google.com/build/docs/private-pools/run-builds-in-private-pool)
-     * for more information.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.BuildOptions.PoolOption pool = 19 [(.google.api.field_behavior) = OPTIONAL]; - * - */ - public Builder setPool( - com.google.cloudbuild.v1.BuildOptions.PoolOption.Builder builderForValue) { - if (poolBuilder_ == null) { - pool_ = builderForValue.build(); - onChanged(); - } else { - poolBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Optional. Specification for execution on a `WorkerPool`.
-     * See [running builds in a private
-     * pool](https://cloud.google.com/build/docs/private-pools/run-builds-in-private-pool)
-     * for more information.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.BuildOptions.PoolOption pool = 19 [(.google.api.field_behavior) = OPTIONAL]; - * - */ - public Builder mergePool(com.google.cloudbuild.v1.BuildOptions.PoolOption value) { - if (poolBuilder_ == null) { - if (pool_ != null) { - pool_ = - com.google.cloudbuild.v1.BuildOptions.PoolOption.newBuilder(pool_) - .mergeFrom(value) - .buildPartial(); - } else { - pool_ = value; - } - onChanged(); - } else { - poolBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * Optional. Specification for execution on a `WorkerPool`.
-     * See [running builds in a private
-     * pool](https://cloud.google.com/build/docs/private-pools/run-builds-in-private-pool)
-     * for more information.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.BuildOptions.PoolOption pool = 19 [(.google.api.field_behavior) = OPTIONAL]; - * - */ - public Builder clearPool() { - if (poolBuilder_ == null) { - pool_ = null; - onChanged(); - } else { - pool_ = null; - poolBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Optional. Specification for execution on a `WorkerPool`.
-     * See [running builds in a private
-     * pool](https://cloud.google.com/build/docs/private-pools/run-builds-in-private-pool)
-     * for more information.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.BuildOptions.PoolOption pool = 19 [(.google.api.field_behavior) = OPTIONAL]; - * - */ - public com.google.cloudbuild.v1.BuildOptions.PoolOption.Builder getPoolBuilder() { - - onChanged(); - return getPoolFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Optional. Specification for execution on a `WorkerPool`.
-     * See [running builds in a private
-     * pool](https://cloud.google.com/build/docs/private-pools/run-builds-in-private-pool)
-     * for more information.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.BuildOptions.PoolOption pool = 19 [(.google.api.field_behavior) = OPTIONAL]; - * - */ - public com.google.cloudbuild.v1.BuildOptions.PoolOptionOrBuilder getPoolOrBuilder() { - if (poolBuilder_ != null) { - return poolBuilder_.getMessageOrBuilder(); - } else { - return pool_ == null - ? com.google.cloudbuild.v1.BuildOptions.PoolOption.getDefaultInstance() - : pool_; - } - } - /** - * - * - *
-     * Optional. Specification for execution on a `WorkerPool`.
-     * See [running builds in a private
-     * pool](https://cloud.google.com/build/docs/private-pools/run-builds-in-private-pool)
-     * for more information.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.BuildOptions.PoolOption pool = 19 [(.google.api.field_behavior) = OPTIONAL]; - * - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.BuildOptions.PoolOption, - com.google.cloudbuild.v1.BuildOptions.PoolOption.Builder, - com.google.cloudbuild.v1.BuildOptions.PoolOptionOrBuilder> - getPoolFieldBuilder() { - if (poolBuilder_ == null) { - poolBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.BuildOptions.PoolOption, - com.google.cloudbuild.v1.BuildOptions.PoolOption.Builder, - com.google.cloudbuild.v1.BuildOptions.PoolOptionOrBuilder>( - getPool(), getParentForChildren(), isClean()); - pool_ = null; - } - return poolBuilder_; - } - - private int logging_ = 0; - /** - * - * - *
-     * Option to specify the logging mode, which determines if and where build
-     * logs are stored.
-     * 
- * - * .google.devtools.cloudbuild.v1.BuildOptions.LoggingMode logging = 11; - * - * @return The enum numeric value on the wire for logging. - */ - @java.lang.Override - public int getLoggingValue() { - return logging_; - } - /** - * - * - *
-     * Option to specify the logging mode, which determines if and where build
-     * logs are stored.
-     * 
- * - * .google.devtools.cloudbuild.v1.BuildOptions.LoggingMode logging = 11; - * - * @param value The enum numeric value on the wire for logging to set. - * @return This builder for chaining. - */ - public Builder setLoggingValue(int value) { - - logging_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Option to specify the logging mode, which determines if and where build
-     * logs are stored.
-     * 
- * - * .google.devtools.cloudbuild.v1.BuildOptions.LoggingMode logging = 11; - * - * @return The logging. - */ - @java.lang.Override - public com.google.cloudbuild.v1.BuildOptions.LoggingMode getLogging() { - @SuppressWarnings("deprecation") - com.google.cloudbuild.v1.BuildOptions.LoggingMode result = - com.google.cloudbuild.v1.BuildOptions.LoggingMode.valueOf(logging_); - return result == null - ? com.google.cloudbuild.v1.BuildOptions.LoggingMode.UNRECOGNIZED - : result; - } - /** - * - * - *
-     * Option to specify the logging mode, which determines if and where build
-     * logs are stored.
-     * 
- * - * .google.devtools.cloudbuild.v1.BuildOptions.LoggingMode logging = 11; - * - * @param value The logging to set. - * @return This builder for chaining. - */ - public Builder setLogging(com.google.cloudbuild.v1.BuildOptions.LoggingMode value) { - if (value == null) { - throw new NullPointerException(); - } - - logging_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-     * Option to specify the logging mode, which determines if and where build
-     * logs are stored.
-     * 
- * - * .google.devtools.cloudbuild.v1.BuildOptions.LoggingMode logging = 11; - * - * @return This builder for chaining. - */ - public Builder clearLogging() { - - logging_ = 0; - onChanged(); - return this; - } - - private com.google.protobuf.LazyStringList env_ = com.google.protobuf.LazyStringArrayList.EMPTY; - - private void ensureEnvIsMutable() { - if (!((bitField0_ & 0x00000002) != 0)) { - env_ = new com.google.protobuf.LazyStringArrayList(env_); - bitField0_ |= 0x00000002; - } - } - /** - * - * - *
-     * A list of global environment variable definitions that will exist for all
-     * build steps in this build. If a variable is defined in both globally and in
-     * a build step, the variable will use the build step value.
-     * The elements are of the form "KEY=VALUE" for the environment variable "KEY"
-     * being given the value "VALUE".
-     * 
- * - * repeated string env = 12; - * - * @return A list containing the env. - */ - public com.google.protobuf.ProtocolStringList getEnvList() { - return env_.getUnmodifiableView(); - } - /** - * - * - *
-     * A list of global environment variable definitions that will exist for all
-     * build steps in this build. If a variable is defined in both globally and in
-     * a build step, the variable will use the build step value.
-     * The elements are of the form "KEY=VALUE" for the environment variable "KEY"
-     * being given the value "VALUE".
-     * 
- * - * repeated string env = 12; - * - * @return The count of env. - */ - public int getEnvCount() { - return env_.size(); - } - /** - * - * - *
-     * A list of global environment variable definitions that will exist for all
-     * build steps in this build. If a variable is defined in both globally and in
-     * a build step, the variable will use the build step value.
-     * The elements are of the form "KEY=VALUE" for the environment variable "KEY"
-     * being given the value "VALUE".
-     * 
- * - * repeated string env = 12; - * - * @param index The index of the element to return. - * @return The env at the given index. - */ - public java.lang.String getEnv(int index) { - return env_.get(index); - } - /** - * - * - *
-     * A list of global environment variable definitions that will exist for all
-     * build steps in this build. If a variable is defined in both globally and in
-     * a build step, the variable will use the build step value.
-     * The elements are of the form "KEY=VALUE" for the environment variable "KEY"
-     * being given the value "VALUE".
-     * 
- * - * repeated string env = 12; - * - * @param index The index of the value to return. - * @return The bytes of the env at the given index. - */ - public com.google.protobuf.ByteString getEnvBytes(int index) { - return env_.getByteString(index); - } - /** - * - * - *
-     * A list of global environment variable definitions that will exist for all
-     * build steps in this build. If a variable is defined in both globally and in
-     * a build step, the variable will use the build step value.
-     * The elements are of the form "KEY=VALUE" for the environment variable "KEY"
-     * being given the value "VALUE".
-     * 
- * - * repeated string env = 12; - * - * @param index The index to set the value at. - * @param value The env to set. - * @return This builder for chaining. - */ - public Builder setEnv(int index, java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureEnvIsMutable(); - env_.set(index, value); - onChanged(); - return this; - } - /** - * - * - *
-     * A list of global environment variable definitions that will exist for all
-     * build steps in this build. If a variable is defined in both globally and in
-     * a build step, the variable will use the build step value.
-     * The elements are of the form "KEY=VALUE" for the environment variable "KEY"
-     * being given the value "VALUE".
-     * 
- * - * repeated string env = 12; - * - * @param value The env to add. - * @return This builder for chaining. - */ - public Builder addEnv(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureEnvIsMutable(); - env_.add(value); - onChanged(); - return this; - } - /** - * - * - *
-     * A list of global environment variable definitions that will exist for all
-     * build steps in this build. If a variable is defined in both globally and in
-     * a build step, the variable will use the build step value.
-     * The elements are of the form "KEY=VALUE" for the environment variable "KEY"
-     * being given the value "VALUE".
-     * 
- * - * repeated string env = 12; - * - * @param values The env to add. - * @return This builder for chaining. - */ - public Builder addAllEnv(java.lang.Iterable values) { - ensureEnvIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, env_); - onChanged(); - return this; - } - /** - * - * - *
-     * A list of global environment variable definitions that will exist for all
-     * build steps in this build. If a variable is defined in both globally and in
-     * a build step, the variable will use the build step value.
-     * The elements are of the form "KEY=VALUE" for the environment variable "KEY"
-     * being given the value "VALUE".
-     * 
- * - * repeated string env = 12; - * - * @return This builder for chaining. - */ - public Builder clearEnv() { - env_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000002); - onChanged(); - return this; - } - /** - * - * - *
-     * A list of global environment variable definitions that will exist for all
-     * build steps in this build. If a variable is defined in both globally and in
-     * a build step, the variable will use the build step value.
-     * The elements are of the form "KEY=VALUE" for the environment variable "KEY"
-     * being given the value "VALUE".
-     * 
- * - * repeated string env = 12; - * - * @param value The bytes of the env to add. - * @return This builder for chaining. - */ - public Builder addEnvBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - ensureEnvIsMutable(); - env_.add(value); - onChanged(); - return this; - } - - private com.google.protobuf.LazyStringList secretEnv_ = - com.google.protobuf.LazyStringArrayList.EMPTY; - - private void ensureSecretEnvIsMutable() { - if (!((bitField0_ & 0x00000004) != 0)) { - secretEnv_ = new com.google.protobuf.LazyStringArrayList(secretEnv_); - bitField0_ |= 0x00000004; - } - } - /** - * - * - *
-     * A list of global environment variables, which are encrypted using a Cloud
-     * Key Management Service crypto key. These values must be specified in the
-     * build's `Secret`. These variables will be available to all build steps
-     * in this build.
-     * 
- * - * repeated string secret_env = 13; - * - * @return A list containing the secretEnv. - */ - public com.google.protobuf.ProtocolStringList getSecretEnvList() { - return secretEnv_.getUnmodifiableView(); - } - /** - * - * - *
-     * A list of global environment variables, which are encrypted using a Cloud
-     * Key Management Service crypto key. These values must be specified in the
-     * build's `Secret`. These variables will be available to all build steps
-     * in this build.
-     * 
- * - * repeated string secret_env = 13; - * - * @return The count of secretEnv. - */ - public int getSecretEnvCount() { - return secretEnv_.size(); - } - /** - * - * - *
-     * A list of global environment variables, which are encrypted using a Cloud
-     * Key Management Service crypto key. These values must be specified in the
-     * build's `Secret`. These variables will be available to all build steps
-     * in this build.
-     * 
- * - * repeated string secret_env = 13; - * - * @param index The index of the element to return. - * @return The secretEnv at the given index. - */ - public java.lang.String getSecretEnv(int index) { - return secretEnv_.get(index); - } - /** - * - * - *
-     * A list of global environment variables, which are encrypted using a Cloud
-     * Key Management Service crypto key. These values must be specified in the
-     * build's `Secret`. These variables will be available to all build steps
-     * in this build.
-     * 
- * - * repeated string secret_env = 13; - * - * @param index The index of the value to return. - * @return The bytes of the secretEnv at the given index. - */ - public com.google.protobuf.ByteString getSecretEnvBytes(int index) { - return secretEnv_.getByteString(index); - } - /** - * - * - *
-     * A list of global environment variables, which are encrypted using a Cloud
-     * Key Management Service crypto key. These values must be specified in the
-     * build's `Secret`. These variables will be available to all build steps
-     * in this build.
-     * 
- * - * repeated string secret_env = 13; - * - * @param index The index to set the value at. - * @param value The secretEnv to set. - * @return This builder for chaining. - */ - public Builder setSecretEnv(int index, java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureSecretEnvIsMutable(); - secretEnv_.set(index, value); - onChanged(); - return this; - } - /** - * - * - *
-     * A list of global environment variables, which are encrypted using a Cloud
-     * Key Management Service crypto key. These values must be specified in the
-     * build's `Secret`. These variables will be available to all build steps
-     * in this build.
-     * 
- * - * repeated string secret_env = 13; - * - * @param value The secretEnv to add. - * @return This builder for chaining. - */ - public Builder addSecretEnv(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureSecretEnvIsMutable(); - secretEnv_.add(value); - onChanged(); - return this; - } - /** - * - * - *
-     * A list of global environment variables, which are encrypted using a Cloud
-     * Key Management Service crypto key. These values must be specified in the
-     * build's `Secret`. These variables will be available to all build steps
-     * in this build.
-     * 
- * - * repeated string secret_env = 13; - * - * @param values The secretEnv to add. - * @return This builder for chaining. - */ - public Builder addAllSecretEnv(java.lang.Iterable values) { - ensureSecretEnvIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, secretEnv_); - onChanged(); - return this; - } - /** - * - * - *
-     * A list of global environment variables, which are encrypted using a Cloud
-     * Key Management Service crypto key. These values must be specified in the
-     * build's `Secret`. These variables will be available to all build steps
-     * in this build.
-     * 
- * - * repeated string secret_env = 13; - * - * @return This builder for chaining. - */ - public Builder clearSecretEnv() { - secretEnv_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000004); - onChanged(); - return this; - } - /** - * - * - *
-     * A list of global environment variables, which are encrypted using a Cloud
-     * Key Management Service crypto key. These values must be specified in the
-     * build's `Secret`. These variables will be available to all build steps
-     * in this build.
-     * 
- * - * repeated string secret_env = 13; - * - * @param value The bytes of the secretEnv to add. - * @return This builder for chaining. - */ - public Builder addSecretEnvBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - ensureSecretEnvIsMutable(); - secretEnv_.add(value); - onChanged(); - return this; - } - - private java.util.List volumes_ = - java.util.Collections.emptyList(); - - private void ensureVolumesIsMutable() { - if (!((bitField0_ & 0x00000008) != 0)) { - volumes_ = new java.util.ArrayList(volumes_); - bitField0_ |= 0x00000008; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloudbuild.v1.Volume, - com.google.cloudbuild.v1.Volume.Builder, - com.google.cloudbuild.v1.VolumeOrBuilder> - volumesBuilder_; - - /** - * - * - *
-     * Global list of volumes to mount for ALL build steps
-     * Each volume is created as an empty volume prior to starting the build
-     * process. Upon completion of the build, volumes and their contents are
-     * discarded. Global volume names and paths cannot conflict with the volumes
-     * defined a build step.
-     * Using a global volume in a build with only one step is not valid as
-     * it is indicative of a build request with an incorrect configuration.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 14; - */ - public java.util.List getVolumesList() { - if (volumesBuilder_ == null) { - return java.util.Collections.unmodifiableList(volumes_); - } else { - return volumesBuilder_.getMessageList(); - } - } - /** - * - * - *
-     * Global list of volumes to mount for ALL build steps
-     * Each volume is created as an empty volume prior to starting the build
-     * process. Upon completion of the build, volumes and their contents are
-     * discarded. Global volume names and paths cannot conflict with the volumes
-     * defined a build step.
-     * Using a global volume in a build with only one step is not valid as
-     * it is indicative of a build request with an incorrect configuration.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 14; - */ - public int getVolumesCount() { - if (volumesBuilder_ == null) { - return volumes_.size(); - } else { - return volumesBuilder_.getCount(); - } - } - /** - * - * - *
-     * Global list of volumes to mount for ALL build steps
-     * Each volume is created as an empty volume prior to starting the build
-     * process. Upon completion of the build, volumes and their contents are
-     * discarded. Global volume names and paths cannot conflict with the volumes
-     * defined a build step.
-     * Using a global volume in a build with only one step is not valid as
-     * it is indicative of a build request with an incorrect configuration.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 14; - */ - public com.google.cloudbuild.v1.Volume getVolumes(int index) { - if (volumesBuilder_ == null) { - return volumes_.get(index); - } else { - return volumesBuilder_.getMessage(index); - } - } - /** - * - * - *
-     * Global list of volumes to mount for ALL build steps
-     * Each volume is created as an empty volume prior to starting the build
-     * process. Upon completion of the build, volumes and their contents are
-     * discarded. Global volume names and paths cannot conflict with the volumes
-     * defined a build step.
-     * Using a global volume in a build with only one step is not valid as
-     * it is indicative of a build request with an incorrect configuration.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 14; - */ - public Builder setVolumes(int index, com.google.cloudbuild.v1.Volume value) { - if (volumesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureVolumesIsMutable(); - volumes_.set(index, value); - onChanged(); - } else { - volumesBuilder_.setMessage(index, value); - } - return this; - } - /** - * - * - *
-     * Global list of volumes to mount for ALL build steps
-     * Each volume is created as an empty volume prior to starting the build
-     * process. Upon completion of the build, volumes and their contents are
-     * discarded. Global volume names and paths cannot conflict with the volumes
-     * defined a build step.
-     * Using a global volume in a build with only one step is not valid as
-     * it is indicative of a build request with an incorrect configuration.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 14; - */ - public Builder setVolumes(int index, com.google.cloudbuild.v1.Volume.Builder builderForValue) { - if (volumesBuilder_ == null) { - ensureVolumesIsMutable(); - volumes_.set(index, builderForValue.build()); - onChanged(); - } else { - volumesBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * Global list of volumes to mount for ALL build steps
-     * Each volume is created as an empty volume prior to starting the build
-     * process. Upon completion of the build, volumes and their contents are
-     * discarded. Global volume names and paths cannot conflict with the volumes
-     * defined a build step.
-     * Using a global volume in a build with only one step is not valid as
-     * it is indicative of a build request with an incorrect configuration.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 14; - */ - public Builder addVolumes(com.google.cloudbuild.v1.Volume value) { - if (volumesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureVolumesIsMutable(); - volumes_.add(value); - onChanged(); - } else { - volumesBuilder_.addMessage(value); - } - return this; - } - /** - * - * - *
-     * Global list of volumes to mount for ALL build steps
-     * Each volume is created as an empty volume prior to starting the build
-     * process. Upon completion of the build, volumes and their contents are
-     * discarded. Global volume names and paths cannot conflict with the volumes
-     * defined a build step.
-     * Using a global volume in a build with only one step is not valid as
-     * it is indicative of a build request with an incorrect configuration.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 14; - */ - public Builder addVolumes(int index, com.google.cloudbuild.v1.Volume value) { - if (volumesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureVolumesIsMutable(); - volumes_.add(index, value); - onChanged(); - } else { - volumesBuilder_.addMessage(index, value); - } - return this; - } - /** - * - * - *
-     * Global list of volumes to mount for ALL build steps
-     * Each volume is created as an empty volume prior to starting the build
-     * process. Upon completion of the build, volumes and their contents are
-     * discarded. Global volume names and paths cannot conflict with the volumes
-     * defined a build step.
-     * Using a global volume in a build with only one step is not valid as
-     * it is indicative of a build request with an incorrect configuration.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 14; - */ - public Builder addVolumes(com.google.cloudbuild.v1.Volume.Builder builderForValue) { - if (volumesBuilder_ == null) { - ensureVolumesIsMutable(); - volumes_.add(builderForValue.build()); - onChanged(); - } else { - volumesBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * Global list of volumes to mount for ALL build steps
-     * Each volume is created as an empty volume prior to starting the build
-     * process. Upon completion of the build, volumes and their contents are
-     * discarded. Global volume names and paths cannot conflict with the volumes
-     * defined a build step.
-     * Using a global volume in a build with only one step is not valid as
-     * it is indicative of a build request with an incorrect configuration.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 14; - */ - public Builder addVolumes(int index, com.google.cloudbuild.v1.Volume.Builder builderForValue) { - if (volumesBuilder_ == null) { - ensureVolumesIsMutable(); - volumes_.add(index, builderForValue.build()); - onChanged(); - } else { - volumesBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * Global list of volumes to mount for ALL build steps
-     * Each volume is created as an empty volume prior to starting the build
-     * process. Upon completion of the build, volumes and their contents are
-     * discarded. Global volume names and paths cannot conflict with the volumes
-     * defined a build step.
-     * Using a global volume in a build with only one step is not valid as
-     * it is indicative of a build request with an incorrect configuration.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 14; - */ - public Builder addAllVolumes( - java.lang.Iterable values) { - if (volumesBuilder_ == null) { - ensureVolumesIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, volumes_); - onChanged(); - } else { - volumesBuilder_.addAllMessages(values); - } - return this; - } - /** - * - * - *
-     * Global list of volumes to mount for ALL build steps
-     * Each volume is created as an empty volume prior to starting the build
-     * process. Upon completion of the build, volumes and their contents are
-     * discarded. Global volume names and paths cannot conflict with the volumes
-     * defined a build step.
-     * Using a global volume in a build with only one step is not valid as
-     * it is indicative of a build request with an incorrect configuration.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 14; - */ - public Builder clearVolumes() { - if (volumesBuilder_ == null) { - volumes_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000008); - onChanged(); - } else { - volumesBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * Global list of volumes to mount for ALL build steps
-     * Each volume is created as an empty volume prior to starting the build
-     * process. Upon completion of the build, volumes and their contents are
-     * discarded. Global volume names and paths cannot conflict with the volumes
-     * defined a build step.
-     * Using a global volume in a build with only one step is not valid as
-     * it is indicative of a build request with an incorrect configuration.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 14; - */ - public Builder removeVolumes(int index) { - if (volumesBuilder_ == null) { - ensureVolumesIsMutable(); - volumes_.remove(index); - onChanged(); - } else { - volumesBuilder_.remove(index); - } - return this; - } - /** - * - * - *
-     * Global list of volumes to mount for ALL build steps
-     * Each volume is created as an empty volume prior to starting the build
-     * process. Upon completion of the build, volumes and their contents are
-     * discarded. Global volume names and paths cannot conflict with the volumes
-     * defined a build step.
-     * Using a global volume in a build with only one step is not valid as
-     * it is indicative of a build request with an incorrect configuration.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 14; - */ - public com.google.cloudbuild.v1.Volume.Builder getVolumesBuilder(int index) { - return getVolumesFieldBuilder().getBuilder(index); - } - /** - * - * - *
-     * Global list of volumes to mount for ALL build steps
-     * Each volume is created as an empty volume prior to starting the build
-     * process. Upon completion of the build, volumes and their contents are
-     * discarded. Global volume names and paths cannot conflict with the volumes
-     * defined a build step.
-     * Using a global volume in a build with only one step is not valid as
-     * it is indicative of a build request with an incorrect configuration.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 14; - */ - public com.google.cloudbuild.v1.VolumeOrBuilder getVolumesOrBuilder(int index) { - if (volumesBuilder_ == null) { - return volumes_.get(index); - } else { - return volumesBuilder_.getMessageOrBuilder(index); - } - } - /** - * - * - *
-     * Global list of volumes to mount for ALL build steps
-     * Each volume is created as an empty volume prior to starting the build
-     * process. Upon completion of the build, volumes and their contents are
-     * discarded. Global volume names and paths cannot conflict with the volumes
-     * defined a build step.
-     * Using a global volume in a build with only one step is not valid as
-     * it is indicative of a build request with an incorrect configuration.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 14; - */ - public java.util.List - getVolumesOrBuilderList() { - if (volumesBuilder_ != null) { - return volumesBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(volumes_); - } - } - /** - * - * - *
-     * Global list of volumes to mount for ALL build steps
-     * Each volume is created as an empty volume prior to starting the build
-     * process. Upon completion of the build, volumes and their contents are
-     * discarded. Global volume names and paths cannot conflict with the volumes
-     * defined a build step.
-     * Using a global volume in a build with only one step is not valid as
-     * it is indicative of a build request with an incorrect configuration.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 14; - */ - public com.google.cloudbuild.v1.Volume.Builder addVolumesBuilder() { - return getVolumesFieldBuilder() - .addBuilder(com.google.cloudbuild.v1.Volume.getDefaultInstance()); - } - /** - * - * - *
-     * Global list of volumes to mount for ALL build steps
-     * Each volume is created as an empty volume prior to starting the build
-     * process. Upon completion of the build, volumes and their contents are
-     * discarded. Global volume names and paths cannot conflict with the volumes
-     * defined a build step.
-     * Using a global volume in a build with only one step is not valid as
-     * it is indicative of a build request with an incorrect configuration.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 14; - */ - public com.google.cloudbuild.v1.Volume.Builder addVolumesBuilder(int index) { - return getVolumesFieldBuilder() - .addBuilder(index, com.google.cloudbuild.v1.Volume.getDefaultInstance()); - } - /** - * - * - *
-     * Global list of volumes to mount for ALL build steps
-     * Each volume is created as an empty volume prior to starting the build
-     * process. Upon completion of the build, volumes and their contents are
-     * discarded. Global volume names and paths cannot conflict with the volumes
-     * defined a build step.
-     * Using a global volume in a build with only one step is not valid as
-     * it is indicative of a build request with an incorrect configuration.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 14; - */ - public java.util.List getVolumesBuilderList() { - return getVolumesFieldBuilder().getBuilderList(); - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloudbuild.v1.Volume, - com.google.cloudbuild.v1.Volume.Builder, - com.google.cloudbuild.v1.VolumeOrBuilder> - getVolumesFieldBuilder() { - if (volumesBuilder_ == null) { - volumesBuilder_ = - new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloudbuild.v1.Volume, - com.google.cloudbuild.v1.Volume.Builder, - com.google.cloudbuild.v1.VolumeOrBuilder>( - volumes_, ((bitField0_ & 0x00000008) != 0), getParentForChildren(), isClean()); - volumes_ = null; - } - return volumesBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.BuildOptions) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.BuildOptions) - private static final com.google.cloudbuild.v1.BuildOptions DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.BuildOptions(); - } - - public static com.google.cloudbuild.v1.BuildOptions getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public BuildOptions parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.BuildOptions getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildOptionsOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildOptionsOrBuilder.java deleted file mode 100644 index ac3cb3c9..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildOptionsOrBuilder.java +++ /dev/null @@ -1,555 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface BuildOptionsOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.BuildOptions) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * Requested hash for SourceProvenance.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Hash.HashType source_provenance_hash = 1; - * - * @return A list containing the sourceProvenanceHash. - */ - java.util.List getSourceProvenanceHashList(); - /** - * - * - *
-   * Requested hash for SourceProvenance.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Hash.HashType source_provenance_hash = 1; - * - * @return The count of sourceProvenanceHash. - */ - int getSourceProvenanceHashCount(); - /** - * - * - *
-   * Requested hash for SourceProvenance.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Hash.HashType source_provenance_hash = 1; - * - * @param index The index of the element to return. - * @return The sourceProvenanceHash at the given index. - */ - com.google.cloudbuild.v1.Hash.HashType getSourceProvenanceHash(int index); - /** - * - * - *
-   * Requested hash for SourceProvenance.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Hash.HashType source_provenance_hash = 1; - * - * @return A list containing the enum numeric values on the wire for sourceProvenanceHash. - */ - java.util.List getSourceProvenanceHashValueList(); - /** - * - * - *
-   * Requested hash for SourceProvenance.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Hash.HashType source_provenance_hash = 1; - * - * @param index The index of the value to return. - * @return The enum numeric value on the wire of sourceProvenanceHash at the given index. - */ - int getSourceProvenanceHashValue(int index); - - /** - * - * - *
-   * Requested verifiability options.
-   * 
- * - * .google.devtools.cloudbuild.v1.BuildOptions.VerifyOption requested_verify_option = 2; - * - * - * @return The enum numeric value on the wire for requestedVerifyOption. - */ - int getRequestedVerifyOptionValue(); - /** - * - * - *
-   * Requested verifiability options.
-   * 
- * - * .google.devtools.cloudbuild.v1.BuildOptions.VerifyOption requested_verify_option = 2; - * - * - * @return The requestedVerifyOption. - */ - com.google.cloudbuild.v1.BuildOptions.VerifyOption getRequestedVerifyOption(); - - /** - * - * - *
-   * Compute Engine machine type on which to run the build.
-   * 
- * - * .google.devtools.cloudbuild.v1.BuildOptions.MachineType machine_type = 3; - * - * @return The enum numeric value on the wire for machineType. - */ - int getMachineTypeValue(); - /** - * - * - *
-   * Compute Engine machine type on which to run the build.
-   * 
- * - * .google.devtools.cloudbuild.v1.BuildOptions.MachineType machine_type = 3; - * - * @return The machineType. - */ - com.google.cloudbuild.v1.BuildOptions.MachineType getMachineType(); - - /** - * - * - *
-   * Requested disk size for the VM that runs the build. Note that this is *NOT*
-   * "disk free"; some of the space will be used by the operating system and
-   * build utilities. Also note that this is the minimum disk size that will be
-   * allocated for the build -- the build may run with a larger disk than
-   * requested. At present, the maximum disk size is 1000GB; builds that request
-   * more than the maximum are rejected with an error.
-   * 
- * - * int64 disk_size_gb = 6; - * - * @return The diskSizeGb. - */ - long getDiskSizeGb(); - - /** - * - * - *
-   * Option to specify behavior when there is an error in the substitution
-   * checks.
-   * NOTE: this is always set to ALLOW_LOOSE for triggered builds and cannot
-   * be overridden in the build configuration file.
-   * 
- * - * .google.devtools.cloudbuild.v1.BuildOptions.SubstitutionOption substitution_option = 4; - * - * - * @return The enum numeric value on the wire for substitutionOption. - */ - int getSubstitutionOptionValue(); - /** - * - * - *
-   * Option to specify behavior when there is an error in the substitution
-   * checks.
-   * NOTE: this is always set to ALLOW_LOOSE for triggered builds and cannot
-   * be overridden in the build configuration file.
-   * 
- * - * .google.devtools.cloudbuild.v1.BuildOptions.SubstitutionOption substitution_option = 4; - * - * - * @return The substitutionOption. - */ - com.google.cloudbuild.v1.BuildOptions.SubstitutionOption getSubstitutionOption(); - - /** - * - * - *
-   * Option to specify whether or not to apply bash style string
-   * operations to the substitutions.
-   * NOTE: this is always enabled for triggered builds and cannot be
-   * overridden in the build configuration file.
-   * 
- * - * bool dynamic_substitutions = 17; - * - * @return The dynamicSubstitutions. - */ - boolean getDynamicSubstitutions(); - - /** - * - * - *
-   * Option to define build log streaming behavior to Google Cloud
-   * Storage.
-   * 
- * - * .google.devtools.cloudbuild.v1.BuildOptions.LogStreamingOption log_streaming_option = 5; - * - * - * @return The enum numeric value on the wire for logStreamingOption. - */ - int getLogStreamingOptionValue(); - /** - * - * - *
-   * Option to define build log streaming behavior to Google Cloud
-   * Storage.
-   * 
- * - * .google.devtools.cloudbuild.v1.BuildOptions.LogStreamingOption log_streaming_option = 5; - * - * - * @return The logStreamingOption. - */ - com.google.cloudbuild.v1.BuildOptions.LogStreamingOption getLogStreamingOption(); - - /** - * - * - *
-   * This field deprecated; please use `pool.name` instead.
-   * 
- * - * string worker_pool = 7 [deprecated = true]; - * - * @deprecated google.devtools.cloudbuild.v1.BuildOptions.worker_pool is deprecated. See - * google/devtools/cloudbuild/v1/cloudbuild.proto;l=1769 - * @return The workerPool. - */ - @java.lang.Deprecated - java.lang.String getWorkerPool(); - /** - * - * - *
-   * This field deprecated; please use `pool.name` instead.
-   * 
- * - * string worker_pool = 7 [deprecated = true]; - * - * @deprecated google.devtools.cloudbuild.v1.BuildOptions.worker_pool is deprecated. See - * google/devtools/cloudbuild/v1/cloudbuild.proto;l=1769 - * @return The bytes for workerPool. - */ - @java.lang.Deprecated - com.google.protobuf.ByteString getWorkerPoolBytes(); - - /** - * - * - *
-   * Optional. Specification for execution on a `WorkerPool`.
-   * See [running builds in a private
-   * pool](https://cloud.google.com/build/docs/private-pools/run-builds-in-private-pool)
-   * for more information.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.BuildOptions.PoolOption pool = 19 [(.google.api.field_behavior) = OPTIONAL]; - * - * - * @return Whether the pool field is set. - */ - boolean hasPool(); - /** - * - * - *
-   * Optional. Specification for execution on a `WorkerPool`.
-   * See [running builds in a private
-   * pool](https://cloud.google.com/build/docs/private-pools/run-builds-in-private-pool)
-   * for more information.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.BuildOptions.PoolOption pool = 19 [(.google.api.field_behavior) = OPTIONAL]; - * - * - * @return The pool. - */ - com.google.cloudbuild.v1.BuildOptions.PoolOption getPool(); - /** - * - * - *
-   * Optional. Specification for execution on a `WorkerPool`.
-   * See [running builds in a private
-   * pool](https://cloud.google.com/build/docs/private-pools/run-builds-in-private-pool)
-   * for more information.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.BuildOptions.PoolOption pool = 19 [(.google.api.field_behavior) = OPTIONAL]; - * - */ - com.google.cloudbuild.v1.BuildOptions.PoolOptionOrBuilder getPoolOrBuilder(); - - /** - * - * - *
-   * Option to specify the logging mode, which determines if and where build
-   * logs are stored.
-   * 
- * - * .google.devtools.cloudbuild.v1.BuildOptions.LoggingMode logging = 11; - * - * @return The enum numeric value on the wire for logging. - */ - int getLoggingValue(); - /** - * - * - *
-   * Option to specify the logging mode, which determines if and where build
-   * logs are stored.
-   * 
- * - * .google.devtools.cloudbuild.v1.BuildOptions.LoggingMode logging = 11; - * - * @return The logging. - */ - com.google.cloudbuild.v1.BuildOptions.LoggingMode getLogging(); - - /** - * - * - *
-   * A list of global environment variable definitions that will exist for all
-   * build steps in this build. If a variable is defined in both globally and in
-   * a build step, the variable will use the build step value.
-   * The elements are of the form "KEY=VALUE" for the environment variable "KEY"
-   * being given the value "VALUE".
-   * 
- * - * repeated string env = 12; - * - * @return A list containing the env. - */ - java.util.List getEnvList(); - /** - * - * - *
-   * A list of global environment variable definitions that will exist for all
-   * build steps in this build. If a variable is defined in both globally and in
-   * a build step, the variable will use the build step value.
-   * The elements are of the form "KEY=VALUE" for the environment variable "KEY"
-   * being given the value "VALUE".
-   * 
- * - * repeated string env = 12; - * - * @return The count of env. - */ - int getEnvCount(); - /** - * - * - *
-   * A list of global environment variable definitions that will exist for all
-   * build steps in this build. If a variable is defined in both globally and in
-   * a build step, the variable will use the build step value.
-   * The elements are of the form "KEY=VALUE" for the environment variable "KEY"
-   * being given the value "VALUE".
-   * 
- * - * repeated string env = 12; - * - * @param index The index of the element to return. - * @return The env at the given index. - */ - java.lang.String getEnv(int index); - /** - * - * - *
-   * A list of global environment variable definitions that will exist for all
-   * build steps in this build. If a variable is defined in both globally and in
-   * a build step, the variable will use the build step value.
-   * The elements are of the form "KEY=VALUE" for the environment variable "KEY"
-   * being given the value "VALUE".
-   * 
- * - * repeated string env = 12; - * - * @param index The index of the value to return. - * @return The bytes of the env at the given index. - */ - com.google.protobuf.ByteString getEnvBytes(int index); - - /** - * - * - *
-   * A list of global environment variables, which are encrypted using a Cloud
-   * Key Management Service crypto key. These values must be specified in the
-   * build's `Secret`. These variables will be available to all build steps
-   * in this build.
-   * 
- * - * repeated string secret_env = 13; - * - * @return A list containing the secretEnv. - */ - java.util.List getSecretEnvList(); - /** - * - * - *
-   * A list of global environment variables, which are encrypted using a Cloud
-   * Key Management Service crypto key. These values must be specified in the
-   * build's `Secret`. These variables will be available to all build steps
-   * in this build.
-   * 
- * - * repeated string secret_env = 13; - * - * @return The count of secretEnv. - */ - int getSecretEnvCount(); - /** - * - * - *
-   * A list of global environment variables, which are encrypted using a Cloud
-   * Key Management Service crypto key. These values must be specified in the
-   * build's `Secret`. These variables will be available to all build steps
-   * in this build.
-   * 
- * - * repeated string secret_env = 13; - * - * @param index The index of the element to return. - * @return The secretEnv at the given index. - */ - java.lang.String getSecretEnv(int index); - /** - * - * - *
-   * A list of global environment variables, which are encrypted using a Cloud
-   * Key Management Service crypto key. These values must be specified in the
-   * build's `Secret`. These variables will be available to all build steps
-   * in this build.
-   * 
- * - * repeated string secret_env = 13; - * - * @param index The index of the value to return. - * @return The bytes of the secretEnv at the given index. - */ - com.google.protobuf.ByteString getSecretEnvBytes(int index); - - /** - * - * - *
-   * Global list of volumes to mount for ALL build steps
-   * Each volume is created as an empty volume prior to starting the build
-   * process. Upon completion of the build, volumes and their contents are
-   * discarded. Global volume names and paths cannot conflict with the volumes
-   * defined a build step.
-   * Using a global volume in a build with only one step is not valid as
-   * it is indicative of a build request with an incorrect configuration.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 14; - */ - java.util.List getVolumesList(); - /** - * - * - *
-   * Global list of volumes to mount for ALL build steps
-   * Each volume is created as an empty volume prior to starting the build
-   * process. Upon completion of the build, volumes and their contents are
-   * discarded. Global volume names and paths cannot conflict with the volumes
-   * defined a build step.
-   * Using a global volume in a build with only one step is not valid as
-   * it is indicative of a build request with an incorrect configuration.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 14; - */ - com.google.cloudbuild.v1.Volume getVolumes(int index); - /** - * - * - *
-   * Global list of volumes to mount for ALL build steps
-   * Each volume is created as an empty volume prior to starting the build
-   * process. Upon completion of the build, volumes and their contents are
-   * discarded. Global volume names and paths cannot conflict with the volumes
-   * defined a build step.
-   * Using a global volume in a build with only one step is not valid as
-   * it is indicative of a build request with an incorrect configuration.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 14; - */ - int getVolumesCount(); - /** - * - * - *
-   * Global list of volumes to mount for ALL build steps
-   * Each volume is created as an empty volume prior to starting the build
-   * process. Upon completion of the build, volumes and their contents are
-   * discarded. Global volume names and paths cannot conflict with the volumes
-   * defined a build step.
-   * Using a global volume in a build with only one step is not valid as
-   * it is indicative of a build request with an incorrect configuration.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 14; - */ - java.util.List getVolumesOrBuilderList(); - /** - * - * - *
-   * Global list of volumes to mount for ALL build steps
-   * Each volume is created as an empty volume prior to starting the build
-   * process. Upon completion of the build, volumes and their contents are
-   * discarded. Global volume names and paths cannot conflict with the volumes
-   * defined a build step.
-   * Using a global volume in a build with only one step is not valid as
-   * it is indicative of a build request with an incorrect configuration.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 14; - */ - com.google.cloudbuild.v1.VolumeOrBuilder getVolumesOrBuilder(int index); -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildOrBuilder.java deleted file mode 100644 index 27a81a74..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildOrBuilder.java +++ /dev/null @@ -1,1269 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface BuildOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.Build) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * Output only. The 'Build' name with format:
-   * `projects/{project}/locations/{location}/builds/{build}`, where {build}
-   * is a unique identifier generated by the service.
-   * 
- * - * string name = 45 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The name. - */ - java.lang.String getName(); - /** - * - * - *
-   * Output only. The 'Build' name with format:
-   * `projects/{project}/locations/{location}/builds/{build}`, where {build}
-   * is a unique identifier generated by the service.
-   * 
- * - * string name = 45 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The bytes for name. - */ - com.google.protobuf.ByteString getNameBytes(); - - /** - * - * - *
-   * Output only. Unique identifier of the build.
-   * 
- * - * string id = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The id. - */ - java.lang.String getId(); - /** - * - * - *
-   * Output only. Unique identifier of the build.
-   * 
- * - * string id = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The bytes for id. - */ - com.google.protobuf.ByteString getIdBytes(); - - /** - * - * - *
-   * Output only. ID of the project.
-   * 
- * - * string project_id = 16 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The projectId. - */ - java.lang.String getProjectId(); - /** - * - * - *
-   * Output only. ID of the project.
-   * 
- * - * string project_id = 16 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The bytes for projectId. - */ - com.google.protobuf.ByteString getProjectIdBytes(); - - /** - * - * - *
-   * Output only. Status of the build.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.Build.Status status = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The enum numeric value on the wire for status. - */ - int getStatusValue(); - /** - * - * - *
-   * Output only. Status of the build.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.Build.Status status = 2 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The status. - */ - com.google.cloudbuild.v1.Build.Status getStatus(); - - /** - * - * - *
-   * Output only. Customer-readable message about the current status.
-   * 
- * - * string status_detail = 24 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The statusDetail. - */ - java.lang.String getStatusDetail(); - /** - * - * - *
-   * Output only. Customer-readable message about the current status.
-   * 
- * - * string status_detail = 24 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The bytes for statusDetail. - */ - com.google.protobuf.ByteString getStatusDetailBytes(); - - /** - * - * - *
-   * The location of the source files to build.
-   * 
- * - * .google.devtools.cloudbuild.v1.Source source = 3; - * - * @return Whether the source field is set. - */ - boolean hasSource(); - /** - * - * - *
-   * The location of the source files to build.
-   * 
- * - * .google.devtools.cloudbuild.v1.Source source = 3; - * - * @return The source. - */ - com.google.cloudbuild.v1.Source getSource(); - /** - * - * - *
-   * The location of the source files to build.
-   * 
- * - * .google.devtools.cloudbuild.v1.Source source = 3; - */ - com.google.cloudbuild.v1.SourceOrBuilder getSourceOrBuilder(); - - /** - * - * - *
-   * Required. The operations to be performed on the workspace.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildStep steps = 11; - */ - java.util.List getStepsList(); - /** - * - * - *
-   * Required. The operations to be performed on the workspace.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildStep steps = 11; - */ - com.google.cloudbuild.v1.BuildStep getSteps(int index); - /** - * - * - *
-   * Required. The operations to be performed on the workspace.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildStep steps = 11; - */ - int getStepsCount(); - /** - * - * - *
-   * Required. The operations to be performed on the workspace.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildStep steps = 11; - */ - java.util.List getStepsOrBuilderList(); - /** - * - * - *
-   * Required. The operations to be performed on the workspace.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildStep steps = 11; - */ - com.google.cloudbuild.v1.BuildStepOrBuilder getStepsOrBuilder(int index); - - /** - * - * - *
-   * Output only. Results of the build.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.Results results = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return Whether the results field is set. - */ - boolean hasResults(); - /** - * - * - *
-   * Output only. Results of the build.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.Results results = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The results. - */ - com.google.cloudbuild.v1.Results getResults(); - /** - * - * - *
-   * Output only. Results of the build.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.Results results = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - com.google.cloudbuild.v1.ResultsOrBuilder getResultsOrBuilder(); - - /** - * - * - *
-   * Output only. Time at which the request to create the build was received.
-   * 
- * - * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return Whether the createTime field is set. - */ - boolean hasCreateTime(); - /** - * - * - *
-   * Output only. Time at which the request to create the build was received.
-   * 
- * - * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The createTime. - */ - com.google.protobuf.Timestamp getCreateTime(); - /** - * - * - *
-   * Output only. Time at which the request to create the build was received.
-   * 
- * - * .google.protobuf.Timestamp create_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder(); - - /** - * - * - *
-   * Output only. Time at which execution of the build was started.
-   * 
- * - * .google.protobuf.Timestamp start_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return Whether the startTime field is set. - */ - boolean hasStartTime(); - /** - * - * - *
-   * Output only. Time at which execution of the build was started.
-   * 
- * - * .google.protobuf.Timestamp start_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The startTime. - */ - com.google.protobuf.Timestamp getStartTime(); - /** - * - * - *
-   * Output only. Time at which execution of the build was started.
-   * 
- * - * .google.protobuf.Timestamp start_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - com.google.protobuf.TimestampOrBuilder getStartTimeOrBuilder(); - - /** - * - * - *
-   * Output only. Time at which execution of the build was finished.
-   * The difference between finish_time and start_time is the duration of the
-   * build's execution.
-   * 
- * - * .google.protobuf.Timestamp finish_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return Whether the finishTime field is set. - */ - boolean hasFinishTime(); - /** - * - * - *
-   * Output only. Time at which execution of the build was finished.
-   * The difference between finish_time and start_time is the duration of the
-   * build's execution.
-   * 
- * - * .google.protobuf.Timestamp finish_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The finishTime. - */ - com.google.protobuf.Timestamp getFinishTime(); - /** - * - * - *
-   * Output only. Time at which execution of the build was finished.
-   * The difference between finish_time and start_time is the duration of the
-   * build's execution.
-   * 
- * - * .google.protobuf.Timestamp finish_time = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - com.google.protobuf.TimestampOrBuilder getFinishTimeOrBuilder(); - - /** - * - * - *
-   * Amount of time that this build should be allowed to run, to second
-   * granularity. If this amount of time elapses, work on the build will cease
-   * and the build status will be `TIMEOUT`.
-   * `timeout` starts ticking from `startTime`.
-   * Default time is ten minutes.
-   * 
- * - * .google.protobuf.Duration timeout = 12; - * - * @return Whether the timeout field is set. - */ - boolean hasTimeout(); - /** - * - * - *
-   * Amount of time that this build should be allowed to run, to second
-   * granularity. If this amount of time elapses, work on the build will cease
-   * and the build status will be `TIMEOUT`.
-   * `timeout` starts ticking from `startTime`.
-   * Default time is ten minutes.
-   * 
- * - * .google.protobuf.Duration timeout = 12; - * - * @return The timeout. - */ - com.google.protobuf.Duration getTimeout(); - /** - * - * - *
-   * Amount of time that this build should be allowed to run, to second
-   * granularity. If this amount of time elapses, work on the build will cease
-   * and the build status will be `TIMEOUT`.
-   * `timeout` starts ticking from `startTime`.
-   * Default time is ten minutes.
-   * 
- * - * .google.protobuf.Duration timeout = 12; - */ - com.google.protobuf.DurationOrBuilder getTimeoutOrBuilder(); - - /** - * - * - *
-   * A list of images to be pushed upon the successful completion of all build
-   * steps.
-   * The images are pushed using the builder service account's credentials.
-   * The digests of the pushed images will be stored in the `Build` resource's
-   * results field.
-   * If any of the images fail to be pushed, the build status is marked
-   * `FAILURE`.
-   * 
- * - * repeated string images = 13; - * - * @return A list containing the images. - */ - java.util.List getImagesList(); - /** - * - * - *
-   * A list of images to be pushed upon the successful completion of all build
-   * steps.
-   * The images are pushed using the builder service account's credentials.
-   * The digests of the pushed images will be stored in the `Build` resource's
-   * results field.
-   * If any of the images fail to be pushed, the build status is marked
-   * `FAILURE`.
-   * 
- * - * repeated string images = 13; - * - * @return The count of images. - */ - int getImagesCount(); - /** - * - * - *
-   * A list of images to be pushed upon the successful completion of all build
-   * steps.
-   * The images are pushed using the builder service account's credentials.
-   * The digests of the pushed images will be stored in the `Build` resource's
-   * results field.
-   * If any of the images fail to be pushed, the build status is marked
-   * `FAILURE`.
-   * 
- * - * repeated string images = 13; - * - * @param index The index of the element to return. - * @return The images at the given index. - */ - java.lang.String getImages(int index); - /** - * - * - *
-   * A list of images to be pushed upon the successful completion of all build
-   * steps.
-   * The images are pushed using the builder service account's credentials.
-   * The digests of the pushed images will be stored in the `Build` resource's
-   * results field.
-   * If any of the images fail to be pushed, the build status is marked
-   * `FAILURE`.
-   * 
- * - * repeated string images = 13; - * - * @param index The index of the value to return. - * @return The bytes of the images at the given index. - */ - com.google.protobuf.ByteString getImagesBytes(int index); - - /** - * - * - *
-   * TTL in queue for this build. If provided and the build is enqueued longer
-   * than this value, the build will expire and the build status will be
-   * `EXPIRED`.
-   * The TTL starts ticking from create_time.
-   * 
- * - * .google.protobuf.Duration queue_ttl = 40; - * - * @return Whether the queueTtl field is set. - */ - boolean hasQueueTtl(); - /** - * - * - *
-   * TTL in queue for this build. If provided and the build is enqueued longer
-   * than this value, the build will expire and the build status will be
-   * `EXPIRED`.
-   * The TTL starts ticking from create_time.
-   * 
- * - * .google.protobuf.Duration queue_ttl = 40; - * - * @return The queueTtl. - */ - com.google.protobuf.Duration getQueueTtl(); - /** - * - * - *
-   * TTL in queue for this build. If provided and the build is enqueued longer
-   * than this value, the build will expire and the build status will be
-   * `EXPIRED`.
-   * The TTL starts ticking from create_time.
-   * 
- * - * .google.protobuf.Duration queue_ttl = 40; - */ - com.google.protobuf.DurationOrBuilder getQueueTtlOrBuilder(); - - /** - * - * - *
-   * Artifacts produced by the build that should be uploaded upon
-   * successful completion of all build steps.
-   * 
- * - * .google.devtools.cloudbuild.v1.Artifacts artifacts = 37; - * - * @return Whether the artifacts field is set. - */ - boolean hasArtifacts(); - /** - * - * - *
-   * Artifacts produced by the build that should be uploaded upon
-   * successful completion of all build steps.
-   * 
- * - * .google.devtools.cloudbuild.v1.Artifacts artifacts = 37; - * - * @return The artifacts. - */ - com.google.cloudbuild.v1.Artifacts getArtifacts(); - /** - * - * - *
-   * Artifacts produced by the build that should be uploaded upon
-   * successful completion of all build steps.
-   * 
- * - * .google.devtools.cloudbuild.v1.Artifacts artifacts = 37; - */ - com.google.cloudbuild.v1.ArtifactsOrBuilder getArtifactsOrBuilder(); - - /** - * - * - *
-   * Google Cloud Storage bucket where logs should be written (see
-   * [Bucket Name
-   * Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)).
-   * Logs file names will be of the format `${logs_bucket}/log-${build_id}.txt`.
-   * 
- * - * string logs_bucket = 19; - * - * @return The logsBucket. - */ - java.lang.String getLogsBucket(); - /** - * - * - *
-   * Google Cloud Storage bucket where logs should be written (see
-   * [Bucket Name
-   * Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)).
-   * Logs file names will be of the format `${logs_bucket}/log-${build_id}.txt`.
-   * 
- * - * string logs_bucket = 19; - * - * @return The bytes for logsBucket. - */ - com.google.protobuf.ByteString getLogsBucketBytes(); - - /** - * - * - *
-   * Output only. A permanent fixed identifier for source.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.SourceProvenance source_provenance = 21 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return Whether the sourceProvenance field is set. - */ - boolean hasSourceProvenance(); - /** - * - * - *
-   * Output only. A permanent fixed identifier for source.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.SourceProvenance source_provenance = 21 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The sourceProvenance. - */ - com.google.cloudbuild.v1.SourceProvenance getSourceProvenance(); - /** - * - * - *
-   * Output only. A permanent fixed identifier for source.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.SourceProvenance source_provenance = 21 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - com.google.cloudbuild.v1.SourceProvenanceOrBuilder getSourceProvenanceOrBuilder(); - - /** - * - * - *
-   * Output only. The ID of the `BuildTrigger` that triggered this build, if it
-   * was triggered automatically.
-   * 
- * - * string build_trigger_id = 22 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The buildTriggerId. - */ - java.lang.String getBuildTriggerId(); - /** - * - * - *
-   * Output only. The ID of the `BuildTrigger` that triggered this build, if it
-   * was triggered automatically.
-   * 
- * - * string build_trigger_id = 22 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The bytes for buildTriggerId. - */ - com.google.protobuf.ByteString getBuildTriggerIdBytes(); - - /** - * - * - *
-   * Special options for this build.
-   * 
- * - * .google.devtools.cloudbuild.v1.BuildOptions options = 23; - * - * @return Whether the options field is set. - */ - boolean hasOptions(); - /** - * - * - *
-   * Special options for this build.
-   * 
- * - * .google.devtools.cloudbuild.v1.BuildOptions options = 23; - * - * @return The options. - */ - com.google.cloudbuild.v1.BuildOptions getOptions(); - /** - * - * - *
-   * Special options for this build.
-   * 
- * - * .google.devtools.cloudbuild.v1.BuildOptions options = 23; - */ - com.google.cloudbuild.v1.BuildOptionsOrBuilder getOptionsOrBuilder(); - - /** - * - * - *
-   * Output only. URL to logs for this build in Google Cloud Console.
-   * 
- * - * string log_url = 25 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The logUrl. - */ - java.lang.String getLogUrl(); - /** - * - * - *
-   * Output only. URL to logs for this build in Google Cloud Console.
-   * 
- * - * string log_url = 25 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The bytes for logUrl. - */ - com.google.protobuf.ByteString getLogUrlBytes(); - - /** - * - * - *
-   * Substitutions data for `Build` resource.
-   * 
- * - * map<string, string> substitutions = 29; - */ - int getSubstitutionsCount(); - /** - * - * - *
-   * Substitutions data for `Build` resource.
-   * 
- * - * map<string, string> substitutions = 29; - */ - boolean containsSubstitutions(java.lang.String key); - /** Use {@link #getSubstitutionsMap()} instead. */ - @java.lang.Deprecated - java.util.Map getSubstitutions(); - /** - * - * - *
-   * Substitutions data for `Build` resource.
-   * 
- * - * map<string, string> substitutions = 29; - */ - java.util.Map getSubstitutionsMap(); - /** - * - * - *
-   * Substitutions data for `Build` resource.
-   * 
- * - * map<string, string> substitutions = 29; - */ - - /* nullable */ - java.lang.String getSubstitutionsOrDefault( - java.lang.String key, - /* nullable */ - java.lang.String defaultValue); - /** - * - * - *
-   * Substitutions data for `Build` resource.
-   * 
- * - * map<string, string> substitutions = 29; - */ - java.lang.String getSubstitutionsOrThrow(java.lang.String key); - - /** - * - * - *
-   * Tags for annotation of a `Build`. These are not docker tags.
-   * 
- * - * repeated string tags = 31; - * - * @return A list containing the tags. - */ - java.util.List getTagsList(); - /** - * - * - *
-   * Tags for annotation of a `Build`. These are not docker tags.
-   * 
- * - * repeated string tags = 31; - * - * @return The count of tags. - */ - int getTagsCount(); - /** - * - * - *
-   * Tags for annotation of a `Build`. These are not docker tags.
-   * 
- * - * repeated string tags = 31; - * - * @param index The index of the element to return. - * @return The tags at the given index. - */ - java.lang.String getTags(int index); - /** - * - * - *
-   * Tags for annotation of a `Build`. These are not docker tags.
-   * 
- * - * repeated string tags = 31; - * - * @param index The index of the value to return. - * @return The bytes of the tags at the given index. - */ - com.google.protobuf.ByteString getTagsBytes(int index); - - /** - * - * - *
-   * Secrets to decrypt using Cloud Key Management Service.
-   * Note: Secret Manager is the recommended technique
-   * for managing sensitive data with Cloud Build. Use `available_secrets` to
-   * configure builds to access secrets from Secret Manager. For instructions,
-   * see: https://cloud.google.com/cloud-build/docs/securing-builds/use-secrets
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Secret secrets = 32; - */ - java.util.List getSecretsList(); - /** - * - * - *
-   * Secrets to decrypt using Cloud Key Management Service.
-   * Note: Secret Manager is the recommended technique
-   * for managing sensitive data with Cloud Build. Use `available_secrets` to
-   * configure builds to access secrets from Secret Manager. For instructions,
-   * see: https://cloud.google.com/cloud-build/docs/securing-builds/use-secrets
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Secret secrets = 32; - */ - com.google.cloudbuild.v1.Secret getSecrets(int index); - /** - * - * - *
-   * Secrets to decrypt using Cloud Key Management Service.
-   * Note: Secret Manager is the recommended technique
-   * for managing sensitive data with Cloud Build. Use `available_secrets` to
-   * configure builds to access secrets from Secret Manager. For instructions,
-   * see: https://cloud.google.com/cloud-build/docs/securing-builds/use-secrets
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Secret secrets = 32; - */ - int getSecretsCount(); - /** - * - * - *
-   * Secrets to decrypt using Cloud Key Management Service.
-   * Note: Secret Manager is the recommended technique
-   * for managing sensitive data with Cloud Build. Use `available_secrets` to
-   * configure builds to access secrets from Secret Manager. For instructions,
-   * see: https://cloud.google.com/cloud-build/docs/securing-builds/use-secrets
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Secret secrets = 32; - */ - java.util.List getSecretsOrBuilderList(); - /** - * - * - *
-   * Secrets to decrypt using Cloud Key Management Service.
-   * Note: Secret Manager is the recommended technique
-   * for managing sensitive data with Cloud Build. Use `available_secrets` to
-   * configure builds to access secrets from Secret Manager. For instructions,
-   * see: https://cloud.google.com/cloud-build/docs/securing-builds/use-secrets
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Secret secrets = 32; - */ - com.google.cloudbuild.v1.SecretOrBuilder getSecretsOrBuilder(int index); - - /** - * - * - *
-   * Output only. Stores timing information for phases of the build. Valid keys
-   * are:
-   * * BUILD: time to execute all build steps.
-   * * PUSH: time to push all specified images.
-   * * FETCHSOURCE: time to fetch source.
-   * * SETUPBUILD: time to set up build.
-   * If the build does not specify source or images,
-   * these keys will not be included.
-   * 
- * - * - * map<string, .google.devtools.cloudbuild.v1.TimeSpan> timing = 33 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - int getTimingCount(); - /** - * - * - *
-   * Output only. Stores timing information for phases of the build. Valid keys
-   * are:
-   * * BUILD: time to execute all build steps.
-   * * PUSH: time to push all specified images.
-   * * FETCHSOURCE: time to fetch source.
-   * * SETUPBUILD: time to set up build.
-   * If the build does not specify source or images,
-   * these keys will not be included.
-   * 
- * - * - * map<string, .google.devtools.cloudbuild.v1.TimeSpan> timing = 33 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - boolean containsTiming(java.lang.String key); - /** Use {@link #getTimingMap()} instead. */ - @java.lang.Deprecated - java.util.Map getTiming(); - /** - * - * - *
-   * Output only. Stores timing information for phases of the build. Valid keys
-   * are:
-   * * BUILD: time to execute all build steps.
-   * * PUSH: time to push all specified images.
-   * * FETCHSOURCE: time to fetch source.
-   * * SETUPBUILD: time to set up build.
-   * If the build does not specify source or images,
-   * these keys will not be included.
-   * 
- * - * - * map<string, .google.devtools.cloudbuild.v1.TimeSpan> timing = 33 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - java.util.Map getTimingMap(); - /** - * - * - *
-   * Output only. Stores timing information for phases of the build. Valid keys
-   * are:
-   * * BUILD: time to execute all build steps.
-   * * PUSH: time to push all specified images.
-   * * FETCHSOURCE: time to fetch source.
-   * * SETUPBUILD: time to set up build.
-   * If the build does not specify source or images,
-   * these keys will not be included.
-   * 
- * - * - * map<string, .google.devtools.cloudbuild.v1.TimeSpan> timing = 33 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - - /* nullable */ - com.google.cloudbuild.v1.TimeSpan getTimingOrDefault( - java.lang.String key, - /* nullable */ - com.google.cloudbuild.v1.TimeSpan defaultValue); - /** - * - * - *
-   * Output only. Stores timing information for phases of the build. Valid keys
-   * are:
-   * * BUILD: time to execute all build steps.
-   * * PUSH: time to push all specified images.
-   * * FETCHSOURCE: time to fetch source.
-   * * SETUPBUILD: time to set up build.
-   * If the build does not specify source or images,
-   * these keys will not be included.
-   * 
- * - * - * map<string, .google.devtools.cloudbuild.v1.TimeSpan> timing = 33 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - com.google.cloudbuild.v1.TimeSpan getTimingOrThrow(java.lang.String key); - - /** - * - * - *
-   * Output only. Describes this build's approval configuration, status,
-   * and result.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.BuildApproval approval = 44 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return Whether the approval field is set. - */ - boolean hasApproval(); - /** - * - * - *
-   * Output only. Describes this build's approval configuration, status,
-   * and result.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.BuildApproval approval = 44 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The approval. - */ - com.google.cloudbuild.v1.BuildApproval getApproval(); - /** - * - * - *
-   * Output only. Describes this build's approval configuration, status,
-   * and result.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.BuildApproval approval = 44 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - com.google.cloudbuild.v1.BuildApprovalOrBuilder getApprovalOrBuilder(); - - /** - * - * - *
-   * IAM service account whose credentials will be used at build runtime.
-   * Must be of the format `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`.
-   * ACCOUNT can be email address or uniqueId of the service account.
-   * 
- * - * string service_account = 42 [(.google.api.resource_reference) = { ... } - * - * @return The serviceAccount. - */ - java.lang.String getServiceAccount(); - /** - * - * - *
-   * IAM service account whose credentials will be used at build runtime.
-   * Must be of the format `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`.
-   * ACCOUNT can be email address or uniqueId of the service account.
-   * 
- * - * string service_account = 42 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for serviceAccount. - */ - com.google.protobuf.ByteString getServiceAccountBytes(); - - /** - * - * - *
-   * Secrets and secret environment variables.
-   * 
- * - * .google.devtools.cloudbuild.v1.Secrets available_secrets = 47; - * - * @return Whether the availableSecrets field is set. - */ - boolean hasAvailableSecrets(); - /** - * - * - *
-   * Secrets and secret environment variables.
-   * 
- * - * .google.devtools.cloudbuild.v1.Secrets available_secrets = 47; - * - * @return The availableSecrets. - */ - com.google.cloudbuild.v1.Secrets getAvailableSecrets(); - /** - * - * - *
-   * Secrets and secret environment variables.
-   * 
- * - * .google.devtools.cloudbuild.v1.Secrets available_secrets = 47; - */ - com.google.cloudbuild.v1.SecretsOrBuilder getAvailableSecretsOrBuilder(); - - /** - * - * - *
-   * Output only. Non-fatal problems encountered during the execution of the
-   * build.
-   * 
- * - * - * repeated .google.devtools.cloudbuild.v1.Build.Warning warnings = 49 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - java.util.List getWarningsList(); - /** - * - * - *
-   * Output only. Non-fatal problems encountered during the execution of the
-   * build.
-   * 
- * - * - * repeated .google.devtools.cloudbuild.v1.Build.Warning warnings = 49 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - com.google.cloudbuild.v1.Build.Warning getWarnings(int index); - /** - * - * - *
-   * Output only. Non-fatal problems encountered during the execution of the
-   * build.
-   * 
- * - * - * repeated .google.devtools.cloudbuild.v1.Build.Warning warnings = 49 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - int getWarningsCount(); - /** - * - * - *
-   * Output only. Non-fatal problems encountered during the execution of the
-   * build.
-   * 
- * - * - * repeated .google.devtools.cloudbuild.v1.Build.Warning warnings = 49 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - java.util.List - getWarningsOrBuilderList(); - /** - * - * - *
-   * Output only. Non-fatal problems encountered during the execution of the
-   * build.
-   * 
- * - * - * repeated .google.devtools.cloudbuild.v1.Build.Warning warnings = 49 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - com.google.cloudbuild.v1.Build.WarningOrBuilder getWarningsOrBuilder(int index); - - /** - * - * - *
-   * Output only. Contains information about the build when status=FAILURE.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.Build.FailureInfo failure_info = 51 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return Whether the failureInfo field is set. - */ - boolean hasFailureInfo(); - /** - * - * - *
-   * Output only. Contains information about the build when status=FAILURE.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.Build.FailureInfo failure_info = 51 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The failureInfo. - */ - com.google.cloudbuild.v1.Build.FailureInfo getFailureInfo(); - /** - * - * - *
-   * Output only. Contains information about the build when status=FAILURE.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.Build.FailureInfo failure_info = 51 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - com.google.cloudbuild.v1.Build.FailureInfoOrBuilder getFailureInfoOrBuilder(); -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildStep.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildStep.java deleted file mode 100644 index caaaa505..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildStep.java +++ /dev/null @@ -1,4365 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * A step in the build pipeline.
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.BuildStep} - */ -public final class BuildStep extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.BuildStep) - BuildStepOrBuilder { - private static final long serialVersionUID = 0L; - // Use BuildStep.newBuilder() to construct. - private BuildStep(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private BuildStep() { - name_ = ""; - env_ = com.google.protobuf.LazyStringArrayList.EMPTY; - args_ = com.google.protobuf.LazyStringArrayList.EMPTY; - dir_ = ""; - id_ = ""; - waitFor_ = com.google.protobuf.LazyStringArrayList.EMPTY; - entrypoint_ = ""; - secretEnv_ = com.google.protobuf.LazyStringArrayList.EMPTY; - volumes_ = java.util.Collections.emptyList(); - status_ = 0; - script_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new BuildStep(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_BuildStep_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_BuildStep_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.BuildStep.class, - com.google.cloudbuild.v1.BuildStep.Builder.class); - } - - public static final int NAME_FIELD_NUMBER = 1; - private volatile java.lang.Object name_; - /** - * - * - *
-   * Required. The name of the container image that will run this particular
-   * build step.
-   * If the image is available in the host's Docker daemon's cache, it
-   * will be run directly. If not, the host will attempt to pull the image
-   * first, using the builder service account's credentials if necessary.
-   * The Docker daemon's cache will already have the latest versions of all of
-   * the officially supported build steps
-   * ([https://github.com/GoogleCloudPlatform/cloud-builders](https://github.com/GoogleCloudPlatform/cloud-builders)).
-   * The Docker daemon will also have cached many of the layers for some popular
-   * images, like "ubuntu", "debian", but they will be refreshed at the time you
-   * attempt to use them.
-   * If you built an image in a previous build step, it will be stored in the
-   * host's Docker daemon's cache and is available to use as the name for a
-   * later build step.
-   * 
- * - * string name = 1; - * - * @return The name. - */ - @java.lang.Override - public java.lang.String getName() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - name_ = s; - return s; - } - } - /** - * - * - *
-   * Required. The name of the container image that will run this particular
-   * build step.
-   * If the image is available in the host's Docker daemon's cache, it
-   * will be run directly. If not, the host will attempt to pull the image
-   * first, using the builder service account's credentials if necessary.
-   * The Docker daemon's cache will already have the latest versions of all of
-   * the officially supported build steps
-   * ([https://github.com/GoogleCloudPlatform/cloud-builders](https://github.com/GoogleCloudPlatform/cloud-builders)).
-   * The Docker daemon will also have cached many of the layers for some popular
-   * images, like "ubuntu", "debian", but they will be refreshed at the time you
-   * attempt to use them.
-   * If you built an image in a previous build step, it will be stored in the
-   * host's Docker daemon's cache and is available to use as the name for a
-   * later build step.
-   * 
- * - * string name = 1; - * - * @return The bytes for name. - */ - @java.lang.Override - public com.google.protobuf.ByteString getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int ENV_FIELD_NUMBER = 2; - private com.google.protobuf.LazyStringList env_; - /** - * - * - *
-   * A list of environment variable definitions to be used when running a step.
-   * The elements are of the form "KEY=VALUE" for the environment variable "KEY"
-   * being given the value "VALUE".
-   * 
- * - * repeated string env = 2; - * - * @return A list containing the env. - */ - public com.google.protobuf.ProtocolStringList getEnvList() { - return env_; - } - /** - * - * - *
-   * A list of environment variable definitions to be used when running a step.
-   * The elements are of the form "KEY=VALUE" for the environment variable "KEY"
-   * being given the value "VALUE".
-   * 
- * - * repeated string env = 2; - * - * @return The count of env. - */ - public int getEnvCount() { - return env_.size(); - } - /** - * - * - *
-   * A list of environment variable definitions to be used when running a step.
-   * The elements are of the form "KEY=VALUE" for the environment variable "KEY"
-   * being given the value "VALUE".
-   * 
- * - * repeated string env = 2; - * - * @param index The index of the element to return. - * @return The env at the given index. - */ - public java.lang.String getEnv(int index) { - return env_.get(index); - } - /** - * - * - *
-   * A list of environment variable definitions to be used when running a step.
-   * The elements are of the form "KEY=VALUE" for the environment variable "KEY"
-   * being given the value "VALUE".
-   * 
- * - * repeated string env = 2; - * - * @param index The index of the value to return. - * @return The bytes of the env at the given index. - */ - public com.google.protobuf.ByteString getEnvBytes(int index) { - return env_.getByteString(index); - } - - public static final int ARGS_FIELD_NUMBER = 3; - private com.google.protobuf.LazyStringList args_; - /** - * - * - *
-   * A list of arguments that will be presented to the step when it is started.
-   * If the image used to run the step's container has an entrypoint, the `args`
-   * are used as arguments to that entrypoint. If the image does not define
-   * an entrypoint, the first element in args is used as the entrypoint,
-   * and the remainder will be used as arguments.
-   * 
- * - * repeated string args = 3; - * - * @return A list containing the args. - */ - public com.google.protobuf.ProtocolStringList getArgsList() { - return args_; - } - /** - * - * - *
-   * A list of arguments that will be presented to the step when it is started.
-   * If the image used to run the step's container has an entrypoint, the `args`
-   * are used as arguments to that entrypoint. If the image does not define
-   * an entrypoint, the first element in args is used as the entrypoint,
-   * and the remainder will be used as arguments.
-   * 
- * - * repeated string args = 3; - * - * @return The count of args. - */ - public int getArgsCount() { - return args_.size(); - } - /** - * - * - *
-   * A list of arguments that will be presented to the step when it is started.
-   * If the image used to run the step's container has an entrypoint, the `args`
-   * are used as arguments to that entrypoint. If the image does not define
-   * an entrypoint, the first element in args is used as the entrypoint,
-   * and the remainder will be used as arguments.
-   * 
- * - * repeated string args = 3; - * - * @param index The index of the element to return. - * @return The args at the given index. - */ - public java.lang.String getArgs(int index) { - return args_.get(index); - } - /** - * - * - *
-   * A list of arguments that will be presented to the step when it is started.
-   * If the image used to run the step's container has an entrypoint, the `args`
-   * are used as arguments to that entrypoint. If the image does not define
-   * an entrypoint, the first element in args is used as the entrypoint,
-   * and the remainder will be used as arguments.
-   * 
- * - * repeated string args = 3; - * - * @param index The index of the value to return. - * @return The bytes of the args at the given index. - */ - public com.google.protobuf.ByteString getArgsBytes(int index) { - return args_.getByteString(index); - } - - public static final int DIR_FIELD_NUMBER = 4; - private volatile java.lang.Object dir_; - /** - * - * - *
-   * Working directory to use when running this step's container.
-   * If this value is a relative path, it is relative to the build's working
-   * directory. If this value is absolute, it may be outside the build's working
-   * directory, in which case the contents of the path may not be persisted
-   * across build step executions, unless a `volume` for that path is specified.
-   * If the build specifies a `RepoSource` with `dir` and a step with a `dir`,
-   * which specifies an absolute path, the `RepoSource` `dir` is ignored for
-   * the step's execution.
-   * 
- * - * string dir = 4; - * - * @return The dir. - */ - @java.lang.Override - public java.lang.String getDir() { - java.lang.Object ref = dir_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - dir_ = s; - return s; - } - } - /** - * - * - *
-   * Working directory to use when running this step's container.
-   * If this value is a relative path, it is relative to the build's working
-   * directory. If this value is absolute, it may be outside the build's working
-   * directory, in which case the contents of the path may not be persisted
-   * across build step executions, unless a `volume` for that path is specified.
-   * If the build specifies a `RepoSource` with `dir` and a step with a `dir`,
-   * which specifies an absolute path, the `RepoSource` `dir` is ignored for
-   * the step's execution.
-   * 
- * - * string dir = 4; - * - * @return The bytes for dir. - */ - @java.lang.Override - public com.google.protobuf.ByteString getDirBytes() { - java.lang.Object ref = dir_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - dir_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int ID_FIELD_NUMBER = 5; - private volatile java.lang.Object id_; - /** - * - * - *
-   * Unique identifier for this build step, used in `wait_for` to
-   * reference this build step as a dependency.
-   * 
- * - * string id = 5; - * - * @return The id. - */ - @java.lang.Override - public java.lang.String getId() { - java.lang.Object ref = id_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - id_ = s; - return s; - } - } - /** - * - * - *
-   * Unique identifier for this build step, used in `wait_for` to
-   * reference this build step as a dependency.
-   * 
- * - * string id = 5; - * - * @return The bytes for id. - */ - @java.lang.Override - public com.google.protobuf.ByteString getIdBytes() { - java.lang.Object ref = id_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - id_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int WAIT_FOR_FIELD_NUMBER = 6; - private com.google.protobuf.LazyStringList waitFor_; - /** - * - * - *
-   * The ID(s) of the step(s) that this build step depends on.
-   * This build step will not start until all the build steps in `wait_for`
-   * have completed successfully. If `wait_for` is empty, this build step will
-   * start when all previous build steps in the `Build.Steps` list have
-   * completed successfully.
-   * 
- * - * repeated string wait_for = 6; - * - * @return A list containing the waitFor. - */ - public com.google.protobuf.ProtocolStringList getWaitForList() { - return waitFor_; - } - /** - * - * - *
-   * The ID(s) of the step(s) that this build step depends on.
-   * This build step will not start until all the build steps in `wait_for`
-   * have completed successfully. If `wait_for` is empty, this build step will
-   * start when all previous build steps in the `Build.Steps` list have
-   * completed successfully.
-   * 
- * - * repeated string wait_for = 6; - * - * @return The count of waitFor. - */ - public int getWaitForCount() { - return waitFor_.size(); - } - /** - * - * - *
-   * The ID(s) of the step(s) that this build step depends on.
-   * This build step will not start until all the build steps in `wait_for`
-   * have completed successfully. If `wait_for` is empty, this build step will
-   * start when all previous build steps in the `Build.Steps` list have
-   * completed successfully.
-   * 
- * - * repeated string wait_for = 6; - * - * @param index The index of the element to return. - * @return The waitFor at the given index. - */ - public java.lang.String getWaitFor(int index) { - return waitFor_.get(index); - } - /** - * - * - *
-   * The ID(s) of the step(s) that this build step depends on.
-   * This build step will not start until all the build steps in `wait_for`
-   * have completed successfully. If `wait_for` is empty, this build step will
-   * start when all previous build steps in the `Build.Steps` list have
-   * completed successfully.
-   * 
- * - * repeated string wait_for = 6; - * - * @param index The index of the value to return. - * @return The bytes of the waitFor at the given index. - */ - public com.google.protobuf.ByteString getWaitForBytes(int index) { - return waitFor_.getByteString(index); - } - - public static final int ENTRYPOINT_FIELD_NUMBER = 7; - private volatile java.lang.Object entrypoint_; - /** - * - * - *
-   * Entrypoint to be used instead of the build step image's default entrypoint.
-   * If unset, the image's default entrypoint is used.
-   * 
- * - * string entrypoint = 7; - * - * @return The entrypoint. - */ - @java.lang.Override - public java.lang.String getEntrypoint() { - java.lang.Object ref = entrypoint_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - entrypoint_ = s; - return s; - } - } - /** - * - * - *
-   * Entrypoint to be used instead of the build step image's default entrypoint.
-   * If unset, the image's default entrypoint is used.
-   * 
- * - * string entrypoint = 7; - * - * @return The bytes for entrypoint. - */ - @java.lang.Override - public com.google.protobuf.ByteString getEntrypointBytes() { - java.lang.Object ref = entrypoint_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - entrypoint_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int SECRET_ENV_FIELD_NUMBER = 8; - private com.google.protobuf.LazyStringList secretEnv_; - /** - * - * - *
-   * A list of environment variables which are encrypted using a Cloud Key
-   * Management Service crypto key. These values must be specified in the
-   * build's `Secret`.
-   * 
- * - * repeated string secret_env = 8; - * - * @return A list containing the secretEnv. - */ - public com.google.protobuf.ProtocolStringList getSecretEnvList() { - return secretEnv_; - } - /** - * - * - *
-   * A list of environment variables which are encrypted using a Cloud Key
-   * Management Service crypto key. These values must be specified in the
-   * build's `Secret`.
-   * 
- * - * repeated string secret_env = 8; - * - * @return The count of secretEnv. - */ - public int getSecretEnvCount() { - return secretEnv_.size(); - } - /** - * - * - *
-   * A list of environment variables which are encrypted using a Cloud Key
-   * Management Service crypto key. These values must be specified in the
-   * build's `Secret`.
-   * 
- * - * repeated string secret_env = 8; - * - * @param index The index of the element to return. - * @return The secretEnv at the given index. - */ - public java.lang.String getSecretEnv(int index) { - return secretEnv_.get(index); - } - /** - * - * - *
-   * A list of environment variables which are encrypted using a Cloud Key
-   * Management Service crypto key. These values must be specified in the
-   * build's `Secret`.
-   * 
- * - * repeated string secret_env = 8; - * - * @param index The index of the value to return. - * @return The bytes of the secretEnv at the given index. - */ - public com.google.protobuf.ByteString getSecretEnvBytes(int index) { - return secretEnv_.getByteString(index); - } - - public static final int VOLUMES_FIELD_NUMBER = 9; - private java.util.List volumes_; - /** - * - * - *
-   * List of volumes to mount into the build step.
-   * Each volume is created as an empty volume prior to execution of the
-   * build step. Upon completion of the build, volumes and their contents are
-   * discarded.
-   * Using a named volume in only one step is not valid as it is indicative
-   * of a build request with an incorrect configuration.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 9; - */ - @java.lang.Override - public java.util.List getVolumesList() { - return volumes_; - } - /** - * - * - *
-   * List of volumes to mount into the build step.
-   * Each volume is created as an empty volume prior to execution of the
-   * build step. Upon completion of the build, volumes and their contents are
-   * discarded.
-   * Using a named volume in only one step is not valid as it is indicative
-   * of a build request with an incorrect configuration.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 9; - */ - @java.lang.Override - public java.util.List - getVolumesOrBuilderList() { - return volumes_; - } - /** - * - * - *
-   * List of volumes to mount into the build step.
-   * Each volume is created as an empty volume prior to execution of the
-   * build step. Upon completion of the build, volumes and their contents are
-   * discarded.
-   * Using a named volume in only one step is not valid as it is indicative
-   * of a build request with an incorrect configuration.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 9; - */ - @java.lang.Override - public int getVolumesCount() { - return volumes_.size(); - } - /** - * - * - *
-   * List of volumes to mount into the build step.
-   * Each volume is created as an empty volume prior to execution of the
-   * build step. Upon completion of the build, volumes and their contents are
-   * discarded.
-   * Using a named volume in only one step is not valid as it is indicative
-   * of a build request with an incorrect configuration.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 9; - */ - @java.lang.Override - public com.google.cloudbuild.v1.Volume getVolumes(int index) { - return volumes_.get(index); - } - /** - * - * - *
-   * List of volumes to mount into the build step.
-   * Each volume is created as an empty volume prior to execution of the
-   * build step. Upon completion of the build, volumes and their contents are
-   * discarded.
-   * Using a named volume in only one step is not valid as it is indicative
-   * of a build request with an incorrect configuration.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 9; - */ - @java.lang.Override - public com.google.cloudbuild.v1.VolumeOrBuilder getVolumesOrBuilder(int index) { - return volumes_.get(index); - } - - public static final int TIMING_FIELD_NUMBER = 10; - private com.google.cloudbuild.v1.TimeSpan timing_; - /** - * - * - *
-   * Output only. Stores timing information for executing this build step.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan timing = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return Whether the timing field is set. - */ - @java.lang.Override - public boolean hasTiming() { - return timing_ != null; - } - /** - * - * - *
-   * Output only. Stores timing information for executing this build step.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan timing = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The timing. - */ - @java.lang.Override - public com.google.cloudbuild.v1.TimeSpan getTiming() { - return timing_ == null ? com.google.cloudbuild.v1.TimeSpan.getDefaultInstance() : timing_; - } - /** - * - * - *
-   * Output only. Stores timing information for executing this build step.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan timing = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - @java.lang.Override - public com.google.cloudbuild.v1.TimeSpanOrBuilder getTimingOrBuilder() { - return getTiming(); - } - - public static final int PULL_TIMING_FIELD_NUMBER = 13; - private com.google.cloudbuild.v1.TimeSpan pullTiming_; - /** - * - * - *
-   * Output only. Stores timing information for pulling this build step's
-   * builder image only.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan pull_timing = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return Whether the pullTiming field is set. - */ - @java.lang.Override - public boolean hasPullTiming() { - return pullTiming_ != null; - } - /** - * - * - *
-   * Output only. Stores timing information for pulling this build step's
-   * builder image only.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan pull_timing = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The pullTiming. - */ - @java.lang.Override - public com.google.cloudbuild.v1.TimeSpan getPullTiming() { - return pullTiming_ == null - ? com.google.cloudbuild.v1.TimeSpan.getDefaultInstance() - : pullTiming_; - } - /** - * - * - *
-   * Output only. Stores timing information for pulling this build step's
-   * builder image only.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan pull_timing = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - @java.lang.Override - public com.google.cloudbuild.v1.TimeSpanOrBuilder getPullTimingOrBuilder() { - return getPullTiming(); - } - - public static final int TIMEOUT_FIELD_NUMBER = 11; - private com.google.protobuf.Duration timeout_; - /** - * - * - *
-   * Time limit for executing this build step. If not defined, the step has no
-   * time limit and will be allowed to continue to run until either it completes
-   * or the build itself times out.
-   * 
- * - * .google.protobuf.Duration timeout = 11; - * - * @return Whether the timeout field is set. - */ - @java.lang.Override - public boolean hasTimeout() { - return timeout_ != null; - } - /** - * - * - *
-   * Time limit for executing this build step. If not defined, the step has no
-   * time limit and will be allowed to continue to run until either it completes
-   * or the build itself times out.
-   * 
- * - * .google.protobuf.Duration timeout = 11; - * - * @return The timeout. - */ - @java.lang.Override - public com.google.protobuf.Duration getTimeout() { - return timeout_ == null ? com.google.protobuf.Duration.getDefaultInstance() : timeout_; - } - /** - * - * - *
-   * Time limit for executing this build step. If not defined, the step has no
-   * time limit and will be allowed to continue to run until either it completes
-   * or the build itself times out.
-   * 
- * - * .google.protobuf.Duration timeout = 11; - */ - @java.lang.Override - public com.google.protobuf.DurationOrBuilder getTimeoutOrBuilder() { - return getTimeout(); - } - - public static final int STATUS_FIELD_NUMBER = 12; - private int status_; - /** - * - * - *
-   * Output only. Status of the build step. At this time, build step status is
-   * only updated on build completion; step status is not updated in real-time
-   * as the build progresses.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.Build.Status status = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The enum numeric value on the wire for status. - */ - @java.lang.Override - public int getStatusValue() { - return status_; - } - /** - * - * - *
-   * Output only. Status of the build step. At this time, build step status is
-   * only updated on build completion; step status is not updated in real-time
-   * as the build progresses.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.Build.Status status = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The status. - */ - @java.lang.Override - public com.google.cloudbuild.v1.Build.Status getStatus() { - @SuppressWarnings("deprecation") - com.google.cloudbuild.v1.Build.Status result = - com.google.cloudbuild.v1.Build.Status.valueOf(status_); - return result == null ? com.google.cloudbuild.v1.Build.Status.UNRECOGNIZED : result; - } - - public static final int SCRIPT_FIELD_NUMBER = 19; - private volatile java.lang.Object script_; - /** - * - * - *
-   * A shell script to be executed in the step.
-   * When script is provided, the user cannot specify the entrypoint or args.
-   * 
- * - * string script = 19; - * - * @return The script. - */ - @java.lang.Override - public java.lang.String getScript() { - java.lang.Object ref = script_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - script_ = s; - return s; - } - } - /** - * - * - *
-   * A shell script to be executed in the step.
-   * When script is provided, the user cannot specify the entrypoint or args.
-   * 
- * - * string script = 19; - * - * @return The bytes for script. - */ - @java.lang.Override - public com.google.protobuf.ByteString getScriptBytes() { - java.lang.Object ref = script_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - script_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); - } - for (int i = 0; i < env_.size(); i++) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, env_.getRaw(i)); - } - for (int i = 0; i < args_.size(); i++) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 3, args_.getRaw(i)); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(dir_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 4, dir_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(id_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 5, id_); - } - for (int i = 0; i < waitFor_.size(); i++) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 6, waitFor_.getRaw(i)); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(entrypoint_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 7, entrypoint_); - } - for (int i = 0; i < secretEnv_.size(); i++) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 8, secretEnv_.getRaw(i)); - } - for (int i = 0; i < volumes_.size(); i++) { - output.writeMessage(9, volumes_.get(i)); - } - if (timing_ != null) { - output.writeMessage(10, getTiming()); - } - if (timeout_ != null) { - output.writeMessage(11, getTimeout()); - } - if (status_ != com.google.cloudbuild.v1.Build.Status.STATUS_UNKNOWN.getNumber()) { - output.writeEnum(12, status_); - } - if (pullTiming_ != null) { - output.writeMessage(13, getPullTiming()); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(script_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 19, script_); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); - } - { - int dataSize = 0; - for (int i = 0; i < env_.size(); i++) { - dataSize += computeStringSizeNoTag(env_.getRaw(i)); - } - size += dataSize; - size += 1 * getEnvList().size(); - } - { - int dataSize = 0; - for (int i = 0; i < args_.size(); i++) { - dataSize += computeStringSizeNoTag(args_.getRaw(i)); - } - size += dataSize; - size += 1 * getArgsList().size(); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(dir_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, dir_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(id_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(5, id_); - } - { - int dataSize = 0; - for (int i = 0; i < waitFor_.size(); i++) { - dataSize += computeStringSizeNoTag(waitFor_.getRaw(i)); - } - size += dataSize; - size += 1 * getWaitForList().size(); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(entrypoint_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(7, entrypoint_); - } - { - int dataSize = 0; - for (int i = 0; i < secretEnv_.size(); i++) { - dataSize += computeStringSizeNoTag(secretEnv_.getRaw(i)); - } - size += dataSize; - size += 1 * getSecretEnvList().size(); - } - for (int i = 0; i < volumes_.size(); i++) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(9, volumes_.get(i)); - } - if (timing_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(10, getTiming()); - } - if (timeout_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(11, getTimeout()); - } - if (status_ != com.google.cloudbuild.v1.Build.Status.STATUS_UNKNOWN.getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(12, status_); - } - if (pullTiming_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(13, getPullTiming()); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(script_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(19, script_); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.BuildStep)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.BuildStep other = (com.google.cloudbuild.v1.BuildStep) obj; - - if (!getName().equals(other.getName())) return false; - if (!getEnvList().equals(other.getEnvList())) return false; - if (!getArgsList().equals(other.getArgsList())) return false; - if (!getDir().equals(other.getDir())) return false; - if (!getId().equals(other.getId())) return false; - if (!getWaitForList().equals(other.getWaitForList())) return false; - if (!getEntrypoint().equals(other.getEntrypoint())) return false; - if (!getSecretEnvList().equals(other.getSecretEnvList())) return false; - if (!getVolumesList().equals(other.getVolumesList())) return false; - if (hasTiming() != other.hasTiming()) return false; - if (hasTiming()) { - if (!getTiming().equals(other.getTiming())) return false; - } - if (hasPullTiming() != other.hasPullTiming()) return false; - if (hasPullTiming()) { - if (!getPullTiming().equals(other.getPullTiming())) return false; - } - if (hasTimeout() != other.hasTimeout()) return false; - if (hasTimeout()) { - if (!getTimeout().equals(other.getTimeout())) return false; - } - if (status_ != other.status_) return false; - if (!getScript().equals(other.getScript())) return false; - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + NAME_FIELD_NUMBER; - hash = (53 * hash) + getName().hashCode(); - if (getEnvCount() > 0) { - hash = (37 * hash) + ENV_FIELD_NUMBER; - hash = (53 * hash) + getEnvList().hashCode(); - } - if (getArgsCount() > 0) { - hash = (37 * hash) + ARGS_FIELD_NUMBER; - hash = (53 * hash) + getArgsList().hashCode(); - } - hash = (37 * hash) + DIR_FIELD_NUMBER; - hash = (53 * hash) + getDir().hashCode(); - hash = (37 * hash) + ID_FIELD_NUMBER; - hash = (53 * hash) + getId().hashCode(); - if (getWaitForCount() > 0) { - hash = (37 * hash) + WAIT_FOR_FIELD_NUMBER; - hash = (53 * hash) + getWaitForList().hashCode(); - } - hash = (37 * hash) + ENTRYPOINT_FIELD_NUMBER; - hash = (53 * hash) + getEntrypoint().hashCode(); - if (getSecretEnvCount() > 0) { - hash = (37 * hash) + SECRET_ENV_FIELD_NUMBER; - hash = (53 * hash) + getSecretEnvList().hashCode(); - } - if (getVolumesCount() > 0) { - hash = (37 * hash) + VOLUMES_FIELD_NUMBER; - hash = (53 * hash) + getVolumesList().hashCode(); - } - if (hasTiming()) { - hash = (37 * hash) + TIMING_FIELD_NUMBER; - hash = (53 * hash) + getTiming().hashCode(); - } - if (hasPullTiming()) { - hash = (37 * hash) + PULL_TIMING_FIELD_NUMBER; - hash = (53 * hash) + getPullTiming().hashCode(); - } - if (hasTimeout()) { - hash = (37 * hash) + TIMEOUT_FIELD_NUMBER; - hash = (53 * hash) + getTimeout().hashCode(); - } - hash = (37 * hash) + STATUS_FIELD_NUMBER; - hash = (53 * hash) + status_; - hash = (37 * hash) + SCRIPT_FIELD_NUMBER; - hash = (53 * hash) + getScript().hashCode(); - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.BuildStep parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.BuildStep parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.BuildStep parseFrom(com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.BuildStep parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.BuildStep parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.BuildStep parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.BuildStep parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.BuildStep parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.BuildStep parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.BuildStep parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.BuildStep parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.BuildStep parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.BuildStep prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * A step in the build pipeline.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.BuildStep} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.BuildStep) - com.google.cloudbuild.v1.BuildStepOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_BuildStep_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_BuildStep_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.BuildStep.class, - com.google.cloudbuild.v1.BuildStep.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.BuildStep.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - name_ = ""; - - env_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000001); - args_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000002); - dir_ = ""; - - id_ = ""; - - waitFor_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000004); - entrypoint_ = ""; - - secretEnv_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000008); - if (volumesBuilder_ == null) { - volumes_ = java.util.Collections.emptyList(); - } else { - volumes_ = null; - volumesBuilder_.clear(); - } - bitField0_ = (bitField0_ & ~0x00000010); - if (timingBuilder_ == null) { - timing_ = null; - } else { - timing_ = null; - timingBuilder_ = null; - } - if (pullTimingBuilder_ == null) { - pullTiming_ = null; - } else { - pullTiming_ = null; - pullTimingBuilder_ = null; - } - if (timeoutBuilder_ == null) { - timeout_ = null; - } else { - timeout_ = null; - timeoutBuilder_ = null; - } - status_ = 0; - - script_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_BuildStep_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.BuildStep getDefaultInstanceForType() { - return com.google.cloudbuild.v1.BuildStep.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.BuildStep build() { - com.google.cloudbuild.v1.BuildStep result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.BuildStep buildPartial() { - com.google.cloudbuild.v1.BuildStep result = new com.google.cloudbuild.v1.BuildStep(this); - int from_bitField0_ = bitField0_; - result.name_ = name_; - if (((bitField0_ & 0x00000001) != 0)) { - env_ = env_.getUnmodifiableView(); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.env_ = env_; - if (((bitField0_ & 0x00000002) != 0)) { - args_ = args_.getUnmodifiableView(); - bitField0_ = (bitField0_ & ~0x00000002); - } - result.args_ = args_; - result.dir_ = dir_; - result.id_ = id_; - if (((bitField0_ & 0x00000004) != 0)) { - waitFor_ = waitFor_.getUnmodifiableView(); - bitField0_ = (bitField0_ & ~0x00000004); - } - result.waitFor_ = waitFor_; - result.entrypoint_ = entrypoint_; - if (((bitField0_ & 0x00000008) != 0)) { - secretEnv_ = secretEnv_.getUnmodifiableView(); - bitField0_ = (bitField0_ & ~0x00000008); - } - result.secretEnv_ = secretEnv_; - if (volumesBuilder_ == null) { - if (((bitField0_ & 0x00000010) != 0)) { - volumes_ = java.util.Collections.unmodifiableList(volumes_); - bitField0_ = (bitField0_ & ~0x00000010); - } - result.volumes_ = volumes_; - } else { - result.volumes_ = volumesBuilder_.build(); - } - if (timingBuilder_ == null) { - result.timing_ = timing_; - } else { - result.timing_ = timingBuilder_.build(); - } - if (pullTimingBuilder_ == null) { - result.pullTiming_ = pullTiming_; - } else { - result.pullTiming_ = pullTimingBuilder_.build(); - } - if (timeoutBuilder_ == null) { - result.timeout_ = timeout_; - } else { - result.timeout_ = timeoutBuilder_.build(); - } - result.status_ = status_; - result.script_ = script_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.BuildStep) { - return mergeFrom((com.google.cloudbuild.v1.BuildStep) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.BuildStep other) { - if (other == com.google.cloudbuild.v1.BuildStep.getDefaultInstance()) return this; - if (!other.getName().isEmpty()) { - name_ = other.name_; - onChanged(); - } - if (!other.env_.isEmpty()) { - if (env_.isEmpty()) { - env_ = other.env_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureEnvIsMutable(); - env_.addAll(other.env_); - } - onChanged(); - } - if (!other.args_.isEmpty()) { - if (args_.isEmpty()) { - args_ = other.args_; - bitField0_ = (bitField0_ & ~0x00000002); - } else { - ensureArgsIsMutable(); - args_.addAll(other.args_); - } - onChanged(); - } - if (!other.getDir().isEmpty()) { - dir_ = other.dir_; - onChanged(); - } - if (!other.getId().isEmpty()) { - id_ = other.id_; - onChanged(); - } - if (!other.waitFor_.isEmpty()) { - if (waitFor_.isEmpty()) { - waitFor_ = other.waitFor_; - bitField0_ = (bitField0_ & ~0x00000004); - } else { - ensureWaitForIsMutable(); - waitFor_.addAll(other.waitFor_); - } - onChanged(); - } - if (!other.getEntrypoint().isEmpty()) { - entrypoint_ = other.entrypoint_; - onChanged(); - } - if (!other.secretEnv_.isEmpty()) { - if (secretEnv_.isEmpty()) { - secretEnv_ = other.secretEnv_; - bitField0_ = (bitField0_ & ~0x00000008); - } else { - ensureSecretEnvIsMutable(); - secretEnv_.addAll(other.secretEnv_); - } - onChanged(); - } - if (volumesBuilder_ == null) { - if (!other.volumes_.isEmpty()) { - if (volumes_.isEmpty()) { - volumes_ = other.volumes_; - bitField0_ = (bitField0_ & ~0x00000010); - } else { - ensureVolumesIsMutable(); - volumes_.addAll(other.volumes_); - } - onChanged(); - } - } else { - if (!other.volumes_.isEmpty()) { - if (volumesBuilder_.isEmpty()) { - volumesBuilder_.dispose(); - volumesBuilder_ = null; - volumes_ = other.volumes_; - bitField0_ = (bitField0_ & ~0x00000010); - volumesBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders - ? getVolumesFieldBuilder() - : null; - } else { - volumesBuilder_.addAllMessages(other.volumes_); - } - } - } - if (other.hasTiming()) { - mergeTiming(other.getTiming()); - } - if (other.hasPullTiming()) { - mergePullTiming(other.getPullTiming()); - } - if (other.hasTimeout()) { - mergeTimeout(other.getTimeout()); - } - if (other.status_ != 0) { - setStatusValue(other.getStatusValue()); - } - if (!other.getScript().isEmpty()) { - script_ = other.script_; - onChanged(); - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - name_ = input.readStringRequireUtf8(); - - break; - } // case 10 - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - ensureEnvIsMutable(); - env_.add(s); - break; - } // case 18 - case 26: - { - java.lang.String s = input.readStringRequireUtf8(); - ensureArgsIsMutable(); - args_.add(s); - break; - } // case 26 - case 34: - { - dir_ = input.readStringRequireUtf8(); - - break; - } // case 34 - case 42: - { - id_ = input.readStringRequireUtf8(); - - break; - } // case 42 - case 50: - { - java.lang.String s = input.readStringRequireUtf8(); - ensureWaitForIsMutable(); - waitFor_.add(s); - break; - } // case 50 - case 58: - { - entrypoint_ = input.readStringRequireUtf8(); - - break; - } // case 58 - case 66: - { - java.lang.String s = input.readStringRequireUtf8(); - ensureSecretEnvIsMutable(); - secretEnv_.add(s); - break; - } // case 66 - case 74: - { - com.google.cloudbuild.v1.Volume m = - input.readMessage(com.google.cloudbuild.v1.Volume.parser(), extensionRegistry); - if (volumesBuilder_ == null) { - ensureVolumesIsMutable(); - volumes_.add(m); - } else { - volumesBuilder_.addMessage(m); - } - break; - } // case 74 - case 82: - { - input.readMessage(getTimingFieldBuilder().getBuilder(), extensionRegistry); - - break; - } // case 82 - case 90: - { - input.readMessage(getTimeoutFieldBuilder().getBuilder(), extensionRegistry); - - break; - } // case 90 - case 96: - { - status_ = input.readEnum(); - - break; - } // case 96 - case 106: - { - input.readMessage(getPullTimingFieldBuilder().getBuilder(), extensionRegistry); - - break; - } // case 106 - case 154: - { - script_ = input.readStringRequireUtf8(); - - break; - } // case 154 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private int bitField0_; - - private java.lang.Object name_ = ""; - /** - * - * - *
-     * Required. The name of the container image that will run this particular
-     * build step.
-     * If the image is available in the host's Docker daemon's cache, it
-     * will be run directly. If not, the host will attempt to pull the image
-     * first, using the builder service account's credentials if necessary.
-     * The Docker daemon's cache will already have the latest versions of all of
-     * the officially supported build steps
-     * ([https://github.com/GoogleCloudPlatform/cloud-builders](https://github.com/GoogleCloudPlatform/cloud-builders)).
-     * The Docker daemon will also have cached many of the layers for some popular
-     * images, like "ubuntu", "debian", but they will be refreshed at the time you
-     * attempt to use them.
-     * If you built an image in a previous build step, it will be stored in the
-     * host's Docker daemon's cache and is available to use as the name for a
-     * later build step.
-     * 
- * - * string name = 1; - * - * @return The name. - */ - public java.lang.String getName() { - java.lang.Object ref = name_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - name_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Required. The name of the container image that will run this particular
-     * build step.
-     * If the image is available in the host's Docker daemon's cache, it
-     * will be run directly. If not, the host will attempt to pull the image
-     * first, using the builder service account's credentials if necessary.
-     * The Docker daemon's cache will already have the latest versions of all of
-     * the officially supported build steps
-     * ([https://github.com/GoogleCloudPlatform/cloud-builders](https://github.com/GoogleCloudPlatform/cloud-builders)).
-     * The Docker daemon will also have cached many of the layers for some popular
-     * images, like "ubuntu", "debian", but they will be refreshed at the time you
-     * attempt to use them.
-     * If you built an image in a previous build step, it will be stored in the
-     * host's Docker daemon's cache and is available to use as the name for a
-     * later build step.
-     * 
- * - * string name = 1; - * - * @return The bytes for name. - */ - public com.google.protobuf.ByteString getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Required. The name of the container image that will run this particular
-     * build step.
-     * If the image is available in the host's Docker daemon's cache, it
-     * will be run directly. If not, the host will attempt to pull the image
-     * first, using the builder service account's credentials if necessary.
-     * The Docker daemon's cache will already have the latest versions of all of
-     * the officially supported build steps
-     * ([https://github.com/GoogleCloudPlatform/cloud-builders](https://github.com/GoogleCloudPlatform/cloud-builders)).
-     * The Docker daemon will also have cached many of the layers for some popular
-     * images, like "ubuntu", "debian", but they will be refreshed at the time you
-     * attempt to use them.
-     * If you built an image in a previous build step, it will be stored in the
-     * host's Docker daemon's cache and is available to use as the name for a
-     * later build step.
-     * 
- * - * string name = 1; - * - * @param value The name to set. - * @return This builder for chaining. - */ - public Builder setName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - name_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Required. The name of the container image that will run this particular
-     * build step.
-     * If the image is available in the host's Docker daemon's cache, it
-     * will be run directly. If not, the host will attempt to pull the image
-     * first, using the builder service account's credentials if necessary.
-     * The Docker daemon's cache will already have the latest versions of all of
-     * the officially supported build steps
-     * ([https://github.com/GoogleCloudPlatform/cloud-builders](https://github.com/GoogleCloudPlatform/cloud-builders)).
-     * The Docker daemon will also have cached many of the layers for some popular
-     * images, like "ubuntu", "debian", but they will be refreshed at the time you
-     * attempt to use them.
-     * If you built an image in a previous build step, it will be stored in the
-     * host's Docker daemon's cache and is available to use as the name for a
-     * later build step.
-     * 
- * - * string name = 1; - * - * @return This builder for chaining. - */ - public Builder clearName() { - - name_ = getDefaultInstance().getName(); - onChanged(); - return this; - } - /** - * - * - *
-     * Required. The name of the container image that will run this particular
-     * build step.
-     * If the image is available in the host's Docker daemon's cache, it
-     * will be run directly. If not, the host will attempt to pull the image
-     * first, using the builder service account's credentials if necessary.
-     * The Docker daemon's cache will already have the latest versions of all of
-     * the officially supported build steps
-     * ([https://github.com/GoogleCloudPlatform/cloud-builders](https://github.com/GoogleCloudPlatform/cloud-builders)).
-     * The Docker daemon will also have cached many of the layers for some popular
-     * images, like "ubuntu", "debian", but they will be refreshed at the time you
-     * attempt to use them.
-     * If you built an image in a previous build step, it will be stored in the
-     * host's Docker daemon's cache and is available to use as the name for a
-     * later build step.
-     * 
- * - * string name = 1; - * - * @param value The bytes for name to set. - * @return This builder for chaining. - */ - public Builder setNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - name_ = value; - onChanged(); - return this; - } - - private com.google.protobuf.LazyStringList env_ = com.google.protobuf.LazyStringArrayList.EMPTY; - - private void ensureEnvIsMutable() { - if (!((bitField0_ & 0x00000001) != 0)) { - env_ = new com.google.protobuf.LazyStringArrayList(env_); - bitField0_ |= 0x00000001; - } - } - /** - * - * - *
-     * A list of environment variable definitions to be used when running a step.
-     * The elements are of the form "KEY=VALUE" for the environment variable "KEY"
-     * being given the value "VALUE".
-     * 
- * - * repeated string env = 2; - * - * @return A list containing the env. - */ - public com.google.protobuf.ProtocolStringList getEnvList() { - return env_.getUnmodifiableView(); - } - /** - * - * - *
-     * A list of environment variable definitions to be used when running a step.
-     * The elements are of the form "KEY=VALUE" for the environment variable "KEY"
-     * being given the value "VALUE".
-     * 
- * - * repeated string env = 2; - * - * @return The count of env. - */ - public int getEnvCount() { - return env_.size(); - } - /** - * - * - *
-     * A list of environment variable definitions to be used when running a step.
-     * The elements are of the form "KEY=VALUE" for the environment variable "KEY"
-     * being given the value "VALUE".
-     * 
- * - * repeated string env = 2; - * - * @param index The index of the element to return. - * @return The env at the given index. - */ - public java.lang.String getEnv(int index) { - return env_.get(index); - } - /** - * - * - *
-     * A list of environment variable definitions to be used when running a step.
-     * The elements are of the form "KEY=VALUE" for the environment variable "KEY"
-     * being given the value "VALUE".
-     * 
- * - * repeated string env = 2; - * - * @param index The index of the value to return. - * @return The bytes of the env at the given index. - */ - public com.google.protobuf.ByteString getEnvBytes(int index) { - return env_.getByteString(index); - } - /** - * - * - *
-     * A list of environment variable definitions to be used when running a step.
-     * The elements are of the form "KEY=VALUE" for the environment variable "KEY"
-     * being given the value "VALUE".
-     * 
- * - * repeated string env = 2; - * - * @param index The index to set the value at. - * @param value The env to set. - * @return This builder for chaining. - */ - public Builder setEnv(int index, java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureEnvIsMutable(); - env_.set(index, value); - onChanged(); - return this; - } - /** - * - * - *
-     * A list of environment variable definitions to be used when running a step.
-     * The elements are of the form "KEY=VALUE" for the environment variable "KEY"
-     * being given the value "VALUE".
-     * 
- * - * repeated string env = 2; - * - * @param value The env to add. - * @return This builder for chaining. - */ - public Builder addEnv(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureEnvIsMutable(); - env_.add(value); - onChanged(); - return this; - } - /** - * - * - *
-     * A list of environment variable definitions to be used when running a step.
-     * The elements are of the form "KEY=VALUE" for the environment variable "KEY"
-     * being given the value "VALUE".
-     * 
- * - * repeated string env = 2; - * - * @param values The env to add. - * @return This builder for chaining. - */ - public Builder addAllEnv(java.lang.Iterable values) { - ensureEnvIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, env_); - onChanged(); - return this; - } - /** - * - * - *
-     * A list of environment variable definitions to be used when running a step.
-     * The elements are of the form "KEY=VALUE" for the environment variable "KEY"
-     * being given the value "VALUE".
-     * 
- * - * repeated string env = 2; - * - * @return This builder for chaining. - */ - public Builder clearEnv() { - env_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - return this; - } - /** - * - * - *
-     * A list of environment variable definitions to be used when running a step.
-     * The elements are of the form "KEY=VALUE" for the environment variable "KEY"
-     * being given the value "VALUE".
-     * 
- * - * repeated string env = 2; - * - * @param value The bytes of the env to add. - * @return This builder for chaining. - */ - public Builder addEnvBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - ensureEnvIsMutable(); - env_.add(value); - onChanged(); - return this; - } - - private com.google.protobuf.LazyStringList args_ = - com.google.protobuf.LazyStringArrayList.EMPTY; - - private void ensureArgsIsMutable() { - if (!((bitField0_ & 0x00000002) != 0)) { - args_ = new com.google.protobuf.LazyStringArrayList(args_); - bitField0_ |= 0x00000002; - } - } - /** - * - * - *
-     * A list of arguments that will be presented to the step when it is started.
-     * If the image used to run the step's container has an entrypoint, the `args`
-     * are used as arguments to that entrypoint. If the image does not define
-     * an entrypoint, the first element in args is used as the entrypoint,
-     * and the remainder will be used as arguments.
-     * 
- * - * repeated string args = 3; - * - * @return A list containing the args. - */ - public com.google.protobuf.ProtocolStringList getArgsList() { - return args_.getUnmodifiableView(); - } - /** - * - * - *
-     * A list of arguments that will be presented to the step when it is started.
-     * If the image used to run the step's container has an entrypoint, the `args`
-     * are used as arguments to that entrypoint. If the image does not define
-     * an entrypoint, the first element in args is used as the entrypoint,
-     * and the remainder will be used as arguments.
-     * 
- * - * repeated string args = 3; - * - * @return The count of args. - */ - public int getArgsCount() { - return args_.size(); - } - /** - * - * - *
-     * A list of arguments that will be presented to the step when it is started.
-     * If the image used to run the step's container has an entrypoint, the `args`
-     * are used as arguments to that entrypoint. If the image does not define
-     * an entrypoint, the first element in args is used as the entrypoint,
-     * and the remainder will be used as arguments.
-     * 
- * - * repeated string args = 3; - * - * @param index The index of the element to return. - * @return The args at the given index. - */ - public java.lang.String getArgs(int index) { - return args_.get(index); - } - /** - * - * - *
-     * A list of arguments that will be presented to the step when it is started.
-     * If the image used to run the step's container has an entrypoint, the `args`
-     * are used as arguments to that entrypoint. If the image does not define
-     * an entrypoint, the first element in args is used as the entrypoint,
-     * and the remainder will be used as arguments.
-     * 
- * - * repeated string args = 3; - * - * @param index The index of the value to return. - * @return The bytes of the args at the given index. - */ - public com.google.protobuf.ByteString getArgsBytes(int index) { - return args_.getByteString(index); - } - /** - * - * - *
-     * A list of arguments that will be presented to the step when it is started.
-     * If the image used to run the step's container has an entrypoint, the `args`
-     * are used as arguments to that entrypoint. If the image does not define
-     * an entrypoint, the first element in args is used as the entrypoint,
-     * and the remainder will be used as arguments.
-     * 
- * - * repeated string args = 3; - * - * @param index The index to set the value at. - * @param value The args to set. - * @return This builder for chaining. - */ - public Builder setArgs(int index, java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureArgsIsMutable(); - args_.set(index, value); - onChanged(); - return this; - } - /** - * - * - *
-     * A list of arguments that will be presented to the step when it is started.
-     * If the image used to run the step's container has an entrypoint, the `args`
-     * are used as arguments to that entrypoint. If the image does not define
-     * an entrypoint, the first element in args is used as the entrypoint,
-     * and the remainder will be used as arguments.
-     * 
- * - * repeated string args = 3; - * - * @param value The args to add. - * @return This builder for chaining. - */ - public Builder addArgs(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureArgsIsMutable(); - args_.add(value); - onChanged(); - return this; - } - /** - * - * - *
-     * A list of arguments that will be presented to the step when it is started.
-     * If the image used to run the step's container has an entrypoint, the `args`
-     * are used as arguments to that entrypoint. If the image does not define
-     * an entrypoint, the first element in args is used as the entrypoint,
-     * and the remainder will be used as arguments.
-     * 
- * - * repeated string args = 3; - * - * @param values The args to add. - * @return This builder for chaining. - */ - public Builder addAllArgs(java.lang.Iterable values) { - ensureArgsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, args_); - onChanged(); - return this; - } - /** - * - * - *
-     * A list of arguments that will be presented to the step when it is started.
-     * If the image used to run the step's container has an entrypoint, the `args`
-     * are used as arguments to that entrypoint. If the image does not define
-     * an entrypoint, the first element in args is used as the entrypoint,
-     * and the remainder will be used as arguments.
-     * 
- * - * repeated string args = 3; - * - * @return This builder for chaining. - */ - public Builder clearArgs() { - args_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000002); - onChanged(); - return this; - } - /** - * - * - *
-     * A list of arguments that will be presented to the step when it is started.
-     * If the image used to run the step's container has an entrypoint, the `args`
-     * are used as arguments to that entrypoint. If the image does not define
-     * an entrypoint, the first element in args is used as the entrypoint,
-     * and the remainder will be used as arguments.
-     * 
- * - * repeated string args = 3; - * - * @param value The bytes of the args to add. - * @return This builder for chaining. - */ - public Builder addArgsBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - ensureArgsIsMutable(); - args_.add(value); - onChanged(); - return this; - } - - private java.lang.Object dir_ = ""; - /** - * - * - *
-     * Working directory to use when running this step's container.
-     * If this value is a relative path, it is relative to the build's working
-     * directory. If this value is absolute, it may be outside the build's working
-     * directory, in which case the contents of the path may not be persisted
-     * across build step executions, unless a `volume` for that path is specified.
-     * If the build specifies a `RepoSource` with `dir` and a step with a `dir`,
-     * which specifies an absolute path, the `RepoSource` `dir` is ignored for
-     * the step's execution.
-     * 
- * - * string dir = 4; - * - * @return The dir. - */ - public java.lang.String getDir() { - java.lang.Object ref = dir_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - dir_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Working directory to use when running this step's container.
-     * If this value is a relative path, it is relative to the build's working
-     * directory. If this value is absolute, it may be outside the build's working
-     * directory, in which case the contents of the path may not be persisted
-     * across build step executions, unless a `volume` for that path is specified.
-     * If the build specifies a `RepoSource` with `dir` and a step with a `dir`,
-     * which specifies an absolute path, the `RepoSource` `dir` is ignored for
-     * the step's execution.
-     * 
- * - * string dir = 4; - * - * @return The bytes for dir. - */ - public com.google.protobuf.ByteString getDirBytes() { - java.lang.Object ref = dir_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - dir_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Working directory to use when running this step's container.
-     * If this value is a relative path, it is relative to the build's working
-     * directory. If this value is absolute, it may be outside the build's working
-     * directory, in which case the contents of the path may not be persisted
-     * across build step executions, unless a `volume` for that path is specified.
-     * If the build specifies a `RepoSource` with `dir` and a step with a `dir`,
-     * which specifies an absolute path, the `RepoSource` `dir` is ignored for
-     * the step's execution.
-     * 
- * - * string dir = 4; - * - * @param value The dir to set. - * @return This builder for chaining. - */ - public Builder setDir(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - dir_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Working directory to use when running this step's container.
-     * If this value is a relative path, it is relative to the build's working
-     * directory. If this value is absolute, it may be outside the build's working
-     * directory, in which case the contents of the path may not be persisted
-     * across build step executions, unless a `volume` for that path is specified.
-     * If the build specifies a `RepoSource` with `dir` and a step with a `dir`,
-     * which specifies an absolute path, the `RepoSource` `dir` is ignored for
-     * the step's execution.
-     * 
- * - * string dir = 4; - * - * @return This builder for chaining. - */ - public Builder clearDir() { - - dir_ = getDefaultInstance().getDir(); - onChanged(); - return this; - } - /** - * - * - *
-     * Working directory to use when running this step's container.
-     * If this value is a relative path, it is relative to the build's working
-     * directory. If this value is absolute, it may be outside the build's working
-     * directory, in which case the contents of the path may not be persisted
-     * across build step executions, unless a `volume` for that path is specified.
-     * If the build specifies a `RepoSource` with `dir` and a step with a `dir`,
-     * which specifies an absolute path, the `RepoSource` `dir` is ignored for
-     * the step's execution.
-     * 
- * - * string dir = 4; - * - * @param value The bytes for dir to set. - * @return This builder for chaining. - */ - public Builder setDirBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - dir_ = value; - onChanged(); - return this; - } - - private java.lang.Object id_ = ""; - /** - * - * - *
-     * Unique identifier for this build step, used in `wait_for` to
-     * reference this build step as a dependency.
-     * 
- * - * string id = 5; - * - * @return The id. - */ - public java.lang.String getId() { - java.lang.Object ref = id_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - id_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Unique identifier for this build step, used in `wait_for` to
-     * reference this build step as a dependency.
-     * 
- * - * string id = 5; - * - * @return The bytes for id. - */ - public com.google.protobuf.ByteString getIdBytes() { - java.lang.Object ref = id_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - id_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Unique identifier for this build step, used in `wait_for` to
-     * reference this build step as a dependency.
-     * 
- * - * string id = 5; - * - * @param value The id to set. - * @return This builder for chaining. - */ - public Builder setId(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - id_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Unique identifier for this build step, used in `wait_for` to
-     * reference this build step as a dependency.
-     * 
- * - * string id = 5; - * - * @return This builder for chaining. - */ - public Builder clearId() { - - id_ = getDefaultInstance().getId(); - onChanged(); - return this; - } - /** - * - * - *
-     * Unique identifier for this build step, used in `wait_for` to
-     * reference this build step as a dependency.
-     * 
- * - * string id = 5; - * - * @param value The bytes for id to set. - * @return This builder for chaining. - */ - public Builder setIdBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - id_ = value; - onChanged(); - return this; - } - - private com.google.protobuf.LazyStringList waitFor_ = - com.google.protobuf.LazyStringArrayList.EMPTY; - - private void ensureWaitForIsMutable() { - if (!((bitField0_ & 0x00000004) != 0)) { - waitFor_ = new com.google.protobuf.LazyStringArrayList(waitFor_); - bitField0_ |= 0x00000004; - } - } - /** - * - * - *
-     * The ID(s) of the step(s) that this build step depends on.
-     * This build step will not start until all the build steps in `wait_for`
-     * have completed successfully. If `wait_for` is empty, this build step will
-     * start when all previous build steps in the `Build.Steps` list have
-     * completed successfully.
-     * 
- * - * repeated string wait_for = 6; - * - * @return A list containing the waitFor. - */ - public com.google.protobuf.ProtocolStringList getWaitForList() { - return waitFor_.getUnmodifiableView(); - } - /** - * - * - *
-     * The ID(s) of the step(s) that this build step depends on.
-     * This build step will not start until all the build steps in `wait_for`
-     * have completed successfully. If `wait_for` is empty, this build step will
-     * start when all previous build steps in the `Build.Steps` list have
-     * completed successfully.
-     * 
- * - * repeated string wait_for = 6; - * - * @return The count of waitFor. - */ - public int getWaitForCount() { - return waitFor_.size(); - } - /** - * - * - *
-     * The ID(s) of the step(s) that this build step depends on.
-     * This build step will not start until all the build steps in `wait_for`
-     * have completed successfully. If `wait_for` is empty, this build step will
-     * start when all previous build steps in the `Build.Steps` list have
-     * completed successfully.
-     * 
- * - * repeated string wait_for = 6; - * - * @param index The index of the element to return. - * @return The waitFor at the given index. - */ - public java.lang.String getWaitFor(int index) { - return waitFor_.get(index); - } - /** - * - * - *
-     * The ID(s) of the step(s) that this build step depends on.
-     * This build step will not start until all the build steps in `wait_for`
-     * have completed successfully. If `wait_for` is empty, this build step will
-     * start when all previous build steps in the `Build.Steps` list have
-     * completed successfully.
-     * 
- * - * repeated string wait_for = 6; - * - * @param index The index of the value to return. - * @return The bytes of the waitFor at the given index. - */ - public com.google.protobuf.ByteString getWaitForBytes(int index) { - return waitFor_.getByteString(index); - } - /** - * - * - *
-     * The ID(s) of the step(s) that this build step depends on.
-     * This build step will not start until all the build steps in `wait_for`
-     * have completed successfully. If `wait_for` is empty, this build step will
-     * start when all previous build steps in the `Build.Steps` list have
-     * completed successfully.
-     * 
- * - * repeated string wait_for = 6; - * - * @param index The index to set the value at. - * @param value The waitFor to set. - * @return This builder for chaining. - */ - public Builder setWaitFor(int index, java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureWaitForIsMutable(); - waitFor_.set(index, value); - onChanged(); - return this; - } - /** - * - * - *
-     * The ID(s) of the step(s) that this build step depends on.
-     * This build step will not start until all the build steps in `wait_for`
-     * have completed successfully. If `wait_for` is empty, this build step will
-     * start when all previous build steps in the `Build.Steps` list have
-     * completed successfully.
-     * 
- * - * repeated string wait_for = 6; - * - * @param value The waitFor to add. - * @return This builder for chaining. - */ - public Builder addWaitFor(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureWaitForIsMutable(); - waitFor_.add(value); - onChanged(); - return this; - } - /** - * - * - *
-     * The ID(s) of the step(s) that this build step depends on.
-     * This build step will not start until all the build steps in `wait_for`
-     * have completed successfully. If `wait_for` is empty, this build step will
-     * start when all previous build steps in the `Build.Steps` list have
-     * completed successfully.
-     * 
- * - * repeated string wait_for = 6; - * - * @param values The waitFor to add. - * @return This builder for chaining. - */ - public Builder addAllWaitFor(java.lang.Iterable values) { - ensureWaitForIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, waitFor_); - onChanged(); - return this; - } - /** - * - * - *
-     * The ID(s) of the step(s) that this build step depends on.
-     * This build step will not start until all the build steps in `wait_for`
-     * have completed successfully. If `wait_for` is empty, this build step will
-     * start when all previous build steps in the `Build.Steps` list have
-     * completed successfully.
-     * 
- * - * repeated string wait_for = 6; - * - * @return This builder for chaining. - */ - public Builder clearWaitFor() { - waitFor_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000004); - onChanged(); - return this; - } - /** - * - * - *
-     * The ID(s) of the step(s) that this build step depends on.
-     * This build step will not start until all the build steps in `wait_for`
-     * have completed successfully. If `wait_for` is empty, this build step will
-     * start when all previous build steps in the `Build.Steps` list have
-     * completed successfully.
-     * 
- * - * repeated string wait_for = 6; - * - * @param value The bytes of the waitFor to add. - * @return This builder for chaining. - */ - public Builder addWaitForBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - ensureWaitForIsMutable(); - waitFor_.add(value); - onChanged(); - return this; - } - - private java.lang.Object entrypoint_ = ""; - /** - * - * - *
-     * Entrypoint to be used instead of the build step image's default entrypoint.
-     * If unset, the image's default entrypoint is used.
-     * 
- * - * string entrypoint = 7; - * - * @return The entrypoint. - */ - public java.lang.String getEntrypoint() { - java.lang.Object ref = entrypoint_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - entrypoint_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Entrypoint to be used instead of the build step image's default entrypoint.
-     * If unset, the image's default entrypoint is used.
-     * 
- * - * string entrypoint = 7; - * - * @return The bytes for entrypoint. - */ - public com.google.protobuf.ByteString getEntrypointBytes() { - java.lang.Object ref = entrypoint_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - entrypoint_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Entrypoint to be used instead of the build step image's default entrypoint.
-     * If unset, the image's default entrypoint is used.
-     * 
- * - * string entrypoint = 7; - * - * @param value The entrypoint to set. - * @return This builder for chaining. - */ - public Builder setEntrypoint(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - entrypoint_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Entrypoint to be used instead of the build step image's default entrypoint.
-     * If unset, the image's default entrypoint is used.
-     * 
- * - * string entrypoint = 7; - * - * @return This builder for chaining. - */ - public Builder clearEntrypoint() { - - entrypoint_ = getDefaultInstance().getEntrypoint(); - onChanged(); - return this; - } - /** - * - * - *
-     * Entrypoint to be used instead of the build step image's default entrypoint.
-     * If unset, the image's default entrypoint is used.
-     * 
- * - * string entrypoint = 7; - * - * @param value The bytes for entrypoint to set. - * @return This builder for chaining. - */ - public Builder setEntrypointBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - entrypoint_ = value; - onChanged(); - return this; - } - - private com.google.protobuf.LazyStringList secretEnv_ = - com.google.protobuf.LazyStringArrayList.EMPTY; - - private void ensureSecretEnvIsMutable() { - if (!((bitField0_ & 0x00000008) != 0)) { - secretEnv_ = new com.google.protobuf.LazyStringArrayList(secretEnv_); - bitField0_ |= 0x00000008; - } - } - /** - * - * - *
-     * A list of environment variables which are encrypted using a Cloud Key
-     * Management Service crypto key. These values must be specified in the
-     * build's `Secret`.
-     * 
- * - * repeated string secret_env = 8; - * - * @return A list containing the secretEnv. - */ - public com.google.protobuf.ProtocolStringList getSecretEnvList() { - return secretEnv_.getUnmodifiableView(); - } - /** - * - * - *
-     * A list of environment variables which are encrypted using a Cloud Key
-     * Management Service crypto key. These values must be specified in the
-     * build's `Secret`.
-     * 
- * - * repeated string secret_env = 8; - * - * @return The count of secretEnv. - */ - public int getSecretEnvCount() { - return secretEnv_.size(); - } - /** - * - * - *
-     * A list of environment variables which are encrypted using a Cloud Key
-     * Management Service crypto key. These values must be specified in the
-     * build's `Secret`.
-     * 
- * - * repeated string secret_env = 8; - * - * @param index The index of the element to return. - * @return The secretEnv at the given index. - */ - public java.lang.String getSecretEnv(int index) { - return secretEnv_.get(index); - } - /** - * - * - *
-     * A list of environment variables which are encrypted using a Cloud Key
-     * Management Service crypto key. These values must be specified in the
-     * build's `Secret`.
-     * 
- * - * repeated string secret_env = 8; - * - * @param index The index of the value to return. - * @return The bytes of the secretEnv at the given index. - */ - public com.google.protobuf.ByteString getSecretEnvBytes(int index) { - return secretEnv_.getByteString(index); - } - /** - * - * - *
-     * A list of environment variables which are encrypted using a Cloud Key
-     * Management Service crypto key. These values must be specified in the
-     * build's `Secret`.
-     * 
- * - * repeated string secret_env = 8; - * - * @param index The index to set the value at. - * @param value The secretEnv to set. - * @return This builder for chaining. - */ - public Builder setSecretEnv(int index, java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureSecretEnvIsMutable(); - secretEnv_.set(index, value); - onChanged(); - return this; - } - /** - * - * - *
-     * A list of environment variables which are encrypted using a Cloud Key
-     * Management Service crypto key. These values must be specified in the
-     * build's `Secret`.
-     * 
- * - * repeated string secret_env = 8; - * - * @param value The secretEnv to add. - * @return This builder for chaining. - */ - public Builder addSecretEnv(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureSecretEnvIsMutable(); - secretEnv_.add(value); - onChanged(); - return this; - } - /** - * - * - *
-     * A list of environment variables which are encrypted using a Cloud Key
-     * Management Service crypto key. These values must be specified in the
-     * build's `Secret`.
-     * 
- * - * repeated string secret_env = 8; - * - * @param values The secretEnv to add. - * @return This builder for chaining. - */ - public Builder addAllSecretEnv(java.lang.Iterable values) { - ensureSecretEnvIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, secretEnv_); - onChanged(); - return this; - } - /** - * - * - *
-     * A list of environment variables which are encrypted using a Cloud Key
-     * Management Service crypto key. These values must be specified in the
-     * build's `Secret`.
-     * 
- * - * repeated string secret_env = 8; - * - * @return This builder for chaining. - */ - public Builder clearSecretEnv() { - secretEnv_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000008); - onChanged(); - return this; - } - /** - * - * - *
-     * A list of environment variables which are encrypted using a Cloud Key
-     * Management Service crypto key. These values must be specified in the
-     * build's `Secret`.
-     * 
- * - * repeated string secret_env = 8; - * - * @param value The bytes of the secretEnv to add. - * @return This builder for chaining. - */ - public Builder addSecretEnvBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - ensureSecretEnvIsMutable(); - secretEnv_.add(value); - onChanged(); - return this; - } - - private java.util.List volumes_ = - java.util.Collections.emptyList(); - - private void ensureVolumesIsMutable() { - if (!((bitField0_ & 0x00000010) != 0)) { - volumes_ = new java.util.ArrayList(volumes_); - bitField0_ |= 0x00000010; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloudbuild.v1.Volume, - com.google.cloudbuild.v1.Volume.Builder, - com.google.cloudbuild.v1.VolumeOrBuilder> - volumesBuilder_; - - /** - * - * - *
-     * List of volumes to mount into the build step.
-     * Each volume is created as an empty volume prior to execution of the
-     * build step. Upon completion of the build, volumes and their contents are
-     * discarded.
-     * Using a named volume in only one step is not valid as it is indicative
-     * of a build request with an incorrect configuration.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 9; - */ - public java.util.List getVolumesList() { - if (volumesBuilder_ == null) { - return java.util.Collections.unmodifiableList(volumes_); - } else { - return volumesBuilder_.getMessageList(); - } - } - /** - * - * - *
-     * List of volumes to mount into the build step.
-     * Each volume is created as an empty volume prior to execution of the
-     * build step. Upon completion of the build, volumes and their contents are
-     * discarded.
-     * Using a named volume in only one step is not valid as it is indicative
-     * of a build request with an incorrect configuration.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 9; - */ - public int getVolumesCount() { - if (volumesBuilder_ == null) { - return volumes_.size(); - } else { - return volumesBuilder_.getCount(); - } - } - /** - * - * - *
-     * List of volumes to mount into the build step.
-     * Each volume is created as an empty volume prior to execution of the
-     * build step. Upon completion of the build, volumes and their contents are
-     * discarded.
-     * Using a named volume in only one step is not valid as it is indicative
-     * of a build request with an incorrect configuration.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 9; - */ - public com.google.cloudbuild.v1.Volume getVolumes(int index) { - if (volumesBuilder_ == null) { - return volumes_.get(index); - } else { - return volumesBuilder_.getMessage(index); - } - } - /** - * - * - *
-     * List of volumes to mount into the build step.
-     * Each volume is created as an empty volume prior to execution of the
-     * build step. Upon completion of the build, volumes and their contents are
-     * discarded.
-     * Using a named volume in only one step is not valid as it is indicative
-     * of a build request with an incorrect configuration.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 9; - */ - public Builder setVolumes(int index, com.google.cloudbuild.v1.Volume value) { - if (volumesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureVolumesIsMutable(); - volumes_.set(index, value); - onChanged(); - } else { - volumesBuilder_.setMessage(index, value); - } - return this; - } - /** - * - * - *
-     * List of volumes to mount into the build step.
-     * Each volume is created as an empty volume prior to execution of the
-     * build step. Upon completion of the build, volumes and their contents are
-     * discarded.
-     * Using a named volume in only one step is not valid as it is indicative
-     * of a build request with an incorrect configuration.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 9; - */ - public Builder setVolumes(int index, com.google.cloudbuild.v1.Volume.Builder builderForValue) { - if (volumesBuilder_ == null) { - ensureVolumesIsMutable(); - volumes_.set(index, builderForValue.build()); - onChanged(); - } else { - volumesBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * List of volumes to mount into the build step.
-     * Each volume is created as an empty volume prior to execution of the
-     * build step. Upon completion of the build, volumes and their contents are
-     * discarded.
-     * Using a named volume in only one step is not valid as it is indicative
-     * of a build request with an incorrect configuration.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 9; - */ - public Builder addVolumes(com.google.cloudbuild.v1.Volume value) { - if (volumesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureVolumesIsMutable(); - volumes_.add(value); - onChanged(); - } else { - volumesBuilder_.addMessage(value); - } - return this; - } - /** - * - * - *
-     * List of volumes to mount into the build step.
-     * Each volume is created as an empty volume prior to execution of the
-     * build step. Upon completion of the build, volumes and their contents are
-     * discarded.
-     * Using a named volume in only one step is not valid as it is indicative
-     * of a build request with an incorrect configuration.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 9; - */ - public Builder addVolumes(int index, com.google.cloudbuild.v1.Volume value) { - if (volumesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureVolumesIsMutable(); - volumes_.add(index, value); - onChanged(); - } else { - volumesBuilder_.addMessage(index, value); - } - return this; - } - /** - * - * - *
-     * List of volumes to mount into the build step.
-     * Each volume is created as an empty volume prior to execution of the
-     * build step. Upon completion of the build, volumes and their contents are
-     * discarded.
-     * Using a named volume in only one step is not valid as it is indicative
-     * of a build request with an incorrect configuration.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 9; - */ - public Builder addVolumes(com.google.cloudbuild.v1.Volume.Builder builderForValue) { - if (volumesBuilder_ == null) { - ensureVolumesIsMutable(); - volumes_.add(builderForValue.build()); - onChanged(); - } else { - volumesBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * List of volumes to mount into the build step.
-     * Each volume is created as an empty volume prior to execution of the
-     * build step. Upon completion of the build, volumes and their contents are
-     * discarded.
-     * Using a named volume in only one step is not valid as it is indicative
-     * of a build request with an incorrect configuration.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 9; - */ - public Builder addVolumes(int index, com.google.cloudbuild.v1.Volume.Builder builderForValue) { - if (volumesBuilder_ == null) { - ensureVolumesIsMutable(); - volumes_.add(index, builderForValue.build()); - onChanged(); - } else { - volumesBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * List of volumes to mount into the build step.
-     * Each volume is created as an empty volume prior to execution of the
-     * build step. Upon completion of the build, volumes and their contents are
-     * discarded.
-     * Using a named volume in only one step is not valid as it is indicative
-     * of a build request with an incorrect configuration.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 9; - */ - public Builder addAllVolumes( - java.lang.Iterable values) { - if (volumesBuilder_ == null) { - ensureVolumesIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, volumes_); - onChanged(); - } else { - volumesBuilder_.addAllMessages(values); - } - return this; - } - /** - * - * - *
-     * List of volumes to mount into the build step.
-     * Each volume is created as an empty volume prior to execution of the
-     * build step. Upon completion of the build, volumes and their contents are
-     * discarded.
-     * Using a named volume in only one step is not valid as it is indicative
-     * of a build request with an incorrect configuration.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 9; - */ - public Builder clearVolumes() { - if (volumesBuilder_ == null) { - volumes_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000010); - onChanged(); - } else { - volumesBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * List of volumes to mount into the build step.
-     * Each volume is created as an empty volume prior to execution of the
-     * build step. Upon completion of the build, volumes and their contents are
-     * discarded.
-     * Using a named volume in only one step is not valid as it is indicative
-     * of a build request with an incorrect configuration.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 9; - */ - public Builder removeVolumes(int index) { - if (volumesBuilder_ == null) { - ensureVolumesIsMutable(); - volumes_.remove(index); - onChanged(); - } else { - volumesBuilder_.remove(index); - } - return this; - } - /** - * - * - *
-     * List of volumes to mount into the build step.
-     * Each volume is created as an empty volume prior to execution of the
-     * build step. Upon completion of the build, volumes and their contents are
-     * discarded.
-     * Using a named volume in only one step is not valid as it is indicative
-     * of a build request with an incorrect configuration.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 9; - */ - public com.google.cloudbuild.v1.Volume.Builder getVolumesBuilder(int index) { - return getVolumesFieldBuilder().getBuilder(index); - } - /** - * - * - *
-     * List of volumes to mount into the build step.
-     * Each volume is created as an empty volume prior to execution of the
-     * build step. Upon completion of the build, volumes and their contents are
-     * discarded.
-     * Using a named volume in only one step is not valid as it is indicative
-     * of a build request with an incorrect configuration.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 9; - */ - public com.google.cloudbuild.v1.VolumeOrBuilder getVolumesOrBuilder(int index) { - if (volumesBuilder_ == null) { - return volumes_.get(index); - } else { - return volumesBuilder_.getMessageOrBuilder(index); - } - } - /** - * - * - *
-     * List of volumes to mount into the build step.
-     * Each volume is created as an empty volume prior to execution of the
-     * build step. Upon completion of the build, volumes and their contents are
-     * discarded.
-     * Using a named volume in only one step is not valid as it is indicative
-     * of a build request with an incorrect configuration.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 9; - */ - public java.util.List - getVolumesOrBuilderList() { - if (volumesBuilder_ != null) { - return volumesBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(volumes_); - } - } - /** - * - * - *
-     * List of volumes to mount into the build step.
-     * Each volume is created as an empty volume prior to execution of the
-     * build step. Upon completion of the build, volumes and their contents are
-     * discarded.
-     * Using a named volume in only one step is not valid as it is indicative
-     * of a build request with an incorrect configuration.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 9; - */ - public com.google.cloudbuild.v1.Volume.Builder addVolumesBuilder() { - return getVolumesFieldBuilder() - .addBuilder(com.google.cloudbuild.v1.Volume.getDefaultInstance()); - } - /** - * - * - *
-     * List of volumes to mount into the build step.
-     * Each volume is created as an empty volume prior to execution of the
-     * build step. Upon completion of the build, volumes and their contents are
-     * discarded.
-     * Using a named volume in only one step is not valid as it is indicative
-     * of a build request with an incorrect configuration.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 9; - */ - public com.google.cloudbuild.v1.Volume.Builder addVolumesBuilder(int index) { - return getVolumesFieldBuilder() - .addBuilder(index, com.google.cloudbuild.v1.Volume.getDefaultInstance()); - } - /** - * - * - *
-     * List of volumes to mount into the build step.
-     * Each volume is created as an empty volume prior to execution of the
-     * build step. Upon completion of the build, volumes and their contents are
-     * discarded.
-     * Using a named volume in only one step is not valid as it is indicative
-     * of a build request with an incorrect configuration.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 9; - */ - public java.util.List getVolumesBuilderList() { - return getVolumesFieldBuilder().getBuilderList(); - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloudbuild.v1.Volume, - com.google.cloudbuild.v1.Volume.Builder, - com.google.cloudbuild.v1.VolumeOrBuilder> - getVolumesFieldBuilder() { - if (volumesBuilder_ == null) { - volumesBuilder_ = - new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloudbuild.v1.Volume, - com.google.cloudbuild.v1.Volume.Builder, - com.google.cloudbuild.v1.VolumeOrBuilder>( - volumes_, ((bitField0_ & 0x00000010) != 0), getParentForChildren(), isClean()); - volumes_ = null; - } - return volumesBuilder_; - } - - private com.google.cloudbuild.v1.TimeSpan timing_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.TimeSpan, - com.google.cloudbuild.v1.TimeSpan.Builder, - com.google.cloudbuild.v1.TimeSpanOrBuilder> - timingBuilder_; - /** - * - * - *
-     * Output only. Stores timing information for executing this build step.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan timing = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return Whether the timing field is set. - */ - public boolean hasTiming() { - return timingBuilder_ != null || timing_ != null; - } - /** - * - * - *
-     * Output only. Stores timing information for executing this build step.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan timing = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The timing. - */ - public com.google.cloudbuild.v1.TimeSpan getTiming() { - if (timingBuilder_ == null) { - return timing_ == null ? com.google.cloudbuild.v1.TimeSpan.getDefaultInstance() : timing_; - } else { - return timingBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Output only. Stores timing information for executing this build step.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan timing = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder setTiming(com.google.cloudbuild.v1.TimeSpan value) { - if (timingBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - timing_ = value; - onChanged(); - } else { - timingBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * Output only. Stores timing information for executing this build step.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan timing = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder setTiming(com.google.cloudbuild.v1.TimeSpan.Builder builderForValue) { - if (timingBuilder_ == null) { - timing_ = builderForValue.build(); - onChanged(); - } else { - timingBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Output only. Stores timing information for executing this build step.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan timing = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder mergeTiming(com.google.cloudbuild.v1.TimeSpan value) { - if (timingBuilder_ == null) { - if (timing_ != null) { - timing_ = - com.google.cloudbuild.v1.TimeSpan.newBuilder(timing_).mergeFrom(value).buildPartial(); - } else { - timing_ = value; - } - onChanged(); - } else { - timingBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * Output only. Stores timing information for executing this build step.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan timing = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder clearTiming() { - if (timingBuilder_ == null) { - timing_ = null; - onChanged(); - } else { - timing_ = null; - timingBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Output only. Stores timing information for executing this build step.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan timing = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public com.google.cloudbuild.v1.TimeSpan.Builder getTimingBuilder() { - - onChanged(); - return getTimingFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Output only. Stores timing information for executing this build step.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan timing = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public com.google.cloudbuild.v1.TimeSpanOrBuilder getTimingOrBuilder() { - if (timingBuilder_ != null) { - return timingBuilder_.getMessageOrBuilder(); - } else { - return timing_ == null ? com.google.cloudbuild.v1.TimeSpan.getDefaultInstance() : timing_; - } - } - /** - * - * - *
-     * Output only. Stores timing information for executing this build step.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan timing = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.TimeSpan, - com.google.cloudbuild.v1.TimeSpan.Builder, - com.google.cloudbuild.v1.TimeSpanOrBuilder> - getTimingFieldBuilder() { - if (timingBuilder_ == null) { - timingBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.TimeSpan, - com.google.cloudbuild.v1.TimeSpan.Builder, - com.google.cloudbuild.v1.TimeSpanOrBuilder>( - getTiming(), getParentForChildren(), isClean()); - timing_ = null; - } - return timingBuilder_; - } - - private com.google.cloudbuild.v1.TimeSpan pullTiming_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.TimeSpan, - com.google.cloudbuild.v1.TimeSpan.Builder, - com.google.cloudbuild.v1.TimeSpanOrBuilder> - pullTimingBuilder_; - /** - * - * - *
-     * Output only. Stores timing information for pulling this build step's
-     * builder image only.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan pull_timing = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return Whether the pullTiming field is set. - */ - public boolean hasPullTiming() { - return pullTimingBuilder_ != null || pullTiming_ != null; - } - /** - * - * - *
-     * Output only. Stores timing information for pulling this build step's
-     * builder image only.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan pull_timing = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The pullTiming. - */ - public com.google.cloudbuild.v1.TimeSpan getPullTiming() { - if (pullTimingBuilder_ == null) { - return pullTiming_ == null - ? com.google.cloudbuild.v1.TimeSpan.getDefaultInstance() - : pullTiming_; - } else { - return pullTimingBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Output only. Stores timing information for pulling this build step's
-     * builder image only.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan pull_timing = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder setPullTiming(com.google.cloudbuild.v1.TimeSpan value) { - if (pullTimingBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - pullTiming_ = value; - onChanged(); - } else { - pullTimingBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * Output only. Stores timing information for pulling this build step's
-     * builder image only.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan pull_timing = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder setPullTiming(com.google.cloudbuild.v1.TimeSpan.Builder builderForValue) { - if (pullTimingBuilder_ == null) { - pullTiming_ = builderForValue.build(); - onChanged(); - } else { - pullTimingBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Output only. Stores timing information for pulling this build step's
-     * builder image only.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan pull_timing = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder mergePullTiming(com.google.cloudbuild.v1.TimeSpan value) { - if (pullTimingBuilder_ == null) { - if (pullTiming_ != null) { - pullTiming_ = - com.google.cloudbuild.v1.TimeSpan.newBuilder(pullTiming_) - .mergeFrom(value) - .buildPartial(); - } else { - pullTiming_ = value; - } - onChanged(); - } else { - pullTimingBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * Output only. Stores timing information for pulling this build step's
-     * builder image only.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan pull_timing = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder clearPullTiming() { - if (pullTimingBuilder_ == null) { - pullTiming_ = null; - onChanged(); - } else { - pullTiming_ = null; - pullTimingBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Output only. Stores timing information for pulling this build step's
-     * builder image only.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan pull_timing = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public com.google.cloudbuild.v1.TimeSpan.Builder getPullTimingBuilder() { - - onChanged(); - return getPullTimingFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Output only. Stores timing information for pulling this build step's
-     * builder image only.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan pull_timing = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public com.google.cloudbuild.v1.TimeSpanOrBuilder getPullTimingOrBuilder() { - if (pullTimingBuilder_ != null) { - return pullTimingBuilder_.getMessageOrBuilder(); - } else { - return pullTiming_ == null - ? com.google.cloudbuild.v1.TimeSpan.getDefaultInstance() - : pullTiming_; - } - } - /** - * - * - *
-     * Output only. Stores timing information for pulling this build step's
-     * builder image only.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan pull_timing = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.TimeSpan, - com.google.cloudbuild.v1.TimeSpan.Builder, - com.google.cloudbuild.v1.TimeSpanOrBuilder> - getPullTimingFieldBuilder() { - if (pullTimingBuilder_ == null) { - pullTimingBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.TimeSpan, - com.google.cloudbuild.v1.TimeSpan.Builder, - com.google.cloudbuild.v1.TimeSpanOrBuilder>( - getPullTiming(), getParentForChildren(), isClean()); - pullTiming_ = null; - } - return pullTimingBuilder_; - } - - private com.google.protobuf.Duration timeout_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Duration, - com.google.protobuf.Duration.Builder, - com.google.protobuf.DurationOrBuilder> - timeoutBuilder_; - /** - * - * - *
-     * Time limit for executing this build step. If not defined, the step has no
-     * time limit and will be allowed to continue to run until either it completes
-     * or the build itself times out.
-     * 
- * - * .google.protobuf.Duration timeout = 11; - * - * @return Whether the timeout field is set. - */ - public boolean hasTimeout() { - return timeoutBuilder_ != null || timeout_ != null; - } - /** - * - * - *
-     * Time limit for executing this build step. If not defined, the step has no
-     * time limit and will be allowed to continue to run until either it completes
-     * or the build itself times out.
-     * 
- * - * .google.protobuf.Duration timeout = 11; - * - * @return The timeout. - */ - public com.google.protobuf.Duration getTimeout() { - if (timeoutBuilder_ == null) { - return timeout_ == null ? com.google.protobuf.Duration.getDefaultInstance() : timeout_; - } else { - return timeoutBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Time limit for executing this build step. If not defined, the step has no
-     * time limit and will be allowed to continue to run until either it completes
-     * or the build itself times out.
-     * 
- * - * .google.protobuf.Duration timeout = 11; - */ - public Builder setTimeout(com.google.protobuf.Duration value) { - if (timeoutBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - timeout_ = value; - onChanged(); - } else { - timeoutBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * Time limit for executing this build step. If not defined, the step has no
-     * time limit and will be allowed to continue to run until either it completes
-     * or the build itself times out.
-     * 
- * - * .google.protobuf.Duration timeout = 11; - */ - public Builder setTimeout(com.google.protobuf.Duration.Builder builderForValue) { - if (timeoutBuilder_ == null) { - timeout_ = builderForValue.build(); - onChanged(); - } else { - timeoutBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Time limit for executing this build step. If not defined, the step has no
-     * time limit and will be allowed to continue to run until either it completes
-     * or the build itself times out.
-     * 
- * - * .google.protobuf.Duration timeout = 11; - */ - public Builder mergeTimeout(com.google.protobuf.Duration value) { - if (timeoutBuilder_ == null) { - if (timeout_ != null) { - timeout_ = - com.google.protobuf.Duration.newBuilder(timeout_).mergeFrom(value).buildPartial(); - } else { - timeout_ = value; - } - onChanged(); - } else { - timeoutBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * Time limit for executing this build step. If not defined, the step has no
-     * time limit and will be allowed to continue to run until either it completes
-     * or the build itself times out.
-     * 
- * - * .google.protobuf.Duration timeout = 11; - */ - public Builder clearTimeout() { - if (timeoutBuilder_ == null) { - timeout_ = null; - onChanged(); - } else { - timeout_ = null; - timeoutBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Time limit for executing this build step. If not defined, the step has no
-     * time limit and will be allowed to continue to run until either it completes
-     * or the build itself times out.
-     * 
- * - * .google.protobuf.Duration timeout = 11; - */ - public com.google.protobuf.Duration.Builder getTimeoutBuilder() { - - onChanged(); - return getTimeoutFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Time limit for executing this build step. If not defined, the step has no
-     * time limit and will be allowed to continue to run until either it completes
-     * or the build itself times out.
-     * 
- * - * .google.protobuf.Duration timeout = 11; - */ - public com.google.protobuf.DurationOrBuilder getTimeoutOrBuilder() { - if (timeoutBuilder_ != null) { - return timeoutBuilder_.getMessageOrBuilder(); - } else { - return timeout_ == null ? com.google.protobuf.Duration.getDefaultInstance() : timeout_; - } - } - /** - * - * - *
-     * Time limit for executing this build step. If not defined, the step has no
-     * time limit and will be allowed to continue to run until either it completes
-     * or the build itself times out.
-     * 
- * - * .google.protobuf.Duration timeout = 11; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Duration, - com.google.protobuf.Duration.Builder, - com.google.protobuf.DurationOrBuilder> - getTimeoutFieldBuilder() { - if (timeoutBuilder_ == null) { - timeoutBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Duration, - com.google.protobuf.Duration.Builder, - com.google.protobuf.DurationOrBuilder>( - getTimeout(), getParentForChildren(), isClean()); - timeout_ = null; - } - return timeoutBuilder_; - } - - private int status_ = 0; - /** - * - * - *
-     * Output only. Status of the build step. At this time, build step status is
-     * only updated on build completion; step status is not updated in real-time
-     * as the build progresses.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.Build.Status status = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The enum numeric value on the wire for status. - */ - @java.lang.Override - public int getStatusValue() { - return status_; - } - /** - * - * - *
-     * Output only. Status of the build step. At this time, build step status is
-     * only updated on build completion; step status is not updated in real-time
-     * as the build progresses.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.Build.Status status = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @param value The enum numeric value on the wire for status to set. - * @return This builder for chaining. - */ - public Builder setStatusValue(int value) { - - status_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. Status of the build step. At this time, build step status is
-     * only updated on build completion; step status is not updated in real-time
-     * as the build progresses.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.Build.Status status = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The status. - */ - @java.lang.Override - public com.google.cloudbuild.v1.Build.Status getStatus() { - @SuppressWarnings("deprecation") - com.google.cloudbuild.v1.Build.Status result = - com.google.cloudbuild.v1.Build.Status.valueOf(status_); - return result == null ? com.google.cloudbuild.v1.Build.Status.UNRECOGNIZED : result; - } - /** - * - * - *
-     * Output only. Status of the build step. At this time, build step status is
-     * only updated on build completion; step status is not updated in real-time
-     * as the build progresses.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.Build.Status status = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @param value The status to set. - * @return This builder for chaining. - */ - public Builder setStatus(com.google.cloudbuild.v1.Build.Status value) { - if (value == null) { - throw new NullPointerException(); - } - - status_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. Status of the build step. At this time, build step status is
-     * only updated on build completion; step status is not updated in real-time
-     * as the build progresses.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.Build.Status status = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return This builder for chaining. - */ - public Builder clearStatus() { - - status_ = 0; - onChanged(); - return this; - } - - private java.lang.Object script_ = ""; - /** - * - * - *
-     * A shell script to be executed in the step.
-     * When script is provided, the user cannot specify the entrypoint or args.
-     * 
- * - * string script = 19; - * - * @return The script. - */ - public java.lang.String getScript() { - java.lang.Object ref = script_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - script_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * A shell script to be executed in the step.
-     * When script is provided, the user cannot specify the entrypoint or args.
-     * 
- * - * string script = 19; - * - * @return The bytes for script. - */ - public com.google.protobuf.ByteString getScriptBytes() { - java.lang.Object ref = script_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - script_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * A shell script to be executed in the step.
-     * When script is provided, the user cannot specify the entrypoint or args.
-     * 
- * - * string script = 19; - * - * @param value The script to set. - * @return This builder for chaining. - */ - public Builder setScript(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - script_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * A shell script to be executed in the step.
-     * When script is provided, the user cannot specify the entrypoint or args.
-     * 
- * - * string script = 19; - * - * @return This builder for chaining. - */ - public Builder clearScript() { - - script_ = getDefaultInstance().getScript(); - onChanged(); - return this; - } - /** - * - * - *
-     * A shell script to be executed in the step.
-     * When script is provided, the user cannot specify the entrypoint or args.
-     * 
- * - * string script = 19; - * - * @param value The bytes for script to set. - * @return This builder for chaining. - */ - public Builder setScriptBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - script_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.BuildStep) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.BuildStep) - private static final com.google.cloudbuild.v1.BuildStep DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.BuildStep(); - } - - public static com.google.cloudbuild.v1.BuildStep getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public BuildStep parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.BuildStep getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildStepOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildStepOrBuilder.java deleted file mode 100644 index 30624b22..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildStepOrBuilder.java +++ /dev/null @@ -1,683 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface BuildStepOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.BuildStep) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * Required. The name of the container image that will run this particular
-   * build step.
-   * If the image is available in the host's Docker daemon's cache, it
-   * will be run directly. If not, the host will attempt to pull the image
-   * first, using the builder service account's credentials if necessary.
-   * The Docker daemon's cache will already have the latest versions of all of
-   * the officially supported build steps
-   * ([https://github.com/GoogleCloudPlatform/cloud-builders](https://github.com/GoogleCloudPlatform/cloud-builders)).
-   * The Docker daemon will also have cached many of the layers for some popular
-   * images, like "ubuntu", "debian", but they will be refreshed at the time you
-   * attempt to use them.
-   * If you built an image in a previous build step, it will be stored in the
-   * host's Docker daemon's cache and is available to use as the name for a
-   * later build step.
-   * 
- * - * string name = 1; - * - * @return The name. - */ - java.lang.String getName(); - /** - * - * - *
-   * Required. The name of the container image that will run this particular
-   * build step.
-   * If the image is available in the host's Docker daemon's cache, it
-   * will be run directly. If not, the host will attempt to pull the image
-   * first, using the builder service account's credentials if necessary.
-   * The Docker daemon's cache will already have the latest versions of all of
-   * the officially supported build steps
-   * ([https://github.com/GoogleCloudPlatform/cloud-builders](https://github.com/GoogleCloudPlatform/cloud-builders)).
-   * The Docker daemon will also have cached many of the layers for some popular
-   * images, like "ubuntu", "debian", but they will be refreshed at the time you
-   * attempt to use them.
-   * If you built an image in a previous build step, it will be stored in the
-   * host's Docker daemon's cache and is available to use as the name for a
-   * later build step.
-   * 
- * - * string name = 1; - * - * @return The bytes for name. - */ - com.google.protobuf.ByteString getNameBytes(); - - /** - * - * - *
-   * A list of environment variable definitions to be used when running a step.
-   * The elements are of the form "KEY=VALUE" for the environment variable "KEY"
-   * being given the value "VALUE".
-   * 
- * - * repeated string env = 2; - * - * @return A list containing the env. - */ - java.util.List getEnvList(); - /** - * - * - *
-   * A list of environment variable definitions to be used when running a step.
-   * The elements are of the form "KEY=VALUE" for the environment variable "KEY"
-   * being given the value "VALUE".
-   * 
- * - * repeated string env = 2; - * - * @return The count of env. - */ - int getEnvCount(); - /** - * - * - *
-   * A list of environment variable definitions to be used when running a step.
-   * The elements are of the form "KEY=VALUE" for the environment variable "KEY"
-   * being given the value "VALUE".
-   * 
- * - * repeated string env = 2; - * - * @param index The index of the element to return. - * @return The env at the given index. - */ - java.lang.String getEnv(int index); - /** - * - * - *
-   * A list of environment variable definitions to be used when running a step.
-   * The elements are of the form "KEY=VALUE" for the environment variable "KEY"
-   * being given the value "VALUE".
-   * 
- * - * repeated string env = 2; - * - * @param index The index of the value to return. - * @return The bytes of the env at the given index. - */ - com.google.protobuf.ByteString getEnvBytes(int index); - - /** - * - * - *
-   * A list of arguments that will be presented to the step when it is started.
-   * If the image used to run the step's container has an entrypoint, the `args`
-   * are used as arguments to that entrypoint. If the image does not define
-   * an entrypoint, the first element in args is used as the entrypoint,
-   * and the remainder will be used as arguments.
-   * 
- * - * repeated string args = 3; - * - * @return A list containing the args. - */ - java.util.List getArgsList(); - /** - * - * - *
-   * A list of arguments that will be presented to the step when it is started.
-   * If the image used to run the step's container has an entrypoint, the `args`
-   * are used as arguments to that entrypoint. If the image does not define
-   * an entrypoint, the first element in args is used as the entrypoint,
-   * and the remainder will be used as arguments.
-   * 
- * - * repeated string args = 3; - * - * @return The count of args. - */ - int getArgsCount(); - /** - * - * - *
-   * A list of arguments that will be presented to the step when it is started.
-   * If the image used to run the step's container has an entrypoint, the `args`
-   * are used as arguments to that entrypoint. If the image does not define
-   * an entrypoint, the first element in args is used as the entrypoint,
-   * and the remainder will be used as arguments.
-   * 
- * - * repeated string args = 3; - * - * @param index The index of the element to return. - * @return The args at the given index. - */ - java.lang.String getArgs(int index); - /** - * - * - *
-   * A list of arguments that will be presented to the step when it is started.
-   * If the image used to run the step's container has an entrypoint, the `args`
-   * are used as arguments to that entrypoint. If the image does not define
-   * an entrypoint, the first element in args is used as the entrypoint,
-   * and the remainder will be used as arguments.
-   * 
- * - * repeated string args = 3; - * - * @param index The index of the value to return. - * @return The bytes of the args at the given index. - */ - com.google.protobuf.ByteString getArgsBytes(int index); - - /** - * - * - *
-   * Working directory to use when running this step's container.
-   * If this value is a relative path, it is relative to the build's working
-   * directory. If this value is absolute, it may be outside the build's working
-   * directory, in which case the contents of the path may not be persisted
-   * across build step executions, unless a `volume` for that path is specified.
-   * If the build specifies a `RepoSource` with `dir` and a step with a `dir`,
-   * which specifies an absolute path, the `RepoSource` `dir` is ignored for
-   * the step's execution.
-   * 
- * - * string dir = 4; - * - * @return The dir. - */ - java.lang.String getDir(); - /** - * - * - *
-   * Working directory to use when running this step's container.
-   * If this value is a relative path, it is relative to the build's working
-   * directory. If this value is absolute, it may be outside the build's working
-   * directory, in which case the contents of the path may not be persisted
-   * across build step executions, unless a `volume` for that path is specified.
-   * If the build specifies a `RepoSource` with `dir` and a step with a `dir`,
-   * which specifies an absolute path, the `RepoSource` `dir` is ignored for
-   * the step's execution.
-   * 
- * - * string dir = 4; - * - * @return The bytes for dir. - */ - com.google.protobuf.ByteString getDirBytes(); - - /** - * - * - *
-   * Unique identifier for this build step, used in `wait_for` to
-   * reference this build step as a dependency.
-   * 
- * - * string id = 5; - * - * @return The id. - */ - java.lang.String getId(); - /** - * - * - *
-   * Unique identifier for this build step, used in `wait_for` to
-   * reference this build step as a dependency.
-   * 
- * - * string id = 5; - * - * @return The bytes for id. - */ - com.google.protobuf.ByteString getIdBytes(); - - /** - * - * - *
-   * The ID(s) of the step(s) that this build step depends on.
-   * This build step will not start until all the build steps in `wait_for`
-   * have completed successfully. If `wait_for` is empty, this build step will
-   * start when all previous build steps in the `Build.Steps` list have
-   * completed successfully.
-   * 
- * - * repeated string wait_for = 6; - * - * @return A list containing the waitFor. - */ - java.util.List getWaitForList(); - /** - * - * - *
-   * The ID(s) of the step(s) that this build step depends on.
-   * This build step will not start until all the build steps in `wait_for`
-   * have completed successfully. If `wait_for` is empty, this build step will
-   * start when all previous build steps in the `Build.Steps` list have
-   * completed successfully.
-   * 
- * - * repeated string wait_for = 6; - * - * @return The count of waitFor. - */ - int getWaitForCount(); - /** - * - * - *
-   * The ID(s) of the step(s) that this build step depends on.
-   * This build step will not start until all the build steps in `wait_for`
-   * have completed successfully. If `wait_for` is empty, this build step will
-   * start when all previous build steps in the `Build.Steps` list have
-   * completed successfully.
-   * 
- * - * repeated string wait_for = 6; - * - * @param index The index of the element to return. - * @return The waitFor at the given index. - */ - java.lang.String getWaitFor(int index); - /** - * - * - *
-   * The ID(s) of the step(s) that this build step depends on.
-   * This build step will not start until all the build steps in `wait_for`
-   * have completed successfully. If `wait_for` is empty, this build step will
-   * start when all previous build steps in the `Build.Steps` list have
-   * completed successfully.
-   * 
- * - * repeated string wait_for = 6; - * - * @param index The index of the value to return. - * @return The bytes of the waitFor at the given index. - */ - com.google.protobuf.ByteString getWaitForBytes(int index); - - /** - * - * - *
-   * Entrypoint to be used instead of the build step image's default entrypoint.
-   * If unset, the image's default entrypoint is used.
-   * 
- * - * string entrypoint = 7; - * - * @return The entrypoint. - */ - java.lang.String getEntrypoint(); - /** - * - * - *
-   * Entrypoint to be used instead of the build step image's default entrypoint.
-   * If unset, the image's default entrypoint is used.
-   * 
- * - * string entrypoint = 7; - * - * @return The bytes for entrypoint. - */ - com.google.protobuf.ByteString getEntrypointBytes(); - - /** - * - * - *
-   * A list of environment variables which are encrypted using a Cloud Key
-   * Management Service crypto key. These values must be specified in the
-   * build's `Secret`.
-   * 
- * - * repeated string secret_env = 8; - * - * @return A list containing the secretEnv. - */ - java.util.List getSecretEnvList(); - /** - * - * - *
-   * A list of environment variables which are encrypted using a Cloud Key
-   * Management Service crypto key. These values must be specified in the
-   * build's `Secret`.
-   * 
- * - * repeated string secret_env = 8; - * - * @return The count of secretEnv. - */ - int getSecretEnvCount(); - /** - * - * - *
-   * A list of environment variables which are encrypted using a Cloud Key
-   * Management Service crypto key. These values must be specified in the
-   * build's `Secret`.
-   * 
- * - * repeated string secret_env = 8; - * - * @param index The index of the element to return. - * @return The secretEnv at the given index. - */ - java.lang.String getSecretEnv(int index); - /** - * - * - *
-   * A list of environment variables which are encrypted using a Cloud Key
-   * Management Service crypto key. These values must be specified in the
-   * build's `Secret`.
-   * 
- * - * repeated string secret_env = 8; - * - * @param index The index of the value to return. - * @return The bytes of the secretEnv at the given index. - */ - com.google.protobuf.ByteString getSecretEnvBytes(int index); - - /** - * - * - *
-   * List of volumes to mount into the build step.
-   * Each volume is created as an empty volume prior to execution of the
-   * build step. Upon completion of the build, volumes and their contents are
-   * discarded.
-   * Using a named volume in only one step is not valid as it is indicative
-   * of a build request with an incorrect configuration.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 9; - */ - java.util.List getVolumesList(); - /** - * - * - *
-   * List of volumes to mount into the build step.
-   * Each volume is created as an empty volume prior to execution of the
-   * build step. Upon completion of the build, volumes and their contents are
-   * discarded.
-   * Using a named volume in only one step is not valid as it is indicative
-   * of a build request with an incorrect configuration.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 9; - */ - com.google.cloudbuild.v1.Volume getVolumes(int index); - /** - * - * - *
-   * List of volumes to mount into the build step.
-   * Each volume is created as an empty volume prior to execution of the
-   * build step. Upon completion of the build, volumes and their contents are
-   * discarded.
-   * Using a named volume in only one step is not valid as it is indicative
-   * of a build request with an incorrect configuration.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 9; - */ - int getVolumesCount(); - /** - * - * - *
-   * List of volumes to mount into the build step.
-   * Each volume is created as an empty volume prior to execution of the
-   * build step. Upon completion of the build, volumes and their contents are
-   * discarded.
-   * Using a named volume in only one step is not valid as it is indicative
-   * of a build request with an incorrect configuration.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 9; - */ - java.util.List getVolumesOrBuilderList(); - /** - * - * - *
-   * List of volumes to mount into the build step.
-   * Each volume is created as an empty volume prior to execution of the
-   * build step. Upon completion of the build, volumes and their contents are
-   * discarded.
-   * Using a named volume in only one step is not valid as it is indicative
-   * of a build request with an incorrect configuration.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Volume volumes = 9; - */ - com.google.cloudbuild.v1.VolumeOrBuilder getVolumesOrBuilder(int index); - - /** - * - * - *
-   * Output only. Stores timing information for executing this build step.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan timing = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return Whether the timing field is set. - */ - boolean hasTiming(); - /** - * - * - *
-   * Output only. Stores timing information for executing this build step.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan timing = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The timing. - */ - com.google.cloudbuild.v1.TimeSpan getTiming(); - /** - * - * - *
-   * Output only. Stores timing information for executing this build step.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan timing = 10 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - com.google.cloudbuild.v1.TimeSpanOrBuilder getTimingOrBuilder(); - - /** - * - * - *
-   * Output only. Stores timing information for pulling this build step's
-   * builder image only.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan pull_timing = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return Whether the pullTiming field is set. - */ - boolean hasPullTiming(); - /** - * - * - *
-   * Output only. Stores timing information for pulling this build step's
-   * builder image only.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan pull_timing = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The pullTiming. - */ - com.google.cloudbuild.v1.TimeSpan getPullTiming(); - /** - * - * - *
-   * Output only. Stores timing information for pulling this build step's
-   * builder image only.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan pull_timing = 13 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - com.google.cloudbuild.v1.TimeSpanOrBuilder getPullTimingOrBuilder(); - - /** - * - * - *
-   * Time limit for executing this build step. If not defined, the step has no
-   * time limit and will be allowed to continue to run until either it completes
-   * or the build itself times out.
-   * 
- * - * .google.protobuf.Duration timeout = 11; - * - * @return Whether the timeout field is set. - */ - boolean hasTimeout(); - /** - * - * - *
-   * Time limit for executing this build step. If not defined, the step has no
-   * time limit and will be allowed to continue to run until either it completes
-   * or the build itself times out.
-   * 
- * - * .google.protobuf.Duration timeout = 11; - * - * @return The timeout. - */ - com.google.protobuf.Duration getTimeout(); - /** - * - * - *
-   * Time limit for executing this build step. If not defined, the step has no
-   * time limit and will be allowed to continue to run until either it completes
-   * or the build itself times out.
-   * 
- * - * .google.protobuf.Duration timeout = 11; - */ - com.google.protobuf.DurationOrBuilder getTimeoutOrBuilder(); - - /** - * - * - *
-   * Output only. Status of the build step. At this time, build step status is
-   * only updated on build completion; step status is not updated in real-time
-   * as the build progresses.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.Build.Status status = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The enum numeric value on the wire for status. - */ - int getStatusValue(); - /** - * - * - *
-   * Output only. Status of the build step. At this time, build step status is
-   * only updated on build completion; step status is not updated in real-time
-   * as the build progresses.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.Build.Status status = 12 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The status. - */ - com.google.cloudbuild.v1.Build.Status getStatus(); - - /** - * - * - *
-   * A shell script to be executed in the step.
-   * When script is provided, the user cannot specify the entrypoint or args.
-   * 
- * - * string script = 19; - * - * @return The script. - */ - java.lang.String getScript(); - /** - * - * - *
-   * A shell script to be executed in the step.
-   * When script is provided, the user cannot specify the entrypoint or args.
-   * 
- * - * string script = 19; - * - * @return The bytes for script. - */ - com.google.protobuf.ByteString getScriptBytes(); -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildTrigger.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildTrigger.java deleted file mode 100644 index 114dc76a..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildTrigger.java +++ /dev/null @@ -1,5207 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * Configuration for an automated build in response to source repository
- * changes.
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.BuildTrigger} - */ -public final class BuildTrigger extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.BuildTrigger) - BuildTriggerOrBuilder { - private static final long serialVersionUID = 0L; - // Use BuildTrigger.newBuilder() to construct. - private BuildTrigger(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private BuildTrigger() { - resourceName_ = ""; - id_ = ""; - description_ = ""; - name_ = ""; - tags_ = com.google.protobuf.LazyStringArrayList.EMPTY; - ignoredFiles_ = com.google.protobuf.LazyStringArrayList.EMPTY; - includedFiles_ = com.google.protobuf.LazyStringArrayList.EMPTY; - filter_ = ""; - serviceAccount_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new BuildTrigger(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_BuildTrigger_descriptor; - } - - @SuppressWarnings({"rawtypes"}) - @java.lang.Override - protected com.google.protobuf.MapField internalGetMapField(int number) { - switch (number) { - case 11: - return internalGetSubstitutions(); - default: - throw new RuntimeException("Invalid map field number: " + number); - } - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_BuildTrigger_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.BuildTrigger.class, - com.google.cloudbuild.v1.BuildTrigger.Builder.class); - } - - private int buildTemplateCase_ = 0; - private java.lang.Object buildTemplate_; - - public enum BuildTemplateCase - implements - com.google.protobuf.Internal.EnumLite, - com.google.protobuf.AbstractMessage.InternalOneOfEnum { - AUTODETECT(18), - BUILD(4), - FILENAME(8), - BUILDTEMPLATE_NOT_SET(0); - private final int value; - - private BuildTemplateCase(int value) { - this.value = value; - } - /** - * @param value The number of the enum to look for. - * @return The enum associated with the given number. - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static BuildTemplateCase valueOf(int value) { - return forNumber(value); - } - - public static BuildTemplateCase forNumber(int value) { - switch (value) { - case 18: - return AUTODETECT; - case 4: - return BUILD; - case 8: - return FILENAME; - case 0: - return BUILDTEMPLATE_NOT_SET; - default: - return null; - } - } - - public int getNumber() { - return this.value; - } - }; - - public BuildTemplateCase getBuildTemplateCase() { - return BuildTemplateCase.forNumber(buildTemplateCase_); - } - - public static final int RESOURCE_NAME_FIELD_NUMBER = 34; - private volatile java.lang.Object resourceName_; - /** - * - * - *
-   * The `Trigger` name with format:
-   * `projects/{project}/locations/{location}/triggers/{trigger}`, where
-   * {trigger} is a unique identifier generated by the service.
-   * 
- * - * string resource_name = 34; - * - * @return The resourceName. - */ - @java.lang.Override - public java.lang.String getResourceName() { - java.lang.Object ref = resourceName_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - resourceName_ = s; - return s; - } - } - /** - * - * - *
-   * The `Trigger` name with format:
-   * `projects/{project}/locations/{location}/triggers/{trigger}`, where
-   * {trigger} is a unique identifier generated by the service.
-   * 
- * - * string resource_name = 34; - * - * @return The bytes for resourceName. - */ - @java.lang.Override - public com.google.protobuf.ByteString getResourceNameBytes() { - java.lang.Object ref = resourceName_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - resourceName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int ID_FIELD_NUMBER = 1; - private volatile java.lang.Object id_; - /** - * - * - *
-   * Output only. Unique identifier of the trigger.
-   * 
- * - * string id = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The id. - */ - @java.lang.Override - public java.lang.String getId() { - java.lang.Object ref = id_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - id_ = s; - return s; - } - } - /** - * - * - *
-   * Output only. Unique identifier of the trigger.
-   * 
- * - * string id = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The bytes for id. - */ - @java.lang.Override - public com.google.protobuf.ByteString getIdBytes() { - java.lang.Object ref = id_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - id_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int DESCRIPTION_FIELD_NUMBER = 10; - private volatile java.lang.Object description_; - /** - * - * - *
-   * Human-readable description of this trigger.
-   * 
- * - * string description = 10; - * - * @return The description. - */ - @java.lang.Override - public java.lang.String getDescription() { - java.lang.Object ref = description_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - description_ = s; - return s; - } - } - /** - * - * - *
-   * Human-readable description of this trigger.
-   * 
- * - * string description = 10; - * - * @return The bytes for description. - */ - @java.lang.Override - public com.google.protobuf.ByteString getDescriptionBytes() { - java.lang.Object ref = description_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - description_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int NAME_FIELD_NUMBER = 21; - private volatile java.lang.Object name_; - /** - * - * - *
-   * User-assigned name of the trigger. Must be unique within the project.
-   * Trigger names must meet the following requirements:
-   * + They must contain only alphanumeric characters and dashes.
-   * + They can be 1-64 characters long.
-   * + They must begin and end with an alphanumeric character.
-   * 
- * - * string name = 21; - * - * @return The name. - */ - @java.lang.Override - public java.lang.String getName() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - name_ = s; - return s; - } - } - /** - * - * - *
-   * User-assigned name of the trigger. Must be unique within the project.
-   * Trigger names must meet the following requirements:
-   * + They must contain only alphanumeric characters and dashes.
-   * + They can be 1-64 characters long.
-   * + They must begin and end with an alphanumeric character.
-   * 
- * - * string name = 21; - * - * @return The bytes for name. - */ - @java.lang.Override - public com.google.protobuf.ByteString getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int TAGS_FIELD_NUMBER = 19; - private com.google.protobuf.LazyStringList tags_; - /** - * - * - *
-   * Tags for annotation of a `BuildTrigger`
-   * 
- * - * repeated string tags = 19; - * - * @return A list containing the tags. - */ - public com.google.protobuf.ProtocolStringList getTagsList() { - return tags_; - } - /** - * - * - *
-   * Tags for annotation of a `BuildTrigger`
-   * 
- * - * repeated string tags = 19; - * - * @return The count of tags. - */ - public int getTagsCount() { - return tags_.size(); - } - /** - * - * - *
-   * Tags for annotation of a `BuildTrigger`
-   * 
- * - * repeated string tags = 19; - * - * @param index The index of the element to return. - * @return The tags at the given index. - */ - public java.lang.String getTags(int index) { - return tags_.get(index); - } - /** - * - * - *
-   * Tags for annotation of a `BuildTrigger`
-   * 
- * - * repeated string tags = 19; - * - * @param index The index of the value to return. - * @return The bytes of the tags at the given index. - */ - public com.google.protobuf.ByteString getTagsBytes(int index) { - return tags_.getByteString(index); - } - - public static final int TRIGGER_TEMPLATE_FIELD_NUMBER = 7; - private com.google.cloudbuild.v1.RepoSource triggerTemplate_; - /** - * - * - *
-   * Template describing the types of source changes to trigger a build.
-   * Branch and tag names in trigger templates are interpreted as regular
-   * expressions. Any branch or tag change that matches that regular expression
-   * will trigger a build.
-   * Mutually exclusive with `github`.
-   * 
- * - * .google.devtools.cloudbuild.v1.RepoSource trigger_template = 7; - * - * @return Whether the triggerTemplate field is set. - */ - @java.lang.Override - public boolean hasTriggerTemplate() { - return triggerTemplate_ != null; - } - /** - * - * - *
-   * Template describing the types of source changes to trigger a build.
-   * Branch and tag names in trigger templates are interpreted as regular
-   * expressions. Any branch or tag change that matches that regular expression
-   * will trigger a build.
-   * Mutually exclusive with `github`.
-   * 
- * - * .google.devtools.cloudbuild.v1.RepoSource trigger_template = 7; - * - * @return The triggerTemplate. - */ - @java.lang.Override - public com.google.cloudbuild.v1.RepoSource getTriggerTemplate() { - return triggerTemplate_ == null - ? com.google.cloudbuild.v1.RepoSource.getDefaultInstance() - : triggerTemplate_; - } - /** - * - * - *
-   * Template describing the types of source changes to trigger a build.
-   * Branch and tag names in trigger templates are interpreted as regular
-   * expressions. Any branch or tag change that matches that regular expression
-   * will trigger a build.
-   * Mutually exclusive with `github`.
-   * 
- * - * .google.devtools.cloudbuild.v1.RepoSource trigger_template = 7; - */ - @java.lang.Override - public com.google.cloudbuild.v1.RepoSourceOrBuilder getTriggerTemplateOrBuilder() { - return getTriggerTemplate(); - } - - public static final int GITHUB_FIELD_NUMBER = 13; - private com.google.cloudbuild.v1.GitHubEventsConfig github_; - /** - * - * - *
-   * GitHubEventsConfig describes the configuration of a trigger that creates
-   * a build whenever a GitHub event is received.
-   * Mutually exclusive with `trigger_template`.
-   * 
- * - * .google.devtools.cloudbuild.v1.GitHubEventsConfig github = 13; - * - * @return Whether the github field is set. - */ - @java.lang.Override - public boolean hasGithub() { - return github_ != null; - } - /** - * - * - *
-   * GitHubEventsConfig describes the configuration of a trigger that creates
-   * a build whenever a GitHub event is received.
-   * Mutually exclusive with `trigger_template`.
-   * 
- * - * .google.devtools.cloudbuild.v1.GitHubEventsConfig github = 13; - * - * @return The github. - */ - @java.lang.Override - public com.google.cloudbuild.v1.GitHubEventsConfig getGithub() { - return github_ == null - ? com.google.cloudbuild.v1.GitHubEventsConfig.getDefaultInstance() - : github_; - } - /** - * - * - *
-   * GitHubEventsConfig describes the configuration of a trigger that creates
-   * a build whenever a GitHub event is received.
-   * Mutually exclusive with `trigger_template`.
-   * 
- * - * .google.devtools.cloudbuild.v1.GitHubEventsConfig github = 13; - */ - @java.lang.Override - public com.google.cloudbuild.v1.GitHubEventsConfigOrBuilder getGithubOrBuilder() { - return getGithub(); - } - - public static final int PUBSUB_CONFIG_FIELD_NUMBER = 29; - private com.google.cloudbuild.v1.PubsubConfig pubsubConfig_; - /** - * - * - *
-   * PubsubConfig describes the configuration of a trigger that
-   * creates a build whenever a Pub/Sub message is published.
-   * 
- * - * .google.devtools.cloudbuild.v1.PubsubConfig pubsub_config = 29; - * - * @return Whether the pubsubConfig field is set. - */ - @java.lang.Override - public boolean hasPubsubConfig() { - return pubsubConfig_ != null; - } - /** - * - * - *
-   * PubsubConfig describes the configuration of a trigger that
-   * creates a build whenever a Pub/Sub message is published.
-   * 
- * - * .google.devtools.cloudbuild.v1.PubsubConfig pubsub_config = 29; - * - * @return The pubsubConfig. - */ - @java.lang.Override - public com.google.cloudbuild.v1.PubsubConfig getPubsubConfig() { - return pubsubConfig_ == null - ? com.google.cloudbuild.v1.PubsubConfig.getDefaultInstance() - : pubsubConfig_; - } - /** - * - * - *
-   * PubsubConfig describes the configuration of a trigger that
-   * creates a build whenever a Pub/Sub message is published.
-   * 
- * - * .google.devtools.cloudbuild.v1.PubsubConfig pubsub_config = 29; - */ - @java.lang.Override - public com.google.cloudbuild.v1.PubsubConfigOrBuilder getPubsubConfigOrBuilder() { - return getPubsubConfig(); - } - - public static final int WEBHOOK_CONFIG_FIELD_NUMBER = 31; - private com.google.cloudbuild.v1.WebhookConfig webhookConfig_; - /** - * - * - *
-   * WebhookConfig describes the configuration of a trigger that
-   * creates a build whenever a webhook is sent to a trigger's webhook URL.
-   * 
- * - * .google.devtools.cloudbuild.v1.WebhookConfig webhook_config = 31; - * - * @return Whether the webhookConfig field is set. - */ - @java.lang.Override - public boolean hasWebhookConfig() { - return webhookConfig_ != null; - } - /** - * - * - *
-   * WebhookConfig describes the configuration of a trigger that
-   * creates a build whenever a webhook is sent to a trigger's webhook URL.
-   * 
- * - * .google.devtools.cloudbuild.v1.WebhookConfig webhook_config = 31; - * - * @return The webhookConfig. - */ - @java.lang.Override - public com.google.cloudbuild.v1.WebhookConfig getWebhookConfig() { - return webhookConfig_ == null - ? com.google.cloudbuild.v1.WebhookConfig.getDefaultInstance() - : webhookConfig_; - } - /** - * - * - *
-   * WebhookConfig describes the configuration of a trigger that
-   * creates a build whenever a webhook is sent to a trigger's webhook URL.
-   * 
- * - * .google.devtools.cloudbuild.v1.WebhookConfig webhook_config = 31; - */ - @java.lang.Override - public com.google.cloudbuild.v1.WebhookConfigOrBuilder getWebhookConfigOrBuilder() { - return getWebhookConfig(); - } - - public static final int AUTODETECT_FIELD_NUMBER = 18; - /** - * - * - *
-   * Autodetect build configuration.  The following precedence is used (case
-   * insensitive):
-   * 1. cloudbuild.yaml
-   * 2. cloudbuild.yml
-   * 3. cloudbuild.json
-   * 4. Dockerfile
-   * Currently only available for GitHub App Triggers.
-   * 
- * - * bool autodetect = 18; - * - * @return Whether the autodetect field is set. - */ - @java.lang.Override - public boolean hasAutodetect() { - return buildTemplateCase_ == 18; - } - /** - * - * - *
-   * Autodetect build configuration.  The following precedence is used (case
-   * insensitive):
-   * 1. cloudbuild.yaml
-   * 2. cloudbuild.yml
-   * 3. cloudbuild.json
-   * 4. Dockerfile
-   * Currently only available for GitHub App Triggers.
-   * 
- * - * bool autodetect = 18; - * - * @return The autodetect. - */ - @java.lang.Override - public boolean getAutodetect() { - if (buildTemplateCase_ == 18) { - return (java.lang.Boolean) buildTemplate_; - } - return false; - } - - public static final int BUILD_FIELD_NUMBER = 4; - /** - * - * - *
-   * Contents of the build template.
-   * 
- * - * .google.devtools.cloudbuild.v1.Build build = 4; - * - * @return Whether the build field is set. - */ - @java.lang.Override - public boolean hasBuild() { - return buildTemplateCase_ == 4; - } - /** - * - * - *
-   * Contents of the build template.
-   * 
- * - * .google.devtools.cloudbuild.v1.Build build = 4; - * - * @return The build. - */ - @java.lang.Override - public com.google.cloudbuild.v1.Build getBuild() { - if (buildTemplateCase_ == 4) { - return (com.google.cloudbuild.v1.Build) buildTemplate_; - } - return com.google.cloudbuild.v1.Build.getDefaultInstance(); - } - /** - * - * - *
-   * Contents of the build template.
-   * 
- * - * .google.devtools.cloudbuild.v1.Build build = 4; - */ - @java.lang.Override - public com.google.cloudbuild.v1.BuildOrBuilder getBuildOrBuilder() { - if (buildTemplateCase_ == 4) { - return (com.google.cloudbuild.v1.Build) buildTemplate_; - } - return com.google.cloudbuild.v1.Build.getDefaultInstance(); - } - - public static final int FILENAME_FIELD_NUMBER = 8; - /** - * - * - *
-   * Path, from the source root, to the build configuration file
-   * (i.e. cloudbuild.yaml).
-   * 
- * - * string filename = 8; - * - * @return Whether the filename field is set. - */ - public boolean hasFilename() { - return buildTemplateCase_ == 8; - } - /** - * - * - *
-   * Path, from the source root, to the build configuration file
-   * (i.e. cloudbuild.yaml).
-   * 
- * - * string filename = 8; - * - * @return The filename. - */ - public java.lang.String getFilename() { - java.lang.Object ref = ""; - if (buildTemplateCase_ == 8) { - ref = buildTemplate_; - } - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (buildTemplateCase_ == 8) { - buildTemplate_ = s; - } - return s; - } - } - /** - * - * - *
-   * Path, from the source root, to the build configuration file
-   * (i.e. cloudbuild.yaml).
-   * 
- * - * string filename = 8; - * - * @return The bytes for filename. - */ - public com.google.protobuf.ByteString getFilenameBytes() { - java.lang.Object ref = ""; - if (buildTemplateCase_ == 8) { - ref = buildTemplate_; - } - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - if (buildTemplateCase_ == 8) { - buildTemplate_ = b; - } - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int CREATE_TIME_FIELD_NUMBER = 5; - private com.google.protobuf.Timestamp createTime_; - /** - * - * - *
-   * Output only. Time when the trigger was created.
-   * 
- * - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return Whether the createTime field is set. - */ - @java.lang.Override - public boolean hasCreateTime() { - return createTime_ != null; - } - /** - * - * - *
-   * Output only. Time when the trigger was created.
-   * 
- * - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The createTime. - */ - @java.lang.Override - public com.google.protobuf.Timestamp getCreateTime() { - return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; - } - /** - * - * - *
-   * Output only. Time when the trigger was created.
-   * 
- * - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - @java.lang.Override - public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { - return getCreateTime(); - } - - public static final int DISABLED_FIELD_NUMBER = 9; - private boolean disabled_; - /** - * - * - *
-   * If true, the trigger will never automatically execute a build.
-   * 
- * - * bool disabled = 9; - * - * @return The disabled. - */ - @java.lang.Override - public boolean getDisabled() { - return disabled_; - } - - public static final int SUBSTITUTIONS_FIELD_NUMBER = 11; - - private static final class SubstitutionsDefaultEntryHolder { - static final com.google.protobuf.MapEntry defaultEntry = - com.google.protobuf.MapEntry.newDefaultInstance( - com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_BuildTrigger_SubstitutionsEntry_descriptor, - com.google.protobuf.WireFormat.FieldType.STRING, - "", - com.google.protobuf.WireFormat.FieldType.STRING, - ""); - } - - private com.google.protobuf.MapField substitutions_; - - private com.google.protobuf.MapField - internalGetSubstitutions() { - if (substitutions_ == null) { - return com.google.protobuf.MapField.emptyMapField( - SubstitutionsDefaultEntryHolder.defaultEntry); - } - return substitutions_; - } - - public int getSubstitutionsCount() { - return internalGetSubstitutions().getMap().size(); - } - /** - * - * - *
-   * Substitutions for Build resource. The keys must match the following
-   * regular expression: `^_[A-Z0-9_]+$`.
-   * 
- * - * map<string, string> substitutions = 11; - */ - @java.lang.Override - public boolean containsSubstitutions(java.lang.String key) { - if (key == null) { - throw new NullPointerException("map key"); - } - return internalGetSubstitutions().getMap().containsKey(key); - } - /** Use {@link #getSubstitutionsMap()} instead. */ - @java.lang.Override - @java.lang.Deprecated - public java.util.Map getSubstitutions() { - return getSubstitutionsMap(); - } - /** - * - * - *
-   * Substitutions for Build resource. The keys must match the following
-   * regular expression: `^_[A-Z0-9_]+$`.
-   * 
- * - * map<string, string> substitutions = 11; - */ - @java.lang.Override - public java.util.Map getSubstitutionsMap() { - return internalGetSubstitutions().getMap(); - } - /** - * - * - *
-   * Substitutions for Build resource. The keys must match the following
-   * regular expression: `^_[A-Z0-9_]+$`.
-   * 
- * - * map<string, string> substitutions = 11; - */ - @java.lang.Override - public java.lang.String getSubstitutionsOrDefault( - java.lang.String key, java.lang.String defaultValue) { - if (key == null) { - throw new NullPointerException("map key"); - } - java.util.Map map = internalGetSubstitutions().getMap(); - return map.containsKey(key) ? map.get(key) : defaultValue; - } - /** - * - * - *
-   * Substitutions for Build resource. The keys must match the following
-   * regular expression: `^_[A-Z0-9_]+$`.
-   * 
- * - * map<string, string> substitutions = 11; - */ - @java.lang.Override - public java.lang.String getSubstitutionsOrThrow(java.lang.String key) { - if (key == null) { - throw new NullPointerException("map key"); - } - java.util.Map map = internalGetSubstitutions().getMap(); - if (!map.containsKey(key)) { - throw new java.lang.IllegalArgumentException(); - } - return map.get(key); - } - - public static final int IGNORED_FILES_FIELD_NUMBER = 15; - private com.google.protobuf.LazyStringList ignoredFiles_; - /** - * - * - *
-   * ignored_files and included_files are file glob matches using
-   * https://golang.org/pkg/path/filepath/#Match extended with support for "**".
-   * If ignored_files and changed files are both empty, then they are
-   * not used to determine whether or not to trigger a build.
-   * If ignored_files is not empty, then we ignore any files that match
-   * any of the ignored_file globs. If the change has no files that are
-   * outside of the ignored_files globs, then we do not trigger a build.
-   * 
- * - * repeated string ignored_files = 15; - * - * @return A list containing the ignoredFiles. - */ - public com.google.protobuf.ProtocolStringList getIgnoredFilesList() { - return ignoredFiles_; - } - /** - * - * - *
-   * ignored_files and included_files are file glob matches using
-   * https://golang.org/pkg/path/filepath/#Match extended with support for "**".
-   * If ignored_files and changed files are both empty, then they are
-   * not used to determine whether or not to trigger a build.
-   * If ignored_files is not empty, then we ignore any files that match
-   * any of the ignored_file globs. If the change has no files that are
-   * outside of the ignored_files globs, then we do not trigger a build.
-   * 
- * - * repeated string ignored_files = 15; - * - * @return The count of ignoredFiles. - */ - public int getIgnoredFilesCount() { - return ignoredFiles_.size(); - } - /** - * - * - *
-   * ignored_files and included_files are file glob matches using
-   * https://golang.org/pkg/path/filepath/#Match extended with support for "**".
-   * If ignored_files and changed files are both empty, then they are
-   * not used to determine whether or not to trigger a build.
-   * If ignored_files is not empty, then we ignore any files that match
-   * any of the ignored_file globs. If the change has no files that are
-   * outside of the ignored_files globs, then we do not trigger a build.
-   * 
- * - * repeated string ignored_files = 15; - * - * @param index The index of the element to return. - * @return The ignoredFiles at the given index. - */ - public java.lang.String getIgnoredFiles(int index) { - return ignoredFiles_.get(index); - } - /** - * - * - *
-   * ignored_files and included_files are file glob matches using
-   * https://golang.org/pkg/path/filepath/#Match extended with support for "**".
-   * If ignored_files and changed files are both empty, then they are
-   * not used to determine whether or not to trigger a build.
-   * If ignored_files is not empty, then we ignore any files that match
-   * any of the ignored_file globs. If the change has no files that are
-   * outside of the ignored_files globs, then we do not trigger a build.
-   * 
- * - * repeated string ignored_files = 15; - * - * @param index The index of the value to return. - * @return The bytes of the ignoredFiles at the given index. - */ - public com.google.protobuf.ByteString getIgnoredFilesBytes(int index) { - return ignoredFiles_.getByteString(index); - } - - public static final int INCLUDED_FILES_FIELD_NUMBER = 16; - private com.google.protobuf.LazyStringList includedFiles_; - /** - * - * - *
-   * If any of the files altered in the commit pass the ignored_files
-   * filter and included_files is empty, then as far as this filter is
-   * concerned, we should trigger the build.
-   * If any of the files altered in the commit pass the ignored_files
-   * filter and included_files is not empty, then we make sure that at
-   * least one of those files matches a included_files glob. If not,
-   * then we do not trigger a build.
-   * 
- * - * repeated string included_files = 16; - * - * @return A list containing the includedFiles. - */ - public com.google.protobuf.ProtocolStringList getIncludedFilesList() { - return includedFiles_; - } - /** - * - * - *
-   * If any of the files altered in the commit pass the ignored_files
-   * filter and included_files is empty, then as far as this filter is
-   * concerned, we should trigger the build.
-   * If any of the files altered in the commit pass the ignored_files
-   * filter and included_files is not empty, then we make sure that at
-   * least one of those files matches a included_files glob. If not,
-   * then we do not trigger a build.
-   * 
- * - * repeated string included_files = 16; - * - * @return The count of includedFiles. - */ - public int getIncludedFilesCount() { - return includedFiles_.size(); - } - /** - * - * - *
-   * If any of the files altered in the commit pass the ignored_files
-   * filter and included_files is empty, then as far as this filter is
-   * concerned, we should trigger the build.
-   * If any of the files altered in the commit pass the ignored_files
-   * filter and included_files is not empty, then we make sure that at
-   * least one of those files matches a included_files glob. If not,
-   * then we do not trigger a build.
-   * 
- * - * repeated string included_files = 16; - * - * @param index The index of the element to return. - * @return The includedFiles at the given index. - */ - public java.lang.String getIncludedFiles(int index) { - return includedFiles_.get(index); - } - /** - * - * - *
-   * If any of the files altered in the commit pass the ignored_files
-   * filter and included_files is empty, then as far as this filter is
-   * concerned, we should trigger the build.
-   * If any of the files altered in the commit pass the ignored_files
-   * filter and included_files is not empty, then we make sure that at
-   * least one of those files matches a included_files glob. If not,
-   * then we do not trigger a build.
-   * 
- * - * repeated string included_files = 16; - * - * @param index The index of the value to return. - * @return The bytes of the includedFiles at the given index. - */ - public com.google.protobuf.ByteString getIncludedFilesBytes(int index) { - return includedFiles_.getByteString(index); - } - - public static final int FILTER_FIELD_NUMBER = 30; - private volatile java.lang.Object filter_; - /** - * - * - *
-   * Optional. A Common Expression Language string.
-   * 
- * - * string filter = 30 [(.google.api.field_behavior) = OPTIONAL]; - * - * @return The filter. - */ - @java.lang.Override - public java.lang.String getFilter() { - java.lang.Object ref = filter_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - filter_ = s; - return s; - } - } - /** - * - * - *
-   * Optional. A Common Expression Language string.
-   * 
- * - * string filter = 30 [(.google.api.field_behavior) = OPTIONAL]; - * - * @return The bytes for filter. - */ - @java.lang.Override - public com.google.protobuf.ByteString getFilterBytes() { - java.lang.Object ref = filter_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - filter_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int SERVICE_ACCOUNT_FIELD_NUMBER = 33; - private volatile java.lang.Object serviceAccount_; - /** - * - * - *
-   * The service account used for all user-controlled operations including
-   * UpdateBuildTrigger, RunBuildTrigger, CreateBuild, and CancelBuild.
-   * If no service account is set, then the standard Cloud Build service account
-   * ([PROJECT_NUM]@system.gserviceaccount.com) will be used instead.
-   * Format: `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT_ID_OR_EMAIL}`
-   * 
- * - * string service_account = 33 [(.google.api.resource_reference) = { ... } - * - * @return The serviceAccount. - */ - @java.lang.Override - public java.lang.String getServiceAccount() { - java.lang.Object ref = serviceAccount_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - serviceAccount_ = s; - return s; - } - } - /** - * - * - *
-   * The service account used for all user-controlled operations including
-   * UpdateBuildTrigger, RunBuildTrigger, CreateBuild, and CancelBuild.
-   * If no service account is set, then the standard Cloud Build service account
-   * ([PROJECT_NUM]@system.gserviceaccount.com) will be used instead.
-   * Format: `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT_ID_OR_EMAIL}`
-   * 
- * - * string service_account = 33 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for serviceAccount. - */ - @java.lang.Override - public com.google.protobuf.ByteString getServiceAccountBytes() { - java.lang.Object ref = serviceAccount_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - serviceAccount_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(id_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, id_); - } - if (buildTemplateCase_ == 4) { - output.writeMessage(4, (com.google.cloudbuild.v1.Build) buildTemplate_); - } - if (createTime_ != null) { - output.writeMessage(5, getCreateTime()); - } - if (triggerTemplate_ != null) { - output.writeMessage(7, getTriggerTemplate()); - } - if (buildTemplateCase_ == 8) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 8, buildTemplate_); - } - if (disabled_ != false) { - output.writeBool(9, disabled_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(description_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 10, description_); - } - com.google.protobuf.GeneratedMessageV3.serializeStringMapTo( - output, internalGetSubstitutions(), SubstitutionsDefaultEntryHolder.defaultEntry, 11); - if (github_ != null) { - output.writeMessage(13, getGithub()); - } - for (int i = 0; i < ignoredFiles_.size(); i++) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 15, ignoredFiles_.getRaw(i)); - } - for (int i = 0; i < includedFiles_.size(); i++) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 16, includedFiles_.getRaw(i)); - } - if (buildTemplateCase_ == 18) { - output.writeBool(18, (boolean) ((java.lang.Boolean) buildTemplate_)); - } - for (int i = 0; i < tags_.size(); i++) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 19, tags_.getRaw(i)); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 21, name_); - } - if (pubsubConfig_ != null) { - output.writeMessage(29, getPubsubConfig()); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(filter_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 30, filter_); - } - if (webhookConfig_ != null) { - output.writeMessage(31, getWebhookConfig()); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(serviceAccount_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 33, serviceAccount_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(resourceName_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 34, resourceName_); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(id_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, id_); - } - if (buildTemplateCase_ == 4) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 4, (com.google.cloudbuild.v1.Build) buildTemplate_); - } - if (createTime_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(5, getCreateTime()); - } - if (triggerTemplate_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(7, getTriggerTemplate()); - } - if (buildTemplateCase_ == 8) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(8, buildTemplate_); - } - if (disabled_ != false) { - size += com.google.protobuf.CodedOutputStream.computeBoolSize(9, disabled_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(description_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(10, description_); - } - for (java.util.Map.Entry entry : - internalGetSubstitutions().getMap().entrySet()) { - com.google.protobuf.MapEntry substitutions__ = - SubstitutionsDefaultEntryHolder.defaultEntry - .newBuilderForType() - .setKey(entry.getKey()) - .setValue(entry.getValue()) - .build(); - size += com.google.protobuf.CodedOutputStream.computeMessageSize(11, substitutions__); - } - if (github_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(13, getGithub()); - } - { - int dataSize = 0; - for (int i = 0; i < ignoredFiles_.size(); i++) { - dataSize += computeStringSizeNoTag(ignoredFiles_.getRaw(i)); - } - size += dataSize; - size += 1 * getIgnoredFilesList().size(); - } - { - int dataSize = 0; - for (int i = 0; i < includedFiles_.size(); i++) { - dataSize += computeStringSizeNoTag(includedFiles_.getRaw(i)); - } - size += dataSize; - size += 2 * getIncludedFilesList().size(); - } - if (buildTemplateCase_ == 18) { - size += - com.google.protobuf.CodedOutputStream.computeBoolSize( - 18, (boolean) ((java.lang.Boolean) buildTemplate_)); - } - { - int dataSize = 0; - for (int i = 0; i < tags_.size(); i++) { - dataSize += computeStringSizeNoTag(tags_.getRaw(i)); - } - size += dataSize; - size += 2 * getTagsList().size(); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(21, name_); - } - if (pubsubConfig_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(29, getPubsubConfig()); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(filter_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(30, filter_); - } - if (webhookConfig_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(31, getWebhookConfig()); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(serviceAccount_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(33, serviceAccount_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(resourceName_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(34, resourceName_); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.BuildTrigger)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.BuildTrigger other = (com.google.cloudbuild.v1.BuildTrigger) obj; - - if (!getResourceName().equals(other.getResourceName())) return false; - if (!getId().equals(other.getId())) return false; - if (!getDescription().equals(other.getDescription())) return false; - if (!getName().equals(other.getName())) return false; - if (!getTagsList().equals(other.getTagsList())) return false; - if (hasTriggerTemplate() != other.hasTriggerTemplate()) return false; - if (hasTriggerTemplate()) { - if (!getTriggerTemplate().equals(other.getTriggerTemplate())) return false; - } - if (hasGithub() != other.hasGithub()) return false; - if (hasGithub()) { - if (!getGithub().equals(other.getGithub())) return false; - } - if (hasPubsubConfig() != other.hasPubsubConfig()) return false; - if (hasPubsubConfig()) { - if (!getPubsubConfig().equals(other.getPubsubConfig())) return false; - } - if (hasWebhookConfig() != other.hasWebhookConfig()) return false; - if (hasWebhookConfig()) { - if (!getWebhookConfig().equals(other.getWebhookConfig())) return false; - } - if (hasCreateTime() != other.hasCreateTime()) return false; - if (hasCreateTime()) { - if (!getCreateTime().equals(other.getCreateTime())) return false; - } - if (getDisabled() != other.getDisabled()) return false; - if (!internalGetSubstitutions().equals(other.internalGetSubstitutions())) return false; - if (!getIgnoredFilesList().equals(other.getIgnoredFilesList())) return false; - if (!getIncludedFilesList().equals(other.getIncludedFilesList())) return false; - if (!getFilter().equals(other.getFilter())) return false; - if (!getServiceAccount().equals(other.getServiceAccount())) return false; - if (!getBuildTemplateCase().equals(other.getBuildTemplateCase())) return false; - switch (buildTemplateCase_) { - case 18: - if (getAutodetect() != other.getAutodetect()) return false; - break; - case 4: - if (!getBuild().equals(other.getBuild())) return false; - break; - case 8: - if (!getFilename().equals(other.getFilename())) return false; - break; - case 0: - default: - } - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + RESOURCE_NAME_FIELD_NUMBER; - hash = (53 * hash) + getResourceName().hashCode(); - hash = (37 * hash) + ID_FIELD_NUMBER; - hash = (53 * hash) + getId().hashCode(); - hash = (37 * hash) + DESCRIPTION_FIELD_NUMBER; - hash = (53 * hash) + getDescription().hashCode(); - hash = (37 * hash) + NAME_FIELD_NUMBER; - hash = (53 * hash) + getName().hashCode(); - if (getTagsCount() > 0) { - hash = (37 * hash) + TAGS_FIELD_NUMBER; - hash = (53 * hash) + getTagsList().hashCode(); - } - if (hasTriggerTemplate()) { - hash = (37 * hash) + TRIGGER_TEMPLATE_FIELD_NUMBER; - hash = (53 * hash) + getTriggerTemplate().hashCode(); - } - if (hasGithub()) { - hash = (37 * hash) + GITHUB_FIELD_NUMBER; - hash = (53 * hash) + getGithub().hashCode(); - } - if (hasPubsubConfig()) { - hash = (37 * hash) + PUBSUB_CONFIG_FIELD_NUMBER; - hash = (53 * hash) + getPubsubConfig().hashCode(); - } - if (hasWebhookConfig()) { - hash = (37 * hash) + WEBHOOK_CONFIG_FIELD_NUMBER; - hash = (53 * hash) + getWebhookConfig().hashCode(); - } - if (hasCreateTime()) { - hash = (37 * hash) + CREATE_TIME_FIELD_NUMBER; - hash = (53 * hash) + getCreateTime().hashCode(); - } - hash = (37 * hash) + DISABLED_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getDisabled()); - if (!internalGetSubstitutions().getMap().isEmpty()) { - hash = (37 * hash) + SUBSTITUTIONS_FIELD_NUMBER; - hash = (53 * hash) + internalGetSubstitutions().hashCode(); - } - if (getIgnoredFilesCount() > 0) { - hash = (37 * hash) + IGNORED_FILES_FIELD_NUMBER; - hash = (53 * hash) + getIgnoredFilesList().hashCode(); - } - if (getIncludedFilesCount() > 0) { - hash = (37 * hash) + INCLUDED_FILES_FIELD_NUMBER; - hash = (53 * hash) + getIncludedFilesList().hashCode(); - } - hash = (37 * hash) + FILTER_FIELD_NUMBER; - hash = (53 * hash) + getFilter().hashCode(); - hash = (37 * hash) + SERVICE_ACCOUNT_FIELD_NUMBER; - hash = (53 * hash) + getServiceAccount().hashCode(); - switch (buildTemplateCase_) { - case 18: - hash = (37 * hash) + AUTODETECT_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getAutodetect()); - break; - case 4: - hash = (37 * hash) + BUILD_FIELD_NUMBER; - hash = (53 * hash) + getBuild().hashCode(); - break; - case 8: - hash = (37 * hash) + FILENAME_FIELD_NUMBER; - hash = (53 * hash) + getFilename().hashCode(); - break; - case 0: - default: - } - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.BuildTrigger parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.BuildTrigger parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.BuildTrigger parseFrom(com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.BuildTrigger parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.BuildTrigger parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.BuildTrigger parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.BuildTrigger parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.BuildTrigger parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.BuildTrigger parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.BuildTrigger parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.BuildTrigger parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.BuildTrigger parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.BuildTrigger prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * Configuration for an automated build in response to source repository
-   * changes.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.BuildTrigger} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.BuildTrigger) - com.google.cloudbuild.v1.BuildTriggerOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_BuildTrigger_descriptor; - } - - @SuppressWarnings({"rawtypes"}) - protected com.google.protobuf.MapField internalGetMapField(int number) { - switch (number) { - case 11: - return internalGetSubstitutions(); - default: - throw new RuntimeException("Invalid map field number: " + number); - } - } - - @SuppressWarnings({"rawtypes"}) - protected com.google.protobuf.MapField internalGetMutableMapField(int number) { - switch (number) { - case 11: - return internalGetMutableSubstitutions(); - default: - throw new RuntimeException("Invalid map field number: " + number); - } - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_BuildTrigger_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.BuildTrigger.class, - com.google.cloudbuild.v1.BuildTrigger.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.BuildTrigger.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - resourceName_ = ""; - - id_ = ""; - - description_ = ""; - - name_ = ""; - - tags_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000001); - if (triggerTemplateBuilder_ == null) { - triggerTemplate_ = null; - } else { - triggerTemplate_ = null; - triggerTemplateBuilder_ = null; - } - if (githubBuilder_ == null) { - github_ = null; - } else { - github_ = null; - githubBuilder_ = null; - } - if (pubsubConfigBuilder_ == null) { - pubsubConfig_ = null; - } else { - pubsubConfig_ = null; - pubsubConfigBuilder_ = null; - } - if (webhookConfigBuilder_ == null) { - webhookConfig_ = null; - } else { - webhookConfig_ = null; - webhookConfigBuilder_ = null; - } - if (buildBuilder_ != null) { - buildBuilder_.clear(); - } - if (createTimeBuilder_ == null) { - createTime_ = null; - } else { - createTime_ = null; - createTimeBuilder_ = null; - } - disabled_ = false; - - internalGetMutableSubstitutions().clear(); - ignoredFiles_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000004); - includedFiles_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000008); - filter_ = ""; - - serviceAccount_ = ""; - - buildTemplateCase_ = 0; - buildTemplate_ = null; - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_BuildTrigger_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.BuildTrigger getDefaultInstanceForType() { - return com.google.cloudbuild.v1.BuildTrigger.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.BuildTrigger build() { - com.google.cloudbuild.v1.BuildTrigger result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.BuildTrigger buildPartial() { - com.google.cloudbuild.v1.BuildTrigger result = - new com.google.cloudbuild.v1.BuildTrigger(this); - int from_bitField0_ = bitField0_; - result.resourceName_ = resourceName_; - result.id_ = id_; - result.description_ = description_; - result.name_ = name_; - if (((bitField0_ & 0x00000001) != 0)) { - tags_ = tags_.getUnmodifiableView(); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.tags_ = tags_; - if (triggerTemplateBuilder_ == null) { - result.triggerTemplate_ = triggerTemplate_; - } else { - result.triggerTemplate_ = triggerTemplateBuilder_.build(); - } - if (githubBuilder_ == null) { - result.github_ = github_; - } else { - result.github_ = githubBuilder_.build(); - } - if (pubsubConfigBuilder_ == null) { - result.pubsubConfig_ = pubsubConfig_; - } else { - result.pubsubConfig_ = pubsubConfigBuilder_.build(); - } - if (webhookConfigBuilder_ == null) { - result.webhookConfig_ = webhookConfig_; - } else { - result.webhookConfig_ = webhookConfigBuilder_.build(); - } - if (buildTemplateCase_ == 18) { - result.buildTemplate_ = buildTemplate_; - } - if (buildTemplateCase_ == 4) { - if (buildBuilder_ == null) { - result.buildTemplate_ = buildTemplate_; - } else { - result.buildTemplate_ = buildBuilder_.build(); - } - } - if (buildTemplateCase_ == 8) { - result.buildTemplate_ = buildTemplate_; - } - if (createTimeBuilder_ == null) { - result.createTime_ = createTime_; - } else { - result.createTime_ = createTimeBuilder_.build(); - } - result.disabled_ = disabled_; - result.substitutions_ = internalGetSubstitutions(); - result.substitutions_.makeImmutable(); - if (((bitField0_ & 0x00000004) != 0)) { - ignoredFiles_ = ignoredFiles_.getUnmodifiableView(); - bitField0_ = (bitField0_ & ~0x00000004); - } - result.ignoredFiles_ = ignoredFiles_; - if (((bitField0_ & 0x00000008) != 0)) { - includedFiles_ = includedFiles_.getUnmodifiableView(); - bitField0_ = (bitField0_ & ~0x00000008); - } - result.includedFiles_ = includedFiles_; - result.filter_ = filter_; - result.serviceAccount_ = serviceAccount_; - result.buildTemplateCase_ = buildTemplateCase_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.BuildTrigger) { - return mergeFrom((com.google.cloudbuild.v1.BuildTrigger) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.BuildTrigger other) { - if (other == com.google.cloudbuild.v1.BuildTrigger.getDefaultInstance()) return this; - if (!other.getResourceName().isEmpty()) { - resourceName_ = other.resourceName_; - onChanged(); - } - if (!other.getId().isEmpty()) { - id_ = other.id_; - onChanged(); - } - if (!other.getDescription().isEmpty()) { - description_ = other.description_; - onChanged(); - } - if (!other.getName().isEmpty()) { - name_ = other.name_; - onChanged(); - } - if (!other.tags_.isEmpty()) { - if (tags_.isEmpty()) { - tags_ = other.tags_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureTagsIsMutable(); - tags_.addAll(other.tags_); - } - onChanged(); - } - if (other.hasTriggerTemplate()) { - mergeTriggerTemplate(other.getTriggerTemplate()); - } - if (other.hasGithub()) { - mergeGithub(other.getGithub()); - } - if (other.hasPubsubConfig()) { - mergePubsubConfig(other.getPubsubConfig()); - } - if (other.hasWebhookConfig()) { - mergeWebhookConfig(other.getWebhookConfig()); - } - if (other.hasCreateTime()) { - mergeCreateTime(other.getCreateTime()); - } - if (other.getDisabled() != false) { - setDisabled(other.getDisabled()); - } - internalGetMutableSubstitutions().mergeFrom(other.internalGetSubstitutions()); - if (!other.ignoredFiles_.isEmpty()) { - if (ignoredFiles_.isEmpty()) { - ignoredFiles_ = other.ignoredFiles_; - bitField0_ = (bitField0_ & ~0x00000004); - } else { - ensureIgnoredFilesIsMutable(); - ignoredFiles_.addAll(other.ignoredFiles_); - } - onChanged(); - } - if (!other.includedFiles_.isEmpty()) { - if (includedFiles_.isEmpty()) { - includedFiles_ = other.includedFiles_; - bitField0_ = (bitField0_ & ~0x00000008); - } else { - ensureIncludedFilesIsMutable(); - includedFiles_.addAll(other.includedFiles_); - } - onChanged(); - } - if (!other.getFilter().isEmpty()) { - filter_ = other.filter_; - onChanged(); - } - if (!other.getServiceAccount().isEmpty()) { - serviceAccount_ = other.serviceAccount_; - onChanged(); - } - switch (other.getBuildTemplateCase()) { - case AUTODETECT: - { - setAutodetect(other.getAutodetect()); - break; - } - case BUILD: - { - mergeBuild(other.getBuild()); - break; - } - case FILENAME: - { - buildTemplateCase_ = 8; - buildTemplate_ = other.buildTemplate_; - onChanged(); - break; - } - case BUILDTEMPLATE_NOT_SET: - { - break; - } - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - id_ = input.readStringRequireUtf8(); - - break; - } // case 10 - case 34: - { - input.readMessage(getBuildFieldBuilder().getBuilder(), extensionRegistry); - buildTemplateCase_ = 4; - break; - } // case 34 - case 42: - { - input.readMessage(getCreateTimeFieldBuilder().getBuilder(), extensionRegistry); - - break; - } // case 42 - case 58: - { - input.readMessage(getTriggerTemplateFieldBuilder().getBuilder(), extensionRegistry); - - break; - } // case 58 - case 66: - { - java.lang.String s = input.readStringRequireUtf8(); - buildTemplateCase_ = 8; - buildTemplate_ = s; - break; - } // case 66 - case 72: - { - disabled_ = input.readBool(); - - break; - } // case 72 - case 82: - { - description_ = input.readStringRequireUtf8(); - - break; - } // case 82 - case 90: - { - com.google.protobuf.MapEntry substitutions__ = - input.readMessage( - SubstitutionsDefaultEntryHolder.defaultEntry.getParserForType(), - extensionRegistry); - internalGetMutableSubstitutions() - .getMutableMap() - .put(substitutions__.getKey(), substitutions__.getValue()); - break; - } // case 90 - case 106: - { - input.readMessage(getGithubFieldBuilder().getBuilder(), extensionRegistry); - - break; - } // case 106 - case 122: - { - java.lang.String s = input.readStringRequireUtf8(); - ensureIgnoredFilesIsMutable(); - ignoredFiles_.add(s); - break; - } // case 122 - case 130: - { - java.lang.String s = input.readStringRequireUtf8(); - ensureIncludedFilesIsMutable(); - includedFiles_.add(s); - break; - } // case 130 - case 144: - { - buildTemplate_ = input.readBool(); - buildTemplateCase_ = 18; - break; - } // case 144 - case 154: - { - java.lang.String s = input.readStringRequireUtf8(); - ensureTagsIsMutable(); - tags_.add(s); - break; - } // case 154 - case 170: - { - name_ = input.readStringRequireUtf8(); - - break; - } // case 170 - case 234: - { - input.readMessage(getPubsubConfigFieldBuilder().getBuilder(), extensionRegistry); - - break; - } // case 234 - case 242: - { - filter_ = input.readStringRequireUtf8(); - - break; - } // case 242 - case 250: - { - input.readMessage(getWebhookConfigFieldBuilder().getBuilder(), extensionRegistry); - - break; - } // case 250 - case 266: - { - serviceAccount_ = input.readStringRequireUtf8(); - - break; - } // case 266 - case 274: - { - resourceName_ = input.readStringRequireUtf8(); - - break; - } // case 274 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private int buildTemplateCase_ = 0; - private java.lang.Object buildTemplate_; - - public BuildTemplateCase getBuildTemplateCase() { - return BuildTemplateCase.forNumber(buildTemplateCase_); - } - - public Builder clearBuildTemplate() { - buildTemplateCase_ = 0; - buildTemplate_ = null; - onChanged(); - return this; - } - - private int bitField0_; - - private java.lang.Object resourceName_ = ""; - /** - * - * - *
-     * The `Trigger` name with format:
-     * `projects/{project}/locations/{location}/triggers/{trigger}`, where
-     * {trigger} is a unique identifier generated by the service.
-     * 
- * - * string resource_name = 34; - * - * @return The resourceName. - */ - public java.lang.String getResourceName() { - java.lang.Object ref = resourceName_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - resourceName_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * The `Trigger` name with format:
-     * `projects/{project}/locations/{location}/triggers/{trigger}`, where
-     * {trigger} is a unique identifier generated by the service.
-     * 
- * - * string resource_name = 34; - * - * @return The bytes for resourceName. - */ - public com.google.protobuf.ByteString getResourceNameBytes() { - java.lang.Object ref = resourceName_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - resourceName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * The `Trigger` name with format:
-     * `projects/{project}/locations/{location}/triggers/{trigger}`, where
-     * {trigger} is a unique identifier generated by the service.
-     * 
- * - * string resource_name = 34; - * - * @param value The resourceName to set. - * @return This builder for chaining. - */ - public Builder setResourceName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - resourceName_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The `Trigger` name with format:
-     * `projects/{project}/locations/{location}/triggers/{trigger}`, where
-     * {trigger} is a unique identifier generated by the service.
-     * 
- * - * string resource_name = 34; - * - * @return This builder for chaining. - */ - public Builder clearResourceName() { - - resourceName_ = getDefaultInstance().getResourceName(); - onChanged(); - return this; - } - /** - * - * - *
-     * The `Trigger` name with format:
-     * `projects/{project}/locations/{location}/triggers/{trigger}`, where
-     * {trigger} is a unique identifier generated by the service.
-     * 
- * - * string resource_name = 34; - * - * @param value The bytes for resourceName to set. - * @return This builder for chaining. - */ - public Builder setResourceNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - resourceName_ = value; - onChanged(); - return this; - } - - private java.lang.Object id_ = ""; - /** - * - * - *
-     * Output only. Unique identifier of the trigger.
-     * 
- * - * string id = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The id. - */ - public java.lang.String getId() { - java.lang.Object ref = id_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - id_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Output only. Unique identifier of the trigger.
-     * 
- * - * string id = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The bytes for id. - */ - public com.google.protobuf.ByteString getIdBytes() { - java.lang.Object ref = id_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - id_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Output only. Unique identifier of the trigger.
-     * 
- * - * string id = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @param value The id to set. - * @return This builder for chaining. - */ - public Builder setId(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - id_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. Unique identifier of the trigger.
-     * 
- * - * string id = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return This builder for chaining. - */ - public Builder clearId() { - - id_ = getDefaultInstance().getId(); - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. Unique identifier of the trigger.
-     * 
- * - * string id = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @param value The bytes for id to set. - * @return This builder for chaining. - */ - public Builder setIdBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - id_ = value; - onChanged(); - return this; - } - - private java.lang.Object description_ = ""; - /** - * - * - *
-     * Human-readable description of this trigger.
-     * 
- * - * string description = 10; - * - * @return The description. - */ - public java.lang.String getDescription() { - java.lang.Object ref = description_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - description_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Human-readable description of this trigger.
-     * 
- * - * string description = 10; - * - * @return The bytes for description. - */ - public com.google.protobuf.ByteString getDescriptionBytes() { - java.lang.Object ref = description_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - description_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Human-readable description of this trigger.
-     * 
- * - * string description = 10; - * - * @param value The description to set. - * @return This builder for chaining. - */ - public Builder setDescription(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - description_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Human-readable description of this trigger.
-     * 
- * - * string description = 10; - * - * @return This builder for chaining. - */ - public Builder clearDescription() { - - description_ = getDefaultInstance().getDescription(); - onChanged(); - return this; - } - /** - * - * - *
-     * Human-readable description of this trigger.
-     * 
- * - * string description = 10; - * - * @param value The bytes for description to set. - * @return This builder for chaining. - */ - public Builder setDescriptionBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - description_ = value; - onChanged(); - return this; - } - - private java.lang.Object name_ = ""; - /** - * - * - *
-     * User-assigned name of the trigger. Must be unique within the project.
-     * Trigger names must meet the following requirements:
-     * + They must contain only alphanumeric characters and dashes.
-     * + They can be 1-64 characters long.
-     * + They must begin and end with an alphanumeric character.
-     * 
- * - * string name = 21; - * - * @return The name. - */ - public java.lang.String getName() { - java.lang.Object ref = name_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - name_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * User-assigned name of the trigger. Must be unique within the project.
-     * Trigger names must meet the following requirements:
-     * + They must contain only alphanumeric characters and dashes.
-     * + They can be 1-64 characters long.
-     * + They must begin and end with an alphanumeric character.
-     * 
- * - * string name = 21; - * - * @return The bytes for name. - */ - public com.google.protobuf.ByteString getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * User-assigned name of the trigger. Must be unique within the project.
-     * Trigger names must meet the following requirements:
-     * + They must contain only alphanumeric characters and dashes.
-     * + They can be 1-64 characters long.
-     * + They must begin and end with an alphanumeric character.
-     * 
- * - * string name = 21; - * - * @param value The name to set. - * @return This builder for chaining. - */ - public Builder setName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - name_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * User-assigned name of the trigger. Must be unique within the project.
-     * Trigger names must meet the following requirements:
-     * + They must contain only alphanumeric characters and dashes.
-     * + They can be 1-64 characters long.
-     * + They must begin and end with an alphanumeric character.
-     * 
- * - * string name = 21; - * - * @return This builder for chaining. - */ - public Builder clearName() { - - name_ = getDefaultInstance().getName(); - onChanged(); - return this; - } - /** - * - * - *
-     * User-assigned name of the trigger. Must be unique within the project.
-     * Trigger names must meet the following requirements:
-     * + They must contain only alphanumeric characters and dashes.
-     * + They can be 1-64 characters long.
-     * + They must begin and end with an alphanumeric character.
-     * 
- * - * string name = 21; - * - * @param value The bytes for name to set. - * @return This builder for chaining. - */ - public Builder setNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - name_ = value; - onChanged(); - return this; - } - - private com.google.protobuf.LazyStringList tags_ = - com.google.protobuf.LazyStringArrayList.EMPTY; - - private void ensureTagsIsMutable() { - if (!((bitField0_ & 0x00000001) != 0)) { - tags_ = new com.google.protobuf.LazyStringArrayList(tags_); - bitField0_ |= 0x00000001; - } - } - /** - * - * - *
-     * Tags for annotation of a `BuildTrigger`
-     * 
- * - * repeated string tags = 19; - * - * @return A list containing the tags. - */ - public com.google.protobuf.ProtocolStringList getTagsList() { - return tags_.getUnmodifiableView(); - } - /** - * - * - *
-     * Tags for annotation of a `BuildTrigger`
-     * 
- * - * repeated string tags = 19; - * - * @return The count of tags. - */ - public int getTagsCount() { - return tags_.size(); - } - /** - * - * - *
-     * Tags for annotation of a `BuildTrigger`
-     * 
- * - * repeated string tags = 19; - * - * @param index The index of the element to return. - * @return The tags at the given index. - */ - public java.lang.String getTags(int index) { - return tags_.get(index); - } - /** - * - * - *
-     * Tags for annotation of a `BuildTrigger`
-     * 
- * - * repeated string tags = 19; - * - * @param index The index of the value to return. - * @return The bytes of the tags at the given index. - */ - public com.google.protobuf.ByteString getTagsBytes(int index) { - return tags_.getByteString(index); - } - /** - * - * - *
-     * Tags for annotation of a `BuildTrigger`
-     * 
- * - * repeated string tags = 19; - * - * @param index The index to set the value at. - * @param value The tags to set. - * @return This builder for chaining. - */ - public Builder setTags(int index, java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureTagsIsMutable(); - tags_.set(index, value); - onChanged(); - return this; - } - /** - * - * - *
-     * Tags for annotation of a `BuildTrigger`
-     * 
- * - * repeated string tags = 19; - * - * @param value The tags to add. - * @return This builder for chaining. - */ - public Builder addTags(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureTagsIsMutable(); - tags_.add(value); - onChanged(); - return this; - } - /** - * - * - *
-     * Tags for annotation of a `BuildTrigger`
-     * 
- * - * repeated string tags = 19; - * - * @param values The tags to add. - * @return This builder for chaining. - */ - public Builder addAllTags(java.lang.Iterable values) { - ensureTagsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, tags_); - onChanged(); - return this; - } - /** - * - * - *
-     * Tags for annotation of a `BuildTrigger`
-     * 
- * - * repeated string tags = 19; - * - * @return This builder for chaining. - */ - public Builder clearTags() { - tags_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - return this; - } - /** - * - * - *
-     * Tags for annotation of a `BuildTrigger`
-     * 
- * - * repeated string tags = 19; - * - * @param value The bytes of the tags to add. - * @return This builder for chaining. - */ - public Builder addTagsBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - ensureTagsIsMutable(); - tags_.add(value); - onChanged(); - return this; - } - - private com.google.cloudbuild.v1.RepoSource triggerTemplate_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.RepoSource, - com.google.cloudbuild.v1.RepoSource.Builder, - com.google.cloudbuild.v1.RepoSourceOrBuilder> - triggerTemplateBuilder_; - /** - * - * - *
-     * Template describing the types of source changes to trigger a build.
-     * Branch and tag names in trigger templates are interpreted as regular
-     * expressions. Any branch or tag change that matches that regular expression
-     * will trigger a build.
-     * Mutually exclusive with `github`.
-     * 
- * - * .google.devtools.cloudbuild.v1.RepoSource trigger_template = 7; - * - * @return Whether the triggerTemplate field is set. - */ - public boolean hasTriggerTemplate() { - return triggerTemplateBuilder_ != null || triggerTemplate_ != null; - } - /** - * - * - *
-     * Template describing the types of source changes to trigger a build.
-     * Branch and tag names in trigger templates are interpreted as regular
-     * expressions. Any branch or tag change that matches that regular expression
-     * will trigger a build.
-     * Mutually exclusive with `github`.
-     * 
- * - * .google.devtools.cloudbuild.v1.RepoSource trigger_template = 7; - * - * @return The triggerTemplate. - */ - public com.google.cloudbuild.v1.RepoSource getTriggerTemplate() { - if (triggerTemplateBuilder_ == null) { - return triggerTemplate_ == null - ? com.google.cloudbuild.v1.RepoSource.getDefaultInstance() - : triggerTemplate_; - } else { - return triggerTemplateBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Template describing the types of source changes to trigger a build.
-     * Branch and tag names in trigger templates are interpreted as regular
-     * expressions. Any branch or tag change that matches that regular expression
-     * will trigger a build.
-     * Mutually exclusive with `github`.
-     * 
- * - * .google.devtools.cloudbuild.v1.RepoSource trigger_template = 7; - */ - public Builder setTriggerTemplate(com.google.cloudbuild.v1.RepoSource value) { - if (triggerTemplateBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - triggerTemplate_ = value; - onChanged(); - } else { - triggerTemplateBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * Template describing the types of source changes to trigger a build.
-     * Branch and tag names in trigger templates are interpreted as regular
-     * expressions. Any branch or tag change that matches that regular expression
-     * will trigger a build.
-     * Mutually exclusive with `github`.
-     * 
- * - * .google.devtools.cloudbuild.v1.RepoSource trigger_template = 7; - */ - public Builder setTriggerTemplate(com.google.cloudbuild.v1.RepoSource.Builder builderForValue) { - if (triggerTemplateBuilder_ == null) { - triggerTemplate_ = builderForValue.build(); - onChanged(); - } else { - triggerTemplateBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Template describing the types of source changes to trigger a build.
-     * Branch and tag names in trigger templates are interpreted as regular
-     * expressions. Any branch or tag change that matches that regular expression
-     * will trigger a build.
-     * Mutually exclusive with `github`.
-     * 
- * - * .google.devtools.cloudbuild.v1.RepoSource trigger_template = 7; - */ - public Builder mergeTriggerTemplate(com.google.cloudbuild.v1.RepoSource value) { - if (triggerTemplateBuilder_ == null) { - if (triggerTemplate_ != null) { - triggerTemplate_ = - com.google.cloudbuild.v1.RepoSource.newBuilder(triggerTemplate_) - .mergeFrom(value) - .buildPartial(); - } else { - triggerTemplate_ = value; - } - onChanged(); - } else { - triggerTemplateBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * Template describing the types of source changes to trigger a build.
-     * Branch and tag names in trigger templates are interpreted as regular
-     * expressions. Any branch or tag change that matches that regular expression
-     * will trigger a build.
-     * Mutually exclusive with `github`.
-     * 
- * - * .google.devtools.cloudbuild.v1.RepoSource trigger_template = 7; - */ - public Builder clearTriggerTemplate() { - if (triggerTemplateBuilder_ == null) { - triggerTemplate_ = null; - onChanged(); - } else { - triggerTemplate_ = null; - triggerTemplateBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Template describing the types of source changes to trigger a build.
-     * Branch and tag names in trigger templates are interpreted as regular
-     * expressions. Any branch or tag change that matches that regular expression
-     * will trigger a build.
-     * Mutually exclusive with `github`.
-     * 
- * - * .google.devtools.cloudbuild.v1.RepoSource trigger_template = 7; - */ - public com.google.cloudbuild.v1.RepoSource.Builder getTriggerTemplateBuilder() { - - onChanged(); - return getTriggerTemplateFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Template describing the types of source changes to trigger a build.
-     * Branch and tag names in trigger templates are interpreted as regular
-     * expressions. Any branch or tag change that matches that regular expression
-     * will trigger a build.
-     * Mutually exclusive with `github`.
-     * 
- * - * .google.devtools.cloudbuild.v1.RepoSource trigger_template = 7; - */ - public com.google.cloudbuild.v1.RepoSourceOrBuilder getTriggerTemplateOrBuilder() { - if (triggerTemplateBuilder_ != null) { - return triggerTemplateBuilder_.getMessageOrBuilder(); - } else { - return triggerTemplate_ == null - ? com.google.cloudbuild.v1.RepoSource.getDefaultInstance() - : triggerTemplate_; - } - } - /** - * - * - *
-     * Template describing the types of source changes to trigger a build.
-     * Branch and tag names in trigger templates are interpreted as regular
-     * expressions. Any branch or tag change that matches that regular expression
-     * will trigger a build.
-     * Mutually exclusive with `github`.
-     * 
- * - * .google.devtools.cloudbuild.v1.RepoSource trigger_template = 7; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.RepoSource, - com.google.cloudbuild.v1.RepoSource.Builder, - com.google.cloudbuild.v1.RepoSourceOrBuilder> - getTriggerTemplateFieldBuilder() { - if (triggerTemplateBuilder_ == null) { - triggerTemplateBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.RepoSource, - com.google.cloudbuild.v1.RepoSource.Builder, - com.google.cloudbuild.v1.RepoSourceOrBuilder>( - getTriggerTemplate(), getParentForChildren(), isClean()); - triggerTemplate_ = null; - } - return triggerTemplateBuilder_; - } - - private com.google.cloudbuild.v1.GitHubEventsConfig github_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.GitHubEventsConfig, - com.google.cloudbuild.v1.GitHubEventsConfig.Builder, - com.google.cloudbuild.v1.GitHubEventsConfigOrBuilder> - githubBuilder_; - /** - * - * - *
-     * GitHubEventsConfig describes the configuration of a trigger that creates
-     * a build whenever a GitHub event is received.
-     * Mutually exclusive with `trigger_template`.
-     * 
- * - * .google.devtools.cloudbuild.v1.GitHubEventsConfig github = 13; - * - * @return Whether the github field is set. - */ - public boolean hasGithub() { - return githubBuilder_ != null || github_ != null; - } - /** - * - * - *
-     * GitHubEventsConfig describes the configuration of a trigger that creates
-     * a build whenever a GitHub event is received.
-     * Mutually exclusive with `trigger_template`.
-     * 
- * - * .google.devtools.cloudbuild.v1.GitHubEventsConfig github = 13; - * - * @return The github. - */ - public com.google.cloudbuild.v1.GitHubEventsConfig getGithub() { - if (githubBuilder_ == null) { - return github_ == null - ? com.google.cloudbuild.v1.GitHubEventsConfig.getDefaultInstance() - : github_; - } else { - return githubBuilder_.getMessage(); - } - } - /** - * - * - *
-     * GitHubEventsConfig describes the configuration of a trigger that creates
-     * a build whenever a GitHub event is received.
-     * Mutually exclusive with `trigger_template`.
-     * 
- * - * .google.devtools.cloudbuild.v1.GitHubEventsConfig github = 13; - */ - public Builder setGithub(com.google.cloudbuild.v1.GitHubEventsConfig value) { - if (githubBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - github_ = value; - onChanged(); - } else { - githubBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * GitHubEventsConfig describes the configuration of a trigger that creates
-     * a build whenever a GitHub event is received.
-     * Mutually exclusive with `trigger_template`.
-     * 
- * - * .google.devtools.cloudbuild.v1.GitHubEventsConfig github = 13; - */ - public Builder setGithub(com.google.cloudbuild.v1.GitHubEventsConfig.Builder builderForValue) { - if (githubBuilder_ == null) { - github_ = builderForValue.build(); - onChanged(); - } else { - githubBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * GitHubEventsConfig describes the configuration of a trigger that creates
-     * a build whenever a GitHub event is received.
-     * Mutually exclusive with `trigger_template`.
-     * 
- * - * .google.devtools.cloudbuild.v1.GitHubEventsConfig github = 13; - */ - public Builder mergeGithub(com.google.cloudbuild.v1.GitHubEventsConfig value) { - if (githubBuilder_ == null) { - if (github_ != null) { - github_ = - com.google.cloudbuild.v1.GitHubEventsConfig.newBuilder(github_) - .mergeFrom(value) - .buildPartial(); - } else { - github_ = value; - } - onChanged(); - } else { - githubBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * GitHubEventsConfig describes the configuration of a trigger that creates
-     * a build whenever a GitHub event is received.
-     * Mutually exclusive with `trigger_template`.
-     * 
- * - * .google.devtools.cloudbuild.v1.GitHubEventsConfig github = 13; - */ - public Builder clearGithub() { - if (githubBuilder_ == null) { - github_ = null; - onChanged(); - } else { - github_ = null; - githubBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * GitHubEventsConfig describes the configuration of a trigger that creates
-     * a build whenever a GitHub event is received.
-     * Mutually exclusive with `trigger_template`.
-     * 
- * - * .google.devtools.cloudbuild.v1.GitHubEventsConfig github = 13; - */ - public com.google.cloudbuild.v1.GitHubEventsConfig.Builder getGithubBuilder() { - - onChanged(); - return getGithubFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * GitHubEventsConfig describes the configuration of a trigger that creates
-     * a build whenever a GitHub event is received.
-     * Mutually exclusive with `trigger_template`.
-     * 
- * - * .google.devtools.cloudbuild.v1.GitHubEventsConfig github = 13; - */ - public com.google.cloudbuild.v1.GitHubEventsConfigOrBuilder getGithubOrBuilder() { - if (githubBuilder_ != null) { - return githubBuilder_.getMessageOrBuilder(); - } else { - return github_ == null - ? com.google.cloudbuild.v1.GitHubEventsConfig.getDefaultInstance() - : github_; - } - } - /** - * - * - *
-     * GitHubEventsConfig describes the configuration of a trigger that creates
-     * a build whenever a GitHub event is received.
-     * Mutually exclusive with `trigger_template`.
-     * 
- * - * .google.devtools.cloudbuild.v1.GitHubEventsConfig github = 13; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.GitHubEventsConfig, - com.google.cloudbuild.v1.GitHubEventsConfig.Builder, - com.google.cloudbuild.v1.GitHubEventsConfigOrBuilder> - getGithubFieldBuilder() { - if (githubBuilder_ == null) { - githubBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.GitHubEventsConfig, - com.google.cloudbuild.v1.GitHubEventsConfig.Builder, - com.google.cloudbuild.v1.GitHubEventsConfigOrBuilder>( - getGithub(), getParentForChildren(), isClean()); - github_ = null; - } - return githubBuilder_; - } - - private com.google.cloudbuild.v1.PubsubConfig pubsubConfig_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.PubsubConfig, - com.google.cloudbuild.v1.PubsubConfig.Builder, - com.google.cloudbuild.v1.PubsubConfigOrBuilder> - pubsubConfigBuilder_; - /** - * - * - *
-     * PubsubConfig describes the configuration of a trigger that
-     * creates a build whenever a Pub/Sub message is published.
-     * 
- * - * .google.devtools.cloudbuild.v1.PubsubConfig pubsub_config = 29; - * - * @return Whether the pubsubConfig field is set. - */ - public boolean hasPubsubConfig() { - return pubsubConfigBuilder_ != null || pubsubConfig_ != null; - } - /** - * - * - *
-     * PubsubConfig describes the configuration of a trigger that
-     * creates a build whenever a Pub/Sub message is published.
-     * 
- * - * .google.devtools.cloudbuild.v1.PubsubConfig pubsub_config = 29; - * - * @return The pubsubConfig. - */ - public com.google.cloudbuild.v1.PubsubConfig getPubsubConfig() { - if (pubsubConfigBuilder_ == null) { - return pubsubConfig_ == null - ? com.google.cloudbuild.v1.PubsubConfig.getDefaultInstance() - : pubsubConfig_; - } else { - return pubsubConfigBuilder_.getMessage(); - } - } - /** - * - * - *
-     * PubsubConfig describes the configuration of a trigger that
-     * creates a build whenever a Pub/Sub message is published.
-     * 
- * - * .google.devtools.cloudbuild.v1.PubsubConfig pubsub_config = 29; - */ - public Builder setPubsubConfig(com.google.cloudbuild.v1.PubsubConfig value) { - if (pubsubConfigBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - pubsubConfig_ = value; - onChanged(); - } else { - pubsubConfigBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * PubsubConfig describes the configuration of a trigger that
-     * creates a build whenever a Pub/Sub message is published.
-     * 
- * - * .google.devtools.cloudbuild.v1.PubsubConfig pubsub_config = 29; - */ - public Builder setPubsubConfig(com.google.cloudbuild.v1.PubsubConfig.Builder builderForValue) { - if (pubsubConfigBuilder_ == null) { - pubsubConfig_ = builderForValue.build(); - onChanged(); - } else { - pubsubConfigBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * PubsubConfig describes the configuration of a trigger that
-     * creates a build whenever a Pub/Sub message is published.
-     * 
- * - * .google.devtools.cloudbuild.v1.PubsubConfig pubsub_config = 29; - */ - public Builder mergePubsubConfig(com.google.cloudbuild.v1.PubsubConfig value) { - if (pubsubConfigBuilder_ == null) { - if (pubsubConfig_ != null) { - pubsubConfig_ = - com.google.cloudbuild.v1.PubsubConfig.newBuilder(pubsubConfig_) - .mergeFrom(value) - .buildPartial(); - } else { - pubsubConfig_ = value; - } - onChanged(); - } else { - pubsubConfigBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * PubsubConfig describes the configuration of a trigger that
-     * creates a build whenever a Pub/Sub message is published.
-     * 
- * - * .google.devtools.cloudbuild.v1.PubsubConfig pubsub_config = 29; - */ - public Builder clearPubsubConfig() { - if (pubsubConfigBuilder_ == null) { - pubsubConfig_ = null; - onChanged(); - } else { - pubsubConfig_ = null; - pubsubConfigBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * PubsubConfig describes the configuration of a trigger that
-     * creates a build whenever a Pub/Sub message is published.
-     * 
- * - * .google.devtools.cloudbuild.v1.PubsubConfig pubsub_config = 29; - */ - public com.google.cloudbuild.v1.PubsubConfig.Builder getPubsubConfigBuilder() { - - onChanged(); - return getPubsubConfigFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * PubsubConfig describes the configuration of a trigger that
-     * creates a build whenever a Pub/Sub message is published.
-     * 
- * - * .google.devtools.cloudbuild.v1.PubsubConfig pubsub_config = 29; - */ - public com.google.cloudbuild.v1.PubsubConfigOrBuilder getPubsubConfigOrBuilder() { - if (pubsubConfigBuilder_ != null) { - return pubsubConfigBuilder_.getMessageOrBuilder(); - } else { - return pubsubConfig_ == null - ? com.google.cloudbuild.v1.PubsubConfig.getDefaultInstance() - : pubsubConfig_; - } - } - /** - * - * - *
-     * PubsubConfig describes the configuration of a trigger that
-     * creates a build whenever a Pub/Sub message is published.
-     * 
- * - * .google.devtools.cloudbuild.v1.PubsubConfig pubsub_config = 29; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.PubsubConfig, - com.google.cloudbuild.v1.PubsubConfig.Builder, - com.google.cloudbuild.v1.PubsubConfigOrBuilder> - getPubsubConfigFieldBuilder() { - if (pubsubConfigBuilder_ == null) { - pubsubConfigBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.PubsubConfig, - com.google.cloudbuild.v1.PubsubConfig.Builder, - com.google.cloudbuild.v1.PubsubConfigOrBuilder>( - getPubsubConfig(), getParentForChildren(), isClean()); - pubsubConfig_ = null; - } - return pubsubConfigBuilder_; - } - - private com.google.cloudbuild.v1.WebhookConfig webhookConfig_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.WebhookConfig, - com.google.cloudbuild.v1.WebhookConfig.Builder, - com.google.cloudbuild.v1.WebhookConfigOrBuilder> - webhookConfigBuilder_; - /** - * - * - *
-     * WebhookConfig describes the configuration of a trigger that
-     * creates a build whenever a webhook is sent to a trigger's webhook URL.
-     * 
- * - * .google.devtools.cloudbuild.v1.WebhookConfig webhook_config = 31; - * - * @return Whether the webhookConfig field is set. - */ - public boolean hasWebhookConfig() { - return webhookConfigBuilder_ != null || webhookConfig_ != null; - } - /** - * - * - *
-     * WebhookConfig describes the configuration of a trigger that
-     * creates a build whenever a webhook is sent to a trigger's webhook URL.
-     * 
- * - * .google.devtools.cloudbuild.v1.WebhookConfig webhook_config = 31; - * - * @return The webhookConfig. - */ - public com.google.cloudbuild.v1.WebhookConfig getWebhookConfig() { - if (webhookConfigBuilder_ == null) { - return webhookConfig_ == null - ? com.google.cloudbuild.v1.WebhookConfig.getDefaultInstance() - : webhookConfig_; - } else { - return webhookConfigBuilder_.getMessage(); - } - } - /** - * - * - *
-     * WebhookConfig describes the configuration of a trigger that
-     * creates a build whenever a webhook is sent to a trigger's webhook URL.
-     * 
- * - * .google.devtools.cloudbuild.v1.WebhookConfig webhook_config = 31; - */ - public Builder setWebhookConfig(com.google.cloudbuild.v1.WebhookConfig value) { - if (webhookConfigBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - webhookConfig_ = value; - onChanged(); - } else { - webhookConfigBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * WebhookConfig describes the configuration of a trigger that
-     * creates a build whenever a webhook is sent to a trigger's webhook URL.
-     * 
- * - * .google.devtools.cloudbuild.v1.WebhookConfig webhook_config = 31; - */ - public Builder setWebhookConfig( - com.google.cloudbuild.v1.WebhookConfig.Builder builderForValue) { - if (webhookConfigBuilder_ == null) { - webhookConfig_ = builderForValue.build(); - onChanged(); - } else { - webhookConfigBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * WebhookConfig describes the configuration of a trigger that
-     * creates a build whenever a webhook is sent to a trigger's webhook URL.
-     * 
- * - * .google.devtools.cloudbuild.v1.WebhookConfig webhook_config = 31; - */ - public Builder mergeWebhookConfig(com.google.cloudbuild.v1.WebhookConfig value) { - if (webhookConfigBuilder_ == null) { - if (webhookConfig_ != null) { - webhookConfig_ = - com.google.cloudbuild.v1.WebhookConfig.newBuilder(webhookConfig_) - .mergeFrom(value) - .buildPartial(); - } else { - webhookConfig_ = value; - } - onChanged(); - } else { - webhookConfigBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * WebhookConfig describes the configuration of a trigger that
-     * creates a build whenever a webhook is sent to a trigger's webhook URL.
-     * 
- * - * .google.devtools.cloudbuild.v1.WebhookConfig webhook_config = 31; - */ - public Builder clearWebhookConfig() { - if (webhookConfigBuilder_ == null) { - webhookConfig_ = null; - onChanged(); - } else { - webhookConfig_ = null; - webhookConfigBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * WebhookConfig describes the configuration of a trigger that
-     * creates a build whenever a webhook is sent to a trigger's webhook URL.
-     * 
- * - * .google.devtools.cloudbuild.v1.WebhookConfig webhook_config = 31; - */ - public com.google.cloudbuild.v1.WebhookConfig.Builder getWebhookConfigBuilder() { - - onChanged(); - return getWebhookConfigFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * WebhookConfig describes the configuration of a trigger that
-     * creates a build whenever a webhook is sent to a trigger's webhook URL.
-     * 
- * - * .google.devtools.cloudbuild.v1.WebhookConfig webhook_config = 31; - */ - public com.google.cloudbuild.v1.WebhookConfigOrBuilder getWebhookConfigOrBuilder() { - if (webhookConfigBuilder_ != null) { - return webhookConfigBuilder_.getMessageOrBuilder(); - } else { - return webhookConfig_ == null - ? com.google.cloudbuild.v1.WebhookConfig.getDefaultInstance() - : webhookConfig_; - } - } - /** - * - * - *
-     * WebhookConfig describes the configuration of a trigger that
-     * creates a build whenever a webhook is sent to a trigger's webhook URL.
-     * 
- * - * .google.devtools.cloudbuild.v1.WebhookConfig webhook_config = 31; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.WebhookConfig, - com.google.cloudbuild.v1.WebhookConfig.Builder, - com.google.cloudbuild.v1.WebhookConfigOrBuilder> - getWebhookConfigFieldBuilder() { - if (webhookConfigBuilder_ == null) { - webhookConfigBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.WebhookConfig, - com.google.cloudbuild.v1.WebhookConfig.Builder, - com.google.cloudbuild.v1.WebhookConfigOrBuilder>( - getWebhookConfig(), getParentForChildren(), isClean()); - webhookConfig_ = null; - } - return webhookConfigBuilder_; - } - - /** - * - * - *
-     * Autodetect build configuration.  The following precedence is used (case
-     * insensitive):
-     * 1. cloudbuild.yaml
-     * 2. cloudbuild.yml
-     * 3. cloudbuild.json
-     * 4. Dockerfile
-     * Currently only available for GitHub App Triggers.
-     * 
- * - * bool autodetect = 18; - * - * @return Whether the autodetect field is set. - */ - public boolean hasAutodetect() { - return buildTemplateCase_ == 18; - } - /** - * - * - *
-     * Autodetect build configuration.  The following precedence is used (case
-     * insensitive):
-     * 1. cloudbuild.yaml
-     * 2. cloudbuild.yml
-     * 3. cloudbuild.json
-     * 4. Dockerfile
-     * Currently only available for GitHub App Triggers.
-     * 
- * - * bool autodetect = 18; - * - * @return The autodetect. - */ - public boolean getAutodetect() { - if (buildTemplateCase_ == 18) { - return (java.lang.Boolean) buildTemplate_; - } - return false; - } - /** - * - * - *
-     * Autodetect build configuration.  The following precedence is used (case
-     * insensitive):
-     * 1. cloudbuild.yaml
-     * 2. cloudbuild.yml
-     * 3. cloudbuild.json
-     * 4. Dockerfile
-     * Currently only available for GitHub App Triggers.
-     * 
- * - * bool autodetect = 18; - * - * @param value The autodetect to set. - * @return This builder for chaining. - */ - public Builder setAutodetect(boolean value) { - buildTemplateCase_ = 18; - buildTemplate_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Autodetect build configuration.  The following precedence is used (case
-     * insensitive):
-     * 1. cloudbuild.yaml
-     * 2. cloudbuild.yml
-     * 3. cloudbuild.json
-     * 4. Dockerfile
-     * Currently only available for GitHub App Triggers.
-     * 
- * - * bool autodetect = 18; - * - * @return This builder for chaining. - */ - public Builder clearAutodetect() { - if (buildTemplateCase_ == 18) { - buildTemplateCase_ = 0; - buildTemplate_ = null; - onChanged(); - } - return this; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.Build, - com.google.cloudbuild.v1.Build.Builder, - com.google.cloudbuild.v1.BuildOrBuilder> - buildBuilder_; - /** - * - * - *
-     * Contents of the build template.
-     * 
- * - * .google.devtools.cloudbuild.v1.Build build = 4; - * - * @return Whether the build field is set. - */ - @java.lang.Override - public boolean hasBuild() { - return buildTemplateCase_ == 4; - } - /** - * - * - *
-     * Contents of the build template.
-     * 
- * - * .google.devtools.cloudbuild.v1.Build build = 4; - * - * @return The build. - */ - @java.lang.Override - public com.google.cloudbuild.v1.Build getBuild() { - if (buildBuilder_ == null) { - if (buildTemplateCase_ == 4) { - return (com.google.cloudbuild.v1.Build) buildTemplate_; - } - return com.google.cloudbuild.v1.Build.getDefaultInstance(); - } else { - if (buildTemplateCase_ == 4) { - return buildBuilder_.getMessage(); - } - return com.google.cloudbuild.v1.Build.getDefaultInstance(); - } - } - /** - * - * - *
-     * Contents of the build template.
-     * 
- * - * .google.devtools.cloudbuild.v1.Build build = 4; - */ - public Builder setBuild(com.google.cloudbuild.v1.Build value) { - if (buildBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - buildTemplate_ = value; - onChanged(); - } else { - buildBuilder_.setMessage(value); - } - buildTemplateCase_ = 4; - return this; - } - /** - * - * - *
-     * Contents of the build template.
-     * 
- * - * .google.devtools.cloudbuild.v1.Build build = 4; - */ - public Builder setBuild(com.google.cloudbuild.v1.Build.Builder builderForValue) { - if (buildBuilder_ == null) { - buildTemplate_ = builderForValue.build(); - onChanged(); - } else { - buildBuilder_.setMessage(builderForValue.build()); - } - buildTemplateCase_ = 4; - return this; - } - /** - * - * - *
-     * Contents of the build template.
-     * 
- * - * .google.devtools.cloudbuild.v1.Build build = 4; - */ - public Builder mergeBuild(com.google.cloudbuild.v1.Build value) { - if (buildBuilder_ == null) { - if (buildTemplateCase_ == 4 - && buildTemplate_ != com.google.cloudbuild.v1.Build.getDefaultInstance()) { - buildTemplate_ = - com.google.cloudbuild.v1.Build.newBuilder( - (com.google.cloudbuild.v1.Build) buildTemplate_) - .mergeFrom(value) - .buildPartial(); - } else { - buildTemplate_ = value; - } - onChanged(); - } else { - if (buildTemplateCase_ == 4) { - buildBuilder_.mergeFrom(value); - } else { - buildBuilder_.setMessage(value); - } - } - buildTemplateCase_ = 4; - return this; - } - /** - * - * - *
-     * Contents of the build template.
-     * 
- * - * .google.devtools.cloudbuild.v1.Build build = 4; - */ - public Builder clearBuild() { - if (buildBuilder_ == null) { - if (buildTemplateCase_ == 4) { - buildTemplateCase_ = 0; - buildTemplate_ = null; - onChanged(); - } - } else { - if (buildTemplateCase_ == 4) { - buildTemplateCase_ = 0; - buildTemplate_ = null; - } - buildBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * Contents of the build template.
-     * 
- * - * .google.devtools.cloudbuild.v1.Build build = 4; - */ - public com.google.cloudbuild.v1.Build.Builder getBuildBuilder() { - return getBuildFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Contents of the build template.
-     * 
- * - * .google.devtools.cloudbuild.v1.Build build = 4; - */ - @java.lang.Override - public com.google.cloudbuild.v1.BuildOrBuilder getBuildOrBuilder() { - if ((buildTemplateCase_ == 4) && (buildBuilder_ != null)) { - return buildBuilder_.getMessageOrBuilder(); - } else { - if (buildTemplateCase_ == 4) { - return (com.google.cloudbuild.v1.Build) buildTemplate_; - } - return com.google.cloudbuild.v1.Build.getDefaultInstance(); - } - } - /** - * - * - *
-     * Contents of the build template.
-     * 
- * - * .google.devtools.cloudbuild.v1.Build build = 4; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.Build, - com.google.cloudbuild.v1.Build.Builder, - com.google.cloudbuild.v1.BuildOrBuilder> - getBuildFieldBuilder() { - if (buildBuilder_ == null) { - if (!(buildTemplateCase_ == 4)) { - buildTemplate_ = com.google.cloudbuild.v1.Build.getDefaultInstance(); - } - buildBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.Build, - com.google.cloudbuild.v1.Build.Builder, - com.google.cloudbuild.v1.BuildOrBuilder>( - (com.google.cloudbuild.v1.Build) buildTemplate_, getParentForChildren(), isClean()); - buildTemplate_ = null; - } - buildTemplateCase_ = 4; - onChanged(); - ; - return buildBuilder_; - } - - /** - * - * - *
-     * Path, from the source root, to the build configuration file
-     * (i.e. cloudbuild.yaml).
-     * 
- * - * string filename = 8; - * - * @return Whether the filename field is set. - */ - @java.lang.Override - public boolean hasFilename() { - return buildTemplateCase_ == 8; - } - /** - * - * - *
-     * Path, from the source root, to the build configuration file
-     * (i.e. cloudbuild.yaml).
-     * 
- * - * string filename = 8; - * - * @return The filename. - */ - @java.lang.Override - public java.lang.String getFilename() { - java.lang.Object ref = ""; - if (buildTemplateCase_ == 8) { - ref = buildTemplate_; - } - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (buildTemplateCase_ == 8) { - buildTemplate_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Path, from the source root, to the build configuration file
-     * (i.e. cloudbuild.yaml).
-     * 
- * - * string filename = 8; - * - * @return The bytes for filename. - */ - @java.lang.Override - public com.google.protobuf.ByteString getFilenameBytes() { - java.lang.Object ref = ""; - if (buildTemplateCase_ == 8) { - ref = buildTemplate_; - } - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - if (buildTemplateCase_ == 8) { - buildTemplate_ = b; - } - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Path, from the source root, to the build configuration file
-     * (i.e. cloudbuild.yaml).
-     * 
- * - * string filename = 8; - * - * @param value The filename to set. - * @return This builder for chaining. - */ - public Builder setFilename(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - buildTemplateCase_ = 8; - buildTemplate_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Path, from the source root, to the build configuration file
-     * (i.e. cloudbuild.yaml).
-     * 
- * - * string filename = 8; - * - * @return This builder for chaining. - */ - public Builder clearFilename() { - if (buildTemplateCase_ == 8) { - buildTemplateCase_ = 0; - buildTemplate_ = null; - onChanged(); - } - return this; - } - /** - * - * - *
-     * Path, from the source root, to the build configuration file
-     * (i.e. cloudbuild.yaml).
-     * 
- * - * string filename = 8; - * - * @param value The bytes for filename to set. - * @return This builder for chaining. - */ - public Builder setFilenameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - buildTemplateCase_ = 8; - buildTemplate_ = value; - onChanged(); - return this; - } - - private com.google.protobuf.Timestamp createTime_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - createTimeBuilder_; - /** - * - * - *
-     * Output only. Time when the trigger was created.
-     * 
- * - * - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return Whether the createTime field is set. - */ - public boolean hasCreateTime() { - return createTimeBuilder_ != null || createTime_ != null; - } - /** - * - * - *
-     * Output only. Time when the trigger was created.
-     * 
- * - * - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The createTime. - */ - public com.google.protobuf.Timestamp getCreateTime() { - if (createTimeBuilder_ == null) { - return createTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : createTime_; - } else { - return createTimeBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Output only. Time when the trigger was created.
-     * 
- * - * - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder setCreateTime(com.google.protobuf.Timestamp value) { - if (createTimeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - createTime_ = value; - onChanged(); - } else { - createTimeBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * Output only. Time when the trigger was created.
-     * 
- * - * - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder setCreateTime(com.google.protobuf.Timestamp.Builder builderForValue) { - if (createTimeBuilder_ == null) { - createTime_ = builderForValue.build(); - onChanged(); - } else { - createTimeBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Output only. Time when the trigger was created.
-     * 
- * - * - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder mergeCreateTime(com.google.protobuf.Timestamp value) { - if (createTimeBuilder_ == null) { - if (createTime_ != null) { - createTime_ = - com.google.protobuf.Timestamp.newBuilder(createTime_).mergeFrom(value).buildPartial(); - } else { - createTime_ = value; - } - onChanged(); - } else { - createTimeBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * Output only. Time when the trigger was created.
-     * 
- * - * - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder clearCreateTime() { - if (createTimeBuilder_ == null) { - createTime_ = null; - onChanged(); - } else { - createTime_ = null; - createTimeBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Output only. Time when the trigger was created.
-     * 
- * - * - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder() { - - onChanged(); - return getCreateTimeFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Output only. Time when the trigger was created.
-     * 
- * - * - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { - if (createTimeBuilder_ != null) { - return createTimeBuilder_.getMessageOrBuilder(); - } else { - return createTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : createTime_; - } - } - /** - * - * - *
-     * Output only. Time when the trigger was created.
-     * 
- * - * - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - getCreateTimeFieldBuilder() { - if (createTimeBuilder_ == null) { - createTimeBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder>( - getCreateTime(), getParentForChildren(), isClean()); - createTime_ = null; - } - return createTimeBuilder_; - } - - private boolean disabled_; - /** - * - * - *
-     * If true, the trigger will never automatically execute a build.
-     * 
- * - * bool disabled = 9; - * - * @return The disabled. - */ - @java.lang.Override - public boolean getDisabled() { - return disabled_; - } - /** - * - * - *
-     * If true, the trigger will never automatically execute a build.
-     * 
- * - * bool disabled = 9; - * - * @param value The disabled to set. - * @return This builder for chaining. - */ - public Builder setDisabled(boolean value) { - - disabled_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * If true, the trigger will never automatically execute a build.
-     * 
- * - * bool disabled = 9; - * - * @return This builder for chaining. - */ - public Builder clearDisabled() { - - disabled_ = false; - onChanged(); - return this; - } - - private com.google.protobuf.MapField substitutions_; - - private com.google.protobuf.MapField - internalGetSubstitutions() { - if (substitutions_ == null) { - return com.google.protobuf.MapField.emptyMapField( - SubstitutionsDefaultEntryHolder.defaultEntry); - } - return substitutions_; - } - - private com.google.protobuf.MapField - internalGetMutableSubstitutions() { - onChanged(); - ; - if (substitutions_ == null) { - substitutions_ = - com.google.protobuf.MapField.newMapField(SubstitutionsDefaultEntryHolder.defaultEntry); - } - if (!substitutions_.isMutable()) { - substitutions_ = substitutions_.copy(); - } - return substitutions_; - } - - public int getSubstitutionsCount() { - return internalGetSubstitutions().getMap().size(); - } - /** - * - * - *
-     * Substitutions for Build resource. The keys must match the following
-     * regular expression: `^_[A-Z0-9_]+$`.
-     * 
- * - * map<string, string> substitutions = 11; - */ - @java.lang.Override - public boolean containsSubstitutions(java.lang.String key) { - if (key == null) { - throw new NullPointerException("map key"); - } - return internalGetSubstitutions().getMap().containsKey(key); - } - /** Use {@link #getSubstitutionsMap()} instead. */ - @java.lang.Override - @java.lang.Deprecated - public java.util.Map getSubstitutions() { - return getSubstitutionsMap(); - } - /** - * - * - *
-     * Substitutions for Build resource. The keys must match the following
-     * regular expression: `^_[A-Z0-9_]+$`.
-     * 
- * - * map<string, string> substitutions = 11; - */ - @java.lang.Override - public java.util.Map getSubstitutionsMap() { - return internalGetSubstitutions().getMap(); - } - /** - * - * - *
-     * Substitutions for Build resource. The keys must match the following
-     * regular expression: `^_[A-Z0-9_]+$`.
-     * 
- * - * map<string, string> substitutions = 11; - */ - @java.lang.Override - public java.lang.String getSubstitutionsOrDefault( - java.lang.String key, java.lang.String defaultValue) { - if (key == null) { - throw new NullPointerException("map key"); - } - java.util.Map map = internalGetSubstitutions().getMap(); - return map.containsKey(key) ? map.get(key) : defaultValue; - } - /** - * - * - *
-     * Substitutions for Build resource. The keys must match the following
-     * regular expression: `^_[A-Z0-9_]+$`.
-     * 
- * - * map<string, string> substitutions = 11; - */ - @java.lang.Override - public java.lang.String getSubstitutionsOrThrow(java.lang.String key) { - if (key == null) { - throw new NullPointerException("map key"); - } - java.util.Map map = internalGetSubstitutions().getMap(); - if (!map.containsKey(key)) { - throw new java.lang.IllegalArgumentException(); - } - return map.get(key); - } - - public Builder clearSubstitutions() { - internalGetMutableSubstitutions().getMutableMap().clear(); - return this; - } - /** - * - * - *
-     * Substitutions for Build resource. The keys must match the following
-     * regular expression: `^_[A-Z0-9_]+$`.
-     * 
- * - * map<string, string> substitutions = 11; - */ - public Builder removeSubstitutions(java.lang.String key) { - if (key == null) { - throw new NullPointerException("map key"); - } - internalGetMutableSubstitutions().getMutableMap().remove(key); - return this; - } - /** Use alternate mutation accessors instead. */ - @java.lang.Deprecated - public java.util.Map getMutableSubstitutions() { - return internalGetMutableSubstitutions().getMutableMap(); - } - /** - * - * - *
-     * Substitutions for Build resource. The keys must match the following
-     * regular expression: `^_[A-Z0-9_]+$`.
-     * 
- * - * map<string, string> substitutions = 11; - */ - public Builder putSubstitutions(java.lang.String key, java.lang.String value) { - if (key == null) { - throw new NullPointerException("map key"); - } - if (value == null) { - throw new NullPointerException("map value"); - } - - internalGetMutableSubstitutions().getMutableMap().put(key, value); - return this; - } - /** - * - * - *
-     * Substitutions for Build resource. The keys must match the following
-     * regular expression: `^_[A-Z0-9_]+$`.
-     * 
- * - * map<string, string> substitutions = 11; - */ - public Builder putAllSubstitutions(java.util.Map values) { - internalGetMutableSubstitutions().getMutableMap().putAll(values); - return this; - } - - private com.google.protobuf.LazyStringList ignoredFiles_ = - com.google.protobuf.LazyStringArrayList.EMPTY; - - private void ensureIgnoredFilesIsMutable() { - if (!((bitField0_ & 0x00000004) != 0)) { - ignoredFiles_ = new com.google.protobuf.LazyStringArrayList(ignoredFiles_); - bitField0_ |= 0x00000004; - } - } - /** - * - * - *
-     * ignored_files and included_files are file glob matches using
-     * https://golang.org/pkg/path/filepath/#Match extended with support for "**".
-     * If ignored_files and changed files are both empty, then they are
-     * not used to determine whether or not to trigger a build.
-     * If ignored_files is not empty, then we ignore any files that match
-     * any of the ignored_file globs. If the change has no files that are
-     * outside of the ignored_files globs, then we do not trigger a build.
-     * 
- * - * repeated string ignored_files = 15; - * - * @return A list containing the ignoredFiles. - */ - public com.google.protobuf.ProtocolStringList getIgnoredFilesList() { - return ignoredFiles_.getUnmodifiableView(); - } - /** - * - * - *
-     * ignored_files and included_files are file glob matches using
-     * https://golang.org/pkg/path/filepath/#Match extended with support for "**".
-     * If ignored_files and changed files are both empty, then they are
-     * not used to determine whether or not to trigger a build.
-     * If ignored_files is not empty, then we ignore any files that match
-     * any of the ignored_file globs. If the change has no files that are
-     * outside of the ignored_files globs, then we do not trigger a build.
-     * 
- * - * repeated string ignored_files = 15; - * - * @return The count of ignoredFiles. - */ - public int getIgnoredFilesCount() { - return ignoredFiles_.size(); - } - /** - * - * - *
-     * ignored_files and included_files are file glob matches using
-     * https://golang.org/pkg/path/filepath/#Match extended with support for "**".
-     * If ignored_files and changed files are both empty, then they are
-     * not used to determine whether or not to trigger a build.
-     * If ignored_files is not empty, then we ignore any files that match
-     * any of the ignored_file globs. If the change has no files that are
-     * outside of the ignored_files globs, then we do not trigger a build.
-     * 
- * - * repeated string ignored_files = 15; - * - * @param index The index of the element to return. - * @return The ignoredFiles at the given index. - */ - public java.lang.String getIgnoredFiles(int index) { - return ignoredFiles_.get(index); - } - /** - * - * - *
-     * ignored_files and included_files are file glob matches using
-     * https://golang.org/pkg/path/filepath/#Match extended with support for "**".
-     * If ignored_files and changed files are both empty, then they are
-     * not used to determine whether or not to trigger a build.
-     * If ignored_files is not empty, then we ignore any files that match
-     * any of the ignored_file globs. If the change has no files that are
-     * outside of the ignored_files globs, then we do not trigger a build.
-     * 
- * - * repeated string ignored_files = 15; - * - * @param index The index of the value to return. - * @return The bytes of the ignoredFiles at the given index. - */ - public com.google.protobuf.ByteString getIgnoredFilesBytes(int index) { - return ignoredFiles_.getByteString(index); - } - /** - * - * - *
-     * ignored_files and included_files are file glob matches using
-     * https://golang.org/pkg/path/filepath/#Match extended with support for "**".
-     * If ignored_files and changed files are both empty, then they are
-     * not used to determine whether or not to trigger a build.
-     * If ignored_files is not empty, then we ignore any files that match
-     * any of the ignored_file globs. If the change has no files that are
-     * outside of the ignored_files globs, then we do not trigger a build.
-     * 
- * - * repeated string ignored_files = 15; - * - * @param index The index to set the value at. - * @param value The ignoredFiles to set. - * @return This builder for chaining. - */ - public Builder setIgnoredFiles(int index, java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureIgnoredFilesIsMutable(); - ignoredFiles_.set(index, value); - onChanged(); - return this; - } - /** - * - * - *
-     * ignored_files and included_files are file glob matches using
-     * https://golang.org/pkg/path/filepath/#Match extended with support for "**".
-     * If ignored_files and changed files are both empty, then they are
-     * not used to determine whether or not to trigger a build.
-     * If ignored_files is not empty, then we ignore any files that match
-     * any of the ignored_file globs. If the change has no files that are
-     * outside of the ignored_files globs, then we do not trigger a build.
-     * 
- * - * repeated string ignored_files = 15; - * - * @param value The ignoredFiles to add. - * @return This builder for chaining. - */ - public Builder addIgnoredFiles(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureIgnoredFilesIsMutable(); - ignoredFiles_.add(value); - onChanged(); - return this; - } - /** - * - * - *
-     * ignored_files and included_files are file glob matches using
-     * https://golang.org/pkg/path/filepath/#Match extended with support for "**".
-     * If ignored_files and changed files are both empty, then they are
-     * not used to determine whether or not to trigger a build.
-     * If ignored_files is not empty, then we ignore any files that match
-     * any of the ignored_file globs. If the change has no files that are
-     * outside of the ignored_files globs, then we do not trigger a build.
-     * 
- * - * repeated string ignored_files = 15; - * - * @param values The ignoredFiles to add. - * @return This builder for chaining. - */ - public Builder addAllIgnoredFiles(java.lang.Iterable values) { - ensureIgnoredFilesIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, ignoredFiles_); - onChanged(); - return this; - } - /** - * - * - *
-     * ignored_files and included_files are file glob matches using
-     * https://golang.org/pkg/path/filepath/#Match extended with support for "**".
-     * If ignored_files and changed files are both empty, then they are
-     * not used to determine whether or not to trigger a build.
-     * If ignored_files is not empty, then we ignore any files that match
-     * any of the ignored_file globs. If the change has no files that are
-     * outside of the ignored_files globs, then we do not trigger a build.
-     * 
- * - * repeated string ignored_files = 15; - * - * @return This builder for chaining. - */ - public Builder clearIgnoredFiles() { - ignoredFiles_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000004); - onChanged(); - return this; - } - /** - * - * - *
-     * ignored_files and included_files are file glob matches using
-     * https://golang.org/pkg/path/filepath/#Match extended with support for "**".
-     * If ignored_files and changed files are both empty, then they are
-     * not used to determine whether or not to trigger a build.
-     * If ignored_files is not empty, then we ignore any files that match
-     * any of the ignored_file globs. If the change has no files that are
-     * outside of the ignored_files globs, then we do not trigger a build.
-     * 
- * - * repeated string ignored_files = 15; - * - * @param value The bytes of the ignoredFiles to add. - * @return This builder for chaining. - */ - public Builder addIgnoredFilesBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - ensureIgnoredFilesIsMutable(); - ignoredFiles_.add(value); - onChanged(); - return this; - } - - private com.google.protobuf.LazyStringList includedFiles_ = - com.google.protobuf.LazyStringArrayList.EMPTY; - - private void ensureIncludedFilesIsMutable() { - if (!((bitField0_ & 0x00000008) != 0)) { - includedFiles_ = new com.google.protobuf.LazyStringArrayList(includedFiles_); - bitField0_ |= 0x00000008; - } - } - /** - * - * - *
-     * If any of the files altered in the commit pass the ignored_files
-     * filter and included_files is empty, then as far as this filter is
-     * concerned, we should trigger the build.
-     * If any of the files altered in the commit pass the ignored_files
-     * filter and included_files is not empty, then we make sure that at
-     * least one of those files matches a included_files glob. If not,
-     * then we do not trigger a build.
-     * 
- * - * repeated string included_files = 16; - * - * @return A list containing the includedFiles. - */ - public com.google.protobuf.ProtocolStringList getIncludedFilesList() { - return includedFiles_.getUnmodifiableView(); - } - /** - * - * - *
-     * If any of the files altered in the commit pass the ignored_files
-     * filter and included_files is empty, then as far as this filter is
-     * concerned, we should trigger the build.
-     * If any of the files altered in the commit pass the ignored_files
-     * filter and included_files is not empty, then we make sure that at
-     * least one of those files matches a included_files glob. If not,
-     * then we do not trigger a build.
-     * 
- * - * repeated string included_files = 16; - * - * @return The count of includedFiles. - */ - public int getIncludedFilesCount() { - return includedFiles_.size(); - } - /** - * - * - *
-     * If any of the files altered in the commit pass the ignored_files
-     * filter and included_files is empty, then as far as this filter is
-     * concerned, we should trigger the build.
-     * If any of the files altered in the commit pass the ignored_files
-     * filter and included_files is not empty, then we make sure that at
-     * least one of those files matches a included_files glob. If not,
-     * then we do not trigger a build.
-     * 
- * - * repeated string included_files = 16; - * - * @param index The index of the element to return. - * @return The includedFiles at the given index. - */ - public java.lang.String getIncludedFiles(int index) { - return includedFiles_.get(index); - } - /** - * - * - *
-     * If any of the files altered in the commit pass the ignored_files
-     * filter and included_files is empty, then as far as this filter is
-     * concerned, we should trigger the build.
-     * If any of the files altered in the commit pass the ignored_files
-     * filter and included_files is not empty, then we make sure that at
-     * least one of those files matches a included_files glob. If not,
-     * then we do not trigger a build.
-     * 
- * - * repeated string included_files = 16; - * - * @param index The index of the value to return. - * @return The bytes of the includedFiles at the given index. - */ - public com.google.protobuf.ByteString getIncludedFilesBytes(int index) { - return includedFiles_.getByteString(index); - } - /** - * - * - *
-     * If any of the files altered in the commit pass the ignored_files
-     * filter and included_files is empty, then as far as this filter is
-     * concerned, we should trigger the build.
-     * If any of the files altered in the commit pass the ignored_files
-     * filter and included_files is not empty, then we make sure that at
-     * least one of those files matches a included_files glob. If not,
-     * then we do not trigger a build.
-     * 
- * - * repeated string included_files = 16; - * - * @param index The index to set the value at. - * @param value The includedFiles to set. - * @return This builder for chaining. - */ - public Builder setIncludedFiles(int index, java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureIncludedFilesIsMutable(); - includedFiles_.set(index, value); - onChanged(); - return this; - } - /** - * - * - *
-     * If any of the files altered in the commit pass the ignored_files
-     * filter and included_files is empty, then as far as this filter is
-     * concerned, we should trigger the build.
-     * If any of the files altered in the commit pass the ignored_files
-     * filter and included_files is not empty, then we make sure that at
-     * least one of those files matches a included_files glob. If not,
-     * then we do not trigger a build.
-     * 
- * - * repeated string included_files = 16; - * - * @param value The includedFiles to add. - * @return This builder for chaining. - */ - public Builder addIncludedFiles(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureIncludedFilesIsMutable(); - includedFiles_.add(value); - onChanged(); - return this; - } - /** - * - * - *
-     * If any of the files altered in the commit pass the ignored_files
-     * filter and included_files is empty, then as far as this filter is
-     * concerned, we should trigger the build.
-     * If any of the files altered in the commit pass the ignored_files
-     * filter and included_files is not empty, then we make sure that at
-     * least one of those files matches a included_files glob. If not,
-     * then we do not trigger a build.
-     * 
- * - * repeated string included_files = 16; - * - * @param values The includedFiles to add. - * @return This builder for chaining. - */ - public Builder addAllIncludedFiles(java.lang.Iterable values) { - ensureIncludedFilesIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, includedFiles_); - onChanged(); - return this; - } - /** - * - * - *
-     * If any of the files altered in the commit pass the ignored_files
-     * filter and included_files is empty, then as far as this filter is
-     * concerned, we should trigger the build.
-     * If any of the files altered in the commit pass the ignored_files
-     * filter and included_files is not empty, then we make sure that at
-     * least one of those files matches a included_files glob. If not,
-     * then we do not trigger a build.
-     * 
- * - * repeated string included_files = 16; - * - * @return This builder for chaining. - */ - public Builder clearIncludedFiles() { - includedFiles_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000008); - onChanged(); - return this; - } - /** - * - * - *
-     * If any of the files altered in the commit pass the ignored_files
-     * filter and included_files is empty, then as far as this filter is
-     * concerned, we should trigger the build.
-     * If any of the files altered in the commit pass the ignored_files
-     * filter and included_files is not empty, then we make sure that at
-     * least one of those files matches a included_files glob. If not,
-     * then we do not trigger a build.
-     * 
- * - * repeated string included_files = 16; - * - * @param value The bytes of the includedFiles to add. - * @return This builder for chaining. - */ - public Builder addIncludedFilesBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - ensureIncludedFilesIsMutable(); - includedFiles_.add(value); - onChanged(); - return this; - } - - private java.lang.Object filter_ = ""; - /** - * - * - *
-     * Optional. A Common Expression Language string.
-     * 
- * - * string filter = 30 [(.google.api.field_behavior) = OPTIONAL]; - * - * @return The filter. - */ - public java.lang.String getFilter() { - java.lang.Object ref = filter_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - filter_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Optional. A Common Expression Language string.
-     * 
- * - * string filter = 30 [(.google.api.field_behavior) = OPTIONAL]; - * - * @return The bytes for filter. - */ - public com.google.protobuf.ByteString getFilterBytes() { - java.lang.Object ref = filter_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - filter_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Optional. A Common Expression Language string.
-     * 
- * - * string filter = 30 [(.google.api.field_behavior) = OPTIONAL]; - * - * @param value The filter to set. - * @return This builder for chaining. - */ - public Builder setFilter(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - filter_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Optional. A Common Expression Language string.
-     * 
- * - * string filter = 30 [(.google.api.field_behavior) = OPTIONAL]; - * - * @return This builder for chaining. - */ - public Builder clearFilter() { - - filter_ = getDefaultInstance().getFilter(); - onChanged(); - return this; - } - /** - * - * - *
-     * Optional. A Common Expression Language string.
-     * 
- * - * string filter = 30 [(.google.api.field_behavior) = OPTIONAL]; - * - * @param value The bytes for filter to set. - * @return This builder for chaining. - */ - public Builder setFilterBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - filter_ = value; - onChanged(); - return this; - } - - private java.lang.Object serviceAccount_ = ""; - /** - * - * - *
-     * The service account used for all user-controlled operations including
-     * UpdateBuildTrigger, RunBuildTrigger, CreateBuild, and CancelBuild.
-     * If no service account is set, then the standard Cloud Build service account
-     * ([PROJECT_NUM]@system.gserviceaccount.com) will be used instead.
-     * Format: `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT_ID_OR_EMAIL}`
-     * 
- * - * string service_account = 33 [(.google.api.resource_reference) = { ... } - * - * @return The serviceAccount. - */ - public java.lang.String getServiceAccount() { - java.lang.Object ref = serviceAccount_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - serviceAccount_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * The service account used for all user-controlled operations including
-     * UpdateBuildTrigger, RunBuildTrigger, CreateBuild, and CancelBuild.
-     * If no service account is set, then the standard Cloud Build service account
-     * ([PROJECT_NUM]@system.gserviceaccount.com) will be used instead.
-     * Format: `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT_ID_OR_EMAIL}`
-     * 
- * - * string service_account = 33 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for serviceAccount. - */ - public com.google.protobuf.ByteString getServiceAccountBytes() { - java.lang.Object ref = serviceAccount_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - serviceAccount_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * The service account used for all user-controlled operations including
-     * UpdateBuildTrigger, RunBuildTrigger, CreateBuild, and CancelBuild.
-     * If no service account is set, then the standard Cloud Build service account
-     * ([PROJECT_NUM]@system.gserviceaccount.com) will be used instead.
-     * Format: `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT_ID_OR_EMAIL}`
-     * 
- * - * string service_account = 33 [(.google.api.resource_reference) = { ... } - * - * @param value The serviceAccount to set. - * @return This builder for chaining. - */ - public Builder setServiceAccount(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - serviceAccount_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The service account used for all user-controlled operations including
-     * UpdateBuildTrigger, RunBuildTrigger, CreateBuild, and CancelBuild.
-     * If no service account is set, then the standard Cloud Build service account
-     * ([PROJECT_NUM]@system.gserviceaccount.com) will be used instead.
-     * Format: `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT_ID_OR_EMAIL}`
-     * 
- * - * string service_account = 33 [(.google.api.resource_reference) = { ... } - * - * @return This builder for chaining. - */ - public Builder clearServiceAccount() { - - serviceAccount_ = getDefaultInstance().getServiceAccount(); - onChanged(); - return this; - } - /** - * - * - *
-     * The service account used for all user-controlled operations including
-     * UpdateBuildTrigger, RunBuildTrigger, CreateBuild, and CancelBuild.
-     * If no service account is set, then the standard Cloud Build service account
-     * ([PROJECT_NUM]@system.gserviceaccount.com) will be used instead.
-     * Format: `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT_ID_OR_EMAIL}`
-     * 
- * - * string service_account = 33 [(.google.api.resource_reference) = { ... } - * - * @param value The bytes for serviceAccount to set. - * @return This builder for chaining. - */ - public Builder setServiceAccountBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - serviceAccount_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.BuildTrigger) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.BuildTrigger) - private static final com.google.cloudbuild.v1.BuildTrigger DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.BuildTrigger(); - } - - public static com.google.cloudbuild.v1.BuildTrigger getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public BuildTrigger parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.BuildTrigger getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildTriggerName.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildTriggerName.java deleted file mode 100644 index 95d3e109..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildTriggerName.java +++ /dev/null @@ -1,313 +0,0 @@ -/* - * Copyright 2022 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package com.google.cloudbuild.v1; - -import com.google.api.core.BetaApi; -import com.google.api.pathtemplate.PathTemplate; -import com.google.api.pathtemplate.ValidationException; -import com.google.api.resourcenames.ResourceName; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; -import java.util.Objects; -import javax.annotation.Generated; - -// AUTO-GENERATED DOCUMENTATION AND CLASS. -@Generated("by gapic-generator-java") -public class BuildTriggerName implements ResourceName { - private static final PathTemplate PROJECT_TRIGGER = - PathTemplate.createWithoutUrlEncoding("projects/{project}/triggers/{trigger}"); - private static final PathTemplate PROJECT_LOCATION_TRIGGER = - PathTemplate.createWithoutUrlEncoding( - "projects/{project}/locations/{location}/triggers/{trigger}"); - private volatile Map fieldValuesMap; - private PathTemplate pathTemplate; - private String fixedValue; - private final String project; - private final String trigger; - private final String location; - - @Deprecated - protected BuildTriggerName() { - project = null; - trigger = null; - location = null; - } - - private BuildTriggerName(Builder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - trigger = Preconditions.checkNotNull(builder.getTrigger()); - location = null; - pathTemplate = PROJECT_TRIGGER; - } - - private BuildTriggerName(ProjectLocationTriggerBuilder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - location = Preconditions.checkNotNull(builder.getLocation()); - trigger = Preconditions.checkNotNull(builder.getTrigger()); - pathTemplate = PROJECT_LOCATION_TRIGGER; - } - - public String getProject() { - return project; - } - - public String getTrigger() { - return trigger; - } - - public String getLocation() { - return location; - } - - public static Builder newBuilder() { - return new Builder(); - } - - @BetaApi("The per-pattern Builders are not stable yet and may be changed in the future.") - public static Builder newProjectTriggerBuilder() { - return new Builder(); - } - - @BetaApi("The per-pattern Builders are not stable yet and may be changed in the future.") - public static ProjectLocationTriggerBuilder newProjectLocationTriggerBuilder() { - return new ProjectLocationTriggerBuilder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - public static BuildTriggerName of(String project, String trigger) { - return newBuilder().setProject(project).setTrigger(trigger).build(); - } - - @BetaApi("The static create methods are not stable yet and may be changed in the future.") - public static BuildTriggerName ofProjectTriggerName(String project, String trigger) { - return newBuilder().setProject(project).setTrigger(trigger).build(); - } - - @BetaApi("The static create methods are not stable yet and may be changed in the future.") - public static BuildTriggerName ofProjectLocationTriggerName( - String project, String location, String trigger) { - return newProjectLocationTriggerBuilder() - .setProject(project) - .setLocation(location) - .setTrigger(trigger) - .build(); - } - - public static String format(String project, String trigger) { - return newBuilder().setProject(project).setTrigger(trigger).build().toString(); - } - - @BetaApi("The static format methods are not stable yet and may be changed in the future.") - public static String formatProjectTriggerName(String project, String trigger) { - return newBuilder().setProject(project).setTrigger(trigger).build().toString(); - } - - @BetaApi("The static format methods are not stable yet and may be changed in the future.") - public static String formatProjectLocationTriggerName( - String project, String location, String trigger) { - return newProjectLocationTriggerBuilder() - .setProject(project) - .setLocation(location) - .setTrigger(trigger) - .build() - .toString(); - } - - public static BuildTriggerName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - if (PROJECT_TRIGGER.matches(formattedString)) { - Map matchMap = PROJECT_TRIGGER.match(formattedString); - return ofProjectTriggerName(matchMap.get("project"), matchMap.get("trigger")); - } else if (PROJECT_LOCATION_TRIGGER.matches(formattedString)) { - Map matchMap = PROJECT_LOCATION_TRIGGER.match(formattedString); - return ofProjectLocationTriggerName( - matchMap.get("project"), matchMap.get("location"), matchMap.get("trigger")); - } - throw new ValidationException("BuildTriggerName.parse: formattedString not in valid format"); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList<>(values.size()); - for (BuildTriggerName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PROJECT_TRIGGER.matches(formattedString) - || PROJECT_LOCATION_TRIGGER.matches(formattedString); - } - - @Override - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - if (project != null) { - fieldMapBuilder.put("project", project); - } - if (trigger != null) { - fieldMapBuilder.put("trigger", trigger); - } - if (location != null) { - fieldMapBuilder.put("location", location); - } - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - @Override - public String toString() { - return fixedValue != null ? fixedValue : pathTemplate.instantiate(getFieldValuesMap()); - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o != null || getClass() == o.getClass()) { - BuildTriggerName that = ((BuildTriggerName) o); - return Objects.equals(this.project, that.project) - && Objects.equals(this.trigger, that.trigger) - && Objects.equals(this.location, that.location); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= Objects.hashCode(fixedValue); - h *= 1000003; - h ^= Objects.hashCode(project); - h *= 1000003; - h ^= Objects.hashCode(trigger); - h *= 1000003; - h ^= Objects.hashCode(location); - return h; - } - - /** Builder for projects/{project}/triggers/{trigger}. */ - public static class Builder { - private String project; - private String trigger; - - protected Builder() {} - - public String getProject() { - return project; - } - - public String getTrigger() { - return trigger; - } - - public Builder setProject(String project) { - this.project = project; - return this; - } - - public Builder setTrigger(String trigger) { - this.trigger = trigger; - return this; - } - - private Builder(BuildTriggerName buildTriggerName) { - Preconditions.checkArgument( - Objects.equals(buildTriggerName.pathTemplate, PROJECT_TRIGGER), - "toBuilder is only supported when BuildTriggerName has the pattern of projects/{project}/triggers/{trigger}"); - this.project = buildTriggerName.project; - this.trigger = buildTriggerName.trigger; - } - - public BuildTriggerName build() { - return new BuildTriggerName(this); - } - } - - /** Builder for projects/{project}/locations/{location}/triggers/{trigger}. */ - @BetaApi("The per-pattern Builders are not stable yet and may be changed in the future.") - public static class ProjectLocationTriggerBuilder { - private String project; - private String location; - private String trigger; - - protected ProjectLocationTriggerBuilder() {} - - public String getProject() { - return project; - } - - public String getLocation() { - return location; - } - - public String getTrigger() { - return trigger; - } - - public ProjectLocationTriggerBuilder setProject(String project) { - this.project = project; - return this; - } - - public ProjectLocationTriggerBuilder setLocation(String location) { - this.location = location; - return this; - } - - public ProjectLocationTriggerBuilder setTrigger(String trigger) { - this.trigger = trigger; - return this; - } - - public BuildTriggerName build() { - return new BuildTriggerName(this); - } - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildTriggerOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildTriggerOrBuilder.java deleted file mode 100644 index 751c8786..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildTriggerOrBuilder.java +++ /dev/null @@ -1,789 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface BuildTriggerOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.BuildTrigger) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The `Trigger` name with format:
-   * `projects/{project}/locations/{location}/triggers/{trigger}`, where
-   * {trigger} is a unique identifier generated by the service.
-   * 
- * - * string resource_name = 34; - * - * @return The resourceName. - */ - java.lang.String getResourceName(); - /** - * - * - *
-   * The `Trigger` name with format:
-   * `projects/{project}/locations/{location}/triggers/{trigger}`, where
-   * {trigger} is a unique identifier generated by the service.
-   * 
- * - * string resource_name = 34; - * - * @return The bytes for resourceName. - */ - com.google.protobuf.ByteString getResourceNameBytes(); - - /** - * - * - *
-   * Output only. Unique identifier of the trigger.
-   * 
- * - * string id = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The id. - */ - java.lang.String getId(); - /** - * - * - *
-   * Output only. Unique identifier of the trigger.
-   * 
- * - * string id = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The bytes for id. - */ - com.google.protobuf.ByteString getIdBytes(); - - /** - * - * - *
-   * Human-readable description of this trigger.
-   * 
- * - * string description = 10; - * - * @return The description. - */ - java.lang.String getDescription(); - /** - * - * - *
-   * Human-readable description of this trigger.
-   * 
- * - * string description = 10; - * - * @return The bytes for description. - */ - com.google.protobuf.ByteString getDescriptionBytes(); - - /** - * - * - *
-   * User-assigned name of the trigger. Must be unique within the project.
-   * Trigger names must meet the following requirements:
-   * + They must contain only alphanumeric characters and dashes.
-   * + They can be 1-64 characters long.
-   * + They must begin and end with an alphanumeric character.
-   * 
- * - * string name = 21; - * - * @return The name. - */ - java.lang.String getName(); - /** - * - * - *
-   * User-assigned name of the trigger. Must be unique within the project.
-   * Trigger names must meet the following requirements:
-   * + They must contain only alphanumeric characters and dashes.
-   * + They can be 1-64 characters long.
-   * + They must begin and end with an alphanumeric character.
-   * 
- * - * string name = 21; - * - * @return The bytes for name. - */ - com.google.protobuf.ByteString getNameBytes(); - - /** - * - * - *
-   * Tags for annotation of a `BuildTrigger`
-   * 
- * - * repeated string tags = 19; - * - * @return A list containing the tags. - */ - java.util.List getTagsList(); - /** - * - * - *
-   * Tags for annotation of a `BuildTrigger`
-   * 
- * - * repeated string tags = 19; - * - * @return The count of tags. - */ - int getTagsCount(); - /** - * - * - *
-   * Tags for annotation of a `BuildTrigger`
-   * 
- * - * repeated string tags = 19; - * - * @param index The index of the element to return. - * @return The tags at the given index. - */ - java.lang.String getTags(int index); - /** - * - * - *
-   * Tags for annotation of a `BuildTrigger`
-   * 
- * - * repeated string tags = 19; - * - * @param index The index of the value to return. - * @return The bytes of the tags at the given index. - */ - com.google.protobuf.ByteString getTagsBytes(int index); - - /** - * - * - *
-   * Template describing the types of source changes to trigger a build.
-   * Branch and tag names in trigger templates are interpreted as regular
-   * expressions. Any branch or tag change that matches that regular expression
-   * will trigger a build.
-   * Mutually exclusive with `github`.
-   * 
- * - * .google.devtools.cloudbuild.v1.RepoSource trigger_template = 7; - * - * @return Whether the triggerTemplate field is set. - */ - boolean hasTriggerTemplate(); - /** - * - * - *
-   * Template describing the types of source changes to trigger a build.
-   * Branch and tag names in trigger templates are interpreted as regular
-   * expressions. Any branch or tag change that matches that regular expression
-   * will trigger a build.
-   * Mutually exclusive with `github`.
-   * 
- * - * .google.devtools.cloudbuild.v1.RepoSource trigger_template = 7; - * - * @return The triggerTemplate. - */ - com.google.cloudbuild.v1.RepoSource getTriggerTemplate(); - /** - * - * - *
-   * Template describing the types of source changes to trigger a build.
-   * Branch and tag names in trigger templates are interpreted as regular
-   * expressions. Any branch or tag change that matches that regular expression
-   * will trigger a build.
-   * Mutually exclusive with `github`.
-   * 
- * - * .google.devtools.cloudbuild.v1.RepoSource trigger_template = 7; - */ - com.google.cloudbuild.v1.RepoSourceOrBuilder getTriggerTemplateOrBuilder(); - - /** - * - * - *
-   * GitHubEventsConfig describes the configuration of a trigger that creates
-   * a build whenever a GitHub event is received.
-   * Mutually exclusive with `trigger_template`.
-   * 
- * - * .google.devtools.cloudbuild.v1.GitHubEventsConfig github = 13; - * - * @return Whether the github field is set. - */ - boolean hasGithub(); - /** - * - * - *
-   * GitHubEventsConfig describes the configuration of a trigger that creates
-   * a build whenever a GitHub event is received.
-   * Mutually exclusive with `trigger_template`.
-   * 
- * - * .google.devtools.cloudbuild.v1.GitHubEventsConfig github = 13; - * - * @return The github. - */ - com.google.cloudbuild.v1.GitHubEventsConfig getGithub(); - /** - * - * - *
-   * GitHubEventsConfig describes the configuration of a trigger that creates
-   * a build whenever a GitHub event is received.
-   * Mutually exclusive with `trigger_template`.
-   * 
- * - * .google.devtools.cloudbuild.v1.GitHubEventsConfig github = 13; - */ - com.google.cloudbuild.v1.GitHubEventsConfigOrBuilder getGithubOrBuilder(); - - /** - * - * - *
-   * PubsubConfig describes the configuration of a trigger that
-   * creates a build whenever a Pub/Sub message is published.
-   * 
- * - * .google.devtools.cloudbuild.v1.PubsubConfig pubsub_config = 29; - * - * @return Whether the pubsubConfig field is set. - */ - boolean hasPubsubConfig(); - /** - * - * - *
-   * PubsubConfig describes the configuration of a trigger that
-   * creates a build whenever a Pub/Sub message is published.
-   * 
- * - * .google.devtools.cloudbuild.v1.PubsubConfig pubsub_config = 29; - * - * @return The pubsubConfig. - */ - com.google.cloudbuild.v1.PubsubConfig getPubsubConfig(); - /** - * - * - *
-   * PubsubConfig describes the configuration of a trigger that
-   * creates a build whenever a Pub/Sub message is published.
-   * 
- * - * .google.devtools.cloudbuild.v1.PubsubConfig pubsub_config = 29; - */ - com.google.cloudbuild.v1.PubsubConfigOrBuilder getPubsubConfigOrBuilder(); - - /** - * - * - *
-   * WebhookConfig describes the configuration of a trigger that
-   * creates a build whenever a webhook is sent to a trigger's webhook URL.
-   * 
- * - * .google.devtools.cloudbuild.v1.WebhookConfig webhook_config = 31; - * - * @return Whether the webhookConfig field is set. - */ - boolean hasWebhookConfig(); - /** - * - * - *
-   * WebhookConfig describes the configuration of a trigger that
-   * creates a build whenever a webhook is sent to a trigger's webhook URL.
-   * 
- * - * .google.devtools.cloudbuild.v1.WebhookConfig webhook_config = 31; - * - * @return The webhookConfig. - */ - com.google.cloudbuild.v1.WebhookConfig getWebhookConfig(); - /** - * - * - *
-   * WebhookConfig describes the configuration of a trigger that
-   * creates a build whenever a webhook is sent to a trigger's webhook URL.
-   * 
- * - * .google.devtools.cloudbuild.v1.WebhookConfig webhook_config = 31; - */ - com.google.cloudbuild.v1.WebhookConfigOrBuilder getWebhookConfigOrBuilder(); - - /** - * - * - *
-   * Autodetect build configuration.  The following precedence is used (case
-   * insensitive):
-   * 1. cloudbuild.yaml
-   * 2. cloudbuild.yml
-   * 3. cloudbuild.json
-   * 4. Dockerfile
-   * Currently only available for GitHub App Triggers.
-   * 
- * - * bool autodetect = 18; - * - * @return Whether the autodetect field is set. - */ - boolean hasAutodetect(); - /** - * - * - *
-   * Autodetect build configuration.  The following precedence is used (case
-   * insensitive):
-   * 1. cloudbuild.yaml
-   * 2. cloudbuild.yml
-   * 3. cloudbuild.json
-   * 4. Dockerfile
-   * Currently only available for GitHub App Triggers.
-   * 
- * - * bool autodetect = 18; - * - * @return The autodetect. - */ - boolean getAutodetect(); - - /** - * - * - *
-   * Contents of the build template.
-   * 
- * - * .google.devtools.cloudbuild.v1.Build build = 4; - * - * @return Whether the build field is set. - */ - boolean hasBuild(); - /** - * - * - *
-   * Contents of the build template.
-   * 
- * - * .google.devtools.cloudbuild.v1.Build build = 4; - * - * @return The build. - */ - com.google.cloudbuild.v1.Build getBuild(); - /** - * - * - *
-   * Contents of the build template.
-   * 
- * - * .google.devtools.cloudbuild.v1.Build build = 4; - */ - com.google.cloudbuild.v1.BuildOrBuilder getBuildOrBuilder(); - - /** - * - * - *
-   * Path, from the source root, to the build configuration file
-   * (i.e. cloudbuild.yaml).
-   * 
- * - * string filename = 8; - * - * @return Whether the filename field is set. - */ - boolean hasFilename(); - /** - * - * - *
-   * Path, from the source root, to the build configuration file
-   * (i.e. cloudbuild.yaml).
-   * 
- * - * string filename = 8; - * - * @return The filename. - */ - java.lang.String getFilename(); - /** - * - * - *
-   * Path, from the source root, to the build configuration file
-   * (i.e. cloudbuild.yaml).
-   * 
- * - * string filename = 8; - * - * @return The bytes for filename. - */ - com.google.protobuf.ByteString getFilenameBytes(); - - /** - * - * - *
-   * Output only. Time when the trigger was created.
-   * 
- * - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return Whether the createTime field is set. - */ - boolean hasCreateTime(); - /** - * - * - *
-   * Output only. Time when the trigger was created.
-   * 
- * - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The createTime. - */ - com.google.protobuf.Timestamp getCreateTime(); - /** - * - * - *
-   * Output only. Time when the trigger was created.
-   * 
- * - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder(); - - /** - * - * - *
-   * If true, the trigger will never automatically execute a build.
-   * 
- * - * bool disabled = 9; - * - * @return The disabled. - */ - boolean getDisabled(); - - /** - * - * - *
-   * Substitutions for Build resource. The keys must match the following
-   * regular expression: `^_[A-Z0-9_]+$`.
-   * 
- * - * map<string, string> substitutions = 11; - */ - int getSubstitutionsCount(); - /** - * - * - *
-   * Substitutions for Build resource. The keys must match the following
-   * regular expression: `^_[A-Z0-9_]+$`.
-   * 
- * - * map<string, string> substitutions = 11; - */ - boolean containsSubstitutions(java.lang.String key); - /** Use {@link #getSubstitutionsMap()} instead. */ - @java.lang.Deprecated - java.util.Map getSubstitutions(); - /** - * - * - *
-   * Substitutions for Build resource. The keys must match the following
-   * regular expression: `^_[A-Z0-9_]+$`.
-   * 
- * - * map<string, string> substitutions = 11; - */ - java.util.Map getSubstitutionsMap(); - /** - * - * - *
-   * Substitutions for Build resource. The keys must match the following
-   * regular expression: `^_[A-Z0-9_]+$`.
-   * 
- * - * map<string, string> substitutions = 11; - */ - - /* nullable */ - java.lang.String getSubstitutionsOrDefault( - java.lang.String key, - /* nullable */ - java.lang.String defaultValue); - /** - * - * - *
-   * Substitutions for Build resource. The keys must match the following
-   * regular expression: `^_[A-Z0-9_]+$`.
-   * 
- * - * map<string, string> substitutions = 11; - */ - java.lang.String getSubstitutionsOrThrow(java.lang.String key); - - /** - * - * - *
-   * ignored_files and included_files are file glob matches using
-   * https://golang.org/pkg/path/filepath/#Match extended with support for "**".
-   * If ignored_files and changed files are both empty, then they are
-   * not used to determine whether or not to trigger a build.
-   * If ignored_files is not empty, then we ignore any files that match
-   * any of the ignored_file globs. If the change has no files that are
-   * outside of the ignored_files globs, then we do not trigger a build.
-   * 
- * - * repeated string ignored_files = 15; - * - * @return A list containing the ignoredFiles. - */ - java.util.List getIgnoredFilesList(); - /** - * - * - *
-   * ignored_files and included_files are file glob matches using
-   * https://golang.org/pkg/path/filepath/#Match extended with support for "**".
-   * If ignored_files and changed files are both empty, then they are
-   * not used to determine whether or not to trigger a build.
-   * If ignored_files is not empty, then we ignore any files that match
-   * any of the ignored_file globs. If the change has no files that are
-   * outside of the ignored_files globs, then we do not trigger a build.
-   * 
- * - * repeated string ignored_files = 15; - * - * @return The count of ignoredFiles. - */ - int getIgnoredFilesCount(); - /** - * - * - *
-   * ignored_files and included_files are file glob matches using
-   * https://golang.org/pkg/path/filepath/#Match extended with support for "**".
-   * If ignored_files and changed files are both empty, then they are
-   * not used to determine whether or not to trigger a build.
-   * If ignored_files is not empty, then we ignore any files that match
-   * any of the ignored_file globs. If the change has no files that are
-   * outside of the ignored_files globs, then we do not trigger a build.
-   * 
- * - * repeated string ignored_files = 15; - * - * @param index The index of the element to return. - * @return The ignoredFiles at the given index. - */ - java.lang.String getIgnoredFiles(int index); - /** - * - * - *
-   * ignored_files and included_files are file glob matches using
-   * https://golang.org/pkg/path/filepath/#Match extended with support for "**".
-   * If ignored_files and changed files are both empty, then they are
-   * not used to determine whether or not to trigger a build.
-   * If ignored_files is not empty, then we ignore any files that match
-   * any of the ignored_file globs. If the change has no files that are
-   * outside of the ignored_files globs, then we do not trigger a build.
-   * 
- * - * repeated string ignored_files = 15; - * - * @param index The index of the value to return. - * @return The bytes of the ignoredFiles at the given index. - */ - com.google.protobuf.ByteString getIgnoredFilesBytes(int index); - - /** - * - * - *
-   * If any of the files altered in the commit pass the ignored_files
-   * filter and included_files is empty, then as far as this filter is
-   * concerned, we should trigger the build.
-   * If any of the files altered in the commit pass the ignored_files
-   * filter and included_files is not empty, then we make sure that at
-   * least one of those files matches a included_files glob. If not,
-   * then we do not trigger a build.
-   * 
- * - * repeated string included_files = 16; - * - * @return A list containing the includedFiles. - */ - java.util.List getIncludedFilesList(); - /** - * - * - *
-   * If any of the files altered in the commit pass the ignored_files
-   * filter and included_files is empty, then as far as this filter is
-   * concerned, we should trigger the build.
-   * If any of the files altered in the commit pass the ignored_files
-   * filter and included_files is not empty, then we make sure that at
-   * least one of those files matches a included_files glob. If not,
-   * then we do not trigger a build.
-   * 
- * - * repeated string included_files = 16; - * - * @return The count of includedFiles. - */ - int getIncludedFilesCount(); - /** - * - * - *
-   * If any of the files altered in the commit pass the ignored_files
-   * filter and included_files is empty, then as far as this filter is
-   * concerned, we should trigger the build.
-   * If any of the files altered in the commit pass the ignored_files
-   * filter and included_files is not empty, then we make sure that at
-   * least one of those files matches a included_files glob. If not,
-   * then we do not trigger a build.
-   * 
- * - * repeated string included_files = 16; - * - * @param index The index of the element to return. - * @return The includedFiles at the given index. - */ - java.lang.String getIncludedFiles(int index); - /** - * - * - *
-   * If any of the files altered in the commit pass the ignored_files
-   * filter and included_files is empty, then as far as this filter is
-   * concerned, we should trigger the build.
-   * If any of the files altered in the commit pass the ignored_files
-   * filter and included_files is not empty, then we make sure that at
-   * least one of those files matches a included_files glob. If not,
-   * then we do not trigger a build.
-   * 
- * - * repeated string included_files = 16; - * - * @param index The index of the value to return. - * @return The bytes of the includedFiles at the given index. - */ - com.google.protobuf.ByteString getIncludedFilesBytes(int index); - - /** - * - * - *
-   * Optional. A Common Expression Language string.
-   * 
- * - * string filter = 30 [(.google.api.field_behavior) = OPTIONAL]; - * - * @return The filter. - */ - java.lang.String getFilter(); - /** - * - * - *
-   * Optional. A Common Expression Language string.
-   * 
- * - * string filter = 30 [(.google.api.field_behavior) = OPTIONAL]; - * - * @return The bytes for filter. - */ - com.google.protobuf.ByteString getFilterBytes(); - - /** - * - * - *
-   * The service account used for all user-controlled operations including
-   * UpdateBuildTrigger, RunBuildTrigger, CreateBuild, and CancelBuild.
-   * If no service account is set, then the standard Cloud Build service account
-   * ([PROJECT_NUM]@system.gserviceaccount.com) will be used instead.
-   * Format: `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT_ID_OR_EMAIL}`
-   * 
- * - * string service_account = 33 [(.google.api.resource_reference) = { ... } - * - * @return The serviceAccount. - */ - java.lang.String getServiceAccount(); - /** - * - * - *
-   * The service account used for all user-controlled operations including
-   * UpdateBuildTrigger, RunBuildTrigger, CreateBuild, and CancelBuild.
-   * If no service account is set, then the standard Cloud Build service account
-   * ([PROJECT_NUM]@system.gserviceaccount.com) will be used instead.
-   * Format: `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT_ID_OR_EMAIL}`
-   * 
- * - * string service_account = 33 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for serviceAccount. - */ - com.google.protobuf.ByteString getServiceAccountBytes(); - - public com.google.cloudbuild.v1.BuildTrigger.BuildTemplateCase getBuildTemplateCase(); -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuiltImage.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuiltImage.java deleted file mode 100644 index e1c862ff..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuiltImage.java +++ /dev/null @@ -1,1087 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * An image built by the pipeline.
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.BuiltImage} - */ -public final class BuiltImage extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.BuiltImage) - BuiltImageOrBuilder { - private static final long serialVersionUID = 0L; - // Use BuiltImage.newBuilder() to construct. - private BuiltImage(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private BuiltImage() { - name_ = ""; - digest_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new BuiltImage(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_BuiltImage_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_BuiltImage_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.BuiltImage.class, - com.google.cloudbuild.v1.BuiltImage.Builder.class); - } - - public static final int NAME_FIELD_NUMBER = 1; - private volatile java.lang.Object name_; - /** - * - * - *
-   * Name used to push the container image to Google Container Registry, as
-   * presented to `docker push`.
-   * 
- * - * string name = 1; - * - * @return The name. - */ - @java.lang.Override - public java.lang.String getName() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - name_ = s; - return s; - } - } - /** - * - * - *
-   * Name used to push the container image to Google Container Registry, as
-   * presented to `docker push`.
-   * 
- * - * string name = 1; - * - * @return The bytes for name. - */ - @java.lang.Override - public com.google.protobuf.ByteString getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int DIGEST_FIELD_NUMBER = 3; - private volatile java.lang.Object digest_; - /** - * - * - *
-   * Docker Registry 2.0 digest.
-   * 
- * - * string digest = 3; - * - * @return The digest. - */ - @java.lang.Override - public java.lang.String getDigest() { - java.lang.Object ref = digest_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - digest_ = s; - return s; - } - } - /** - * - * - *
-   * Docker Registry 2.0 digest.
-   * 
- * - * string digest = 3; - * - * @return The bytes for digest. - */ - @java.lang.Override - public com.google.protobuf.ByteString getDigestBytes() { - java.lang.Object ref = digest_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - digest_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int PUSH_TIMING_FIELD_NUMBER = 4; - private com.google.cloudbuild.v1.TimeSpan pushTiming_; - /** - * - * - *
-   * Output only. Stores timing information for pushing the specified image.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan push_timing = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return Whether the pushTiming field is set. - */ - @java.lang.Override - public boolean hasPushTiming() { - return pushTiming_ != null; - } - /** - * - * - *
-   * Output only. Stores timing information for pushing the specified image.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan push_timing = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The pushTiming. - */ - @java.lang.Override - public com.google.cloudbuild.v1.TimeSpan getPushTiming() { - return pushTiming_ == null - ? com.google.cloudbuild.v1.TimeSpan.getDefaultInstance() - : pushTiming_; - } - /** - * - * - *
-   * Output only. Stores timing information for pushing the specified image.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan push_timing = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - @java.lang.Override - public com.google.cloudbuild.v1.TimeSpanOrBuilder getPushTimingOrBuilder() { - return getPushTiming(); - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(digest_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 3, digest_); - } - if (pushTiming_ != null) { - output.writeMessage(4, getPushTiming()); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(digest_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, digest_); - } - if (pushTiming_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, getPushTiming()); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.BuiltImage)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.BuiltImage other = (com.google.cloudbuild.v1.BuiltImage) obj; - - if (!getName().equals(other.getName())) return false; - if (!getDigest().equals(other.getDigest())) return false; - if (hasPushTiming() != other.hasPushTiming()) return false; - if (hasPushTiming()) { - if (!getPushTiming().equals(other.getPushTiming())) return false; - } - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + NAME_FIELD_NUMBER; - hash = (53 * hash) + getName().hashCode(); - hash = (37 * hash) + DIGEST_FIELD_NUMBER; - hash = (53 * hash) + getDigest().hashCode(); - if (hasPushTiming()) { - hash = (37 * hash) + PUSH_TIMING_FIELD_NUMBER; - hash = (53 * hash) + getPushTiming().hashCode(); - } - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.BuiltImage parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.BuiltImage parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.BuiltImage parseFrom(com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.BuiltImage parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.BuiltImage parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.BuiltImage parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.BuiltImage parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.BuiltImage parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.BuiltImage parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.BuiltImage parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.BuiltImage parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.BuiltImage parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.BuiltImage prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * An image built by the pipeline.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.BuiltImage} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.BuiltImage) - com.google.cloudbuild.v1.BuiltImageOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_BuiltImage_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_BuiltImage_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.BuiltImage.class, - com.google.cloudbuild.v1.BuiltImage.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.BuiltImage.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - name_ = ""; - - digest_ = ""; - - if (pushTimingBuilder_ == null) { - pushTiming_ = null; - } else { - pushTiming_ = null; - pushTimingBuilder_ = null; - } - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_BuiltImage_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.BuiltImage getDefaultInstanceForType() { - return com.google.cloudbuild.v1.BuiltImage.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.BuiltImage build() { - com.google.cloudbuild.v1.BuiltImage result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.BuiltImage buildPartial() { - com.google.cloudbuild.v1.BuiltImage result = new com.google.cloudbuild.v1.BuiltImage(this); - result.name_ = name_; - result.digest_ = digest_; - if (pushTimingBuilder_ == null) { - result.pushTiming_ = pushTiming_; - } else { - result.pushTiming_ = pushTimingBuilder_.build(); - } - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.BuiltImage) { - return mergeFrom((com.google.cloudbuild.v1.BuiltImage) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.BuiltImage other) { - if (other == com.google.cloudbuild.v1.BuiltImage.getDefaultInstance()) return this; - if (!other.getName().isEmpty()) { - name_ = other.name_; - onChanged(); - } - if (!other.getDigest().isEmpty()) { - digest_ = other.digest_; - onChanged(); - } - if (other.hasPushTiming()) { - mergePushTiming(other.getPushTiming()); - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - name_ = input.readStringRequireUtf8(); - - break; - } // case 10 - case 26: - { - digest_ = input.readStringRequireUtf8(); - - break; - } // case 26 - case 34: - { - input.readMessage(getPushTimingFieldBuilder().getBuilder(), extensionRegistry); - - break; - } // case 34 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private java.lang.Object name_ = ""; - /** - * - * - *
-     * Name used to push the container image to Google Container Registry, as
-     * presented to `docker push`.
-     * 
- * - * string name = 1; - * - * @return The name. - */ - public java.lang.String getName() { - java.lang.Object ref = name_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - name_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Name used to push the container image to Google Container Registry, as
-     * presented to `docker push`.
-     * 
- * - * string name = 1; - * - * @return The bytes for name. - */ - public com.google.protobuf.ByteString getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Name used to push the container image to Google Container Registry, as
-     * presented to `docker push`.
-     * 
- * - * string name = 1; - * - * @param value The name to set. - * @return This builder for chaining. - */ - public Builder setName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - name_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Name used to push the container image to Google Container Registry, as
-     * presented to `docker push`.
-     * 
- * - * string name = 1; - * - * @return This builder for chaining. - */ - public Builder clearName() { - - name_ = getDefaultInstance().getName(); - onChanged(); - return this; - } - /** - * - * - *
-     * Name used to push the container image to Google Container Registry, as
-     * presented to `docker push`.
-     * 
- * - * string name = 1; - * - * @param value The bytes for name to set. - * @return This builder for chaining. - */ - public Builder setNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - name_ = value; - onChanged(); - return this; - } - - private java.lang.Object digest_ = ""; - /** - * - * - *
-     * Docker Registry 2.0 digest.
-     * 
- * - * string digest = 3; - * - * @return The digest. - */ - public java.lang.String getDigest() { - java.lang.Object ref = digest_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - digest_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Docker Registry 2.0 digest.
-     * 
- * - * string digest = 3; - * - * @return The bytes for digest. - */ - public com.google.protobuf.ByteString getDigestBytes() { - java.lang.Object ref = digest_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - digest_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Docker Registry 2.0 digest.
-     * 
- * - * string digest = 3; - * - * @param value The digest to set. - * @return This builder for chaining. - */ - public Builder setDigest(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - digest_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Docker Registry 2.0 digest.
-     * 
- * - * string digest = 3; - * - * @return This builder for chaining. - */ - public Builder clearDigest() { - - digest_ = getDefaultInstance().getDigest(); - onChanged(); - return this; - } - /** - * - * - *
-     * Docker Registry 2.0 digest.
-     * 
- * - * string digest = 3; - * - * @param value The bytes for digest to set. - * @return This builder for chaining. - */ - public Builder setDigestBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - digest_ = value; - onChanged(); - return this; - } - - private com.google.cloudbuild.v1.TimeSpan pushTiming_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.TimeSpan, - com.google.cloudbuild.v1.TimeSpan.Builder, - com.google.cloudbuild.v1.TimeSpanOrBuilder> - pushTimingBuilder_; - /** - * - * - *
-     * Output only. Stores timing information for pushing the specified image.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan push_timing = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return Whether the pushTiming field is set. - */ - public boolean hasPushTiming() { - return pushTimingBuilder_ != null || pushTiming_ != null; - } - /** - * - * - *
-     * Output only. Stores timing information for pushing the specified image.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan push_timing = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The pushTiming. - */ - public com.google.cloudbuild.v1.TimeSpan getPushTiming() { - if (pushTimingBuilder_ == null) { - return pushTiming_ == null - ? com.google.cloudbuild.v1.TimeSpan.getDefaultInstance() - : pushTiming_; - } else { - return pushTimingBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Output only. Stores timing information for pushing the specified image.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan push_timing = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder setPushTiming(com.google.cloudbuild.v1.TimeSpan value) { - if (pushTimingBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - pushTiming_ = value; - onChanged(); - } else { - pushTimingBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * Output only. Stores timing information for pushing the specified image.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan push_timing = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder setPushTiming(com.google.cloudbuild.v1.TimeSpan.Builder builderForValue) { - if (pushTimingBuilder_ == null) { - pushTiming_ = builderForValue.build(); - onChanged(); - } else { - pushTimingBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Output only. Stores timing information for pushing the specified image.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan push_timing = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder mergePushTiming(com.google.cloudbuild.v1.TimeSpan value) { - if (pushTimingBuilder_ == null) { - if (pushTiming_ != null) { - pushTiming_ = - com.google.cloudbuild.v1.TimeSpan.newBuilder(pushTiming_) - .mergeFrom(value) - .buildPartial(); - } else { - pushTiming_ = value; - } - onChanged(); - } else { - pushTimingBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * Output only. Stores timing information for pushing the specified image.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan push_timing = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder clearPushTiming() { - if (pushTimingBuilder_ == null) { - pushTiming_ = null; - onChanged(); - } else { - pushTiming_ = null; - pushTimingBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Output only. Stores timing information for pushing the specified image.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan push_timing = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public com.google.cloudbuild.v1.TimeSpan.Builder getPushTimingBuilder() { - - onChanged(); - return getPushTimingFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Output only. Stores timing information for pushing the specified image.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan push_timing = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public com.google.cloudbuild.v1.TimeSpanOrBuilder getPushTimingOrBuilder() { - if (pushTimingBuilder_ != null) { - return pushTimingBuilder_.getMessageOrBuilder(); - } else { - return pushTiming_ == null - ? com.google.cloudbuild.v1.TimeSpan.getDefaultInstance() - : pushTiming_; - } - } - /** - * - * - *
-     * Output only. Stores timing information for pushing the specified image.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan push_timing = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.TimeSpan, - com.google.cloudbuild.v1.TimeSpan.Builder, - com.google.cloudbuild.v1.TimeSpanOrBuilder> - getPushTimingFieldBuilder() { - if (pushTimingBuilder_ == null) { - pushTimingBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.TimeSpan, - com.google.cloudbuild.v1.TimeSpan.Builder, - com.google.cloudbuild.v1.TimeSpanOrBuilder>( - getPushTiming(), getParentForChildren(), isClean()); - pushTiming_ = null; - } - return pushTimingBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.BuiltImage) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.BuiltImage) - private static final com.google.cloudbuild.v1.BuiltImage DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.BuiltImage(); - } - - public static com.google.cloudbuild.v1.BuiltImage getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public BuiltImage parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.BuiltImage getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuiltImageOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuiltImageOrBuilder.java deleted file mode 100644 index 25242d4e..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuiltImageOrBuilder.java +++ /dev/null @@ -1,118 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface BuiltImageOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.BuiltImage) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * Name used to push the container image to Google Container Registry, as
-   * presented to `docker push`.
-   * 
- * - * string name = 1; - * - * @return The name. - */ - java.lang.String getName(); - /** - * - * - *
-   * Name used to push the container image to Google Container Registry, as
-   * presented to `docker push`.
-   * 
- * - * string name = 1; - * - * @return The bytes for name. - */ - com.google.protobuf.ByteString getNameBytes(); - - /** - * - * - *
-   * Docker Registry 2.0 digest.
-   * 
- * - * string digest = 3; - * - * @return The digest. - */ - java.lang.String getDigest(); - /** - * - * - *
-   * Docker Registry 2.0 digest.
-   * 
- * - * string digest = 3; - * - * @return The bytes for digest. - */ - com.google.protobuf.ByteString getDigestBytes(); - - /** - * - * - *
-   * Output only. Stores timing information for pushing the specified image.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan push_timing = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return Whether the pushTiming field is set. - */ - boolean hasPushTiming(); - /** - * - * - *
-   * Output only. Stores timing information for pushing the specified image.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan push_timing = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The pushTiming. - */ - com.google.cloudbuild.v1.TimeSpan getPushTiming(); - /** - * - * - *
-   * Output only. Stores timing information for pushing the specified image.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.TimeSpan push_timing = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - com.google.cloudbuild.v1.TimeSpanOrBuilder getPushTimingOrBuilder(); -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CancelBuildRequest.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CancelBuildRequest.java deleted file mode 100644 index a3fa1cc6..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CancelBuildRequest.java +++ /dev/null @@ -1,977 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * Request to cancel an ongoing build.
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.CancelBuildRequest} - */ -public final class CancelBuildRequest extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.CancelBuildRequest) - CancelBuildRequestOrBuilder { - private static final long serialVersionUID = 0L; - // Use CancelBuildRequest.newBuilder() to construct. - private CancelBuildRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private CancelBuildRequest() { - name_ = ""; - projectId_ = ""; - id_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new CancelBuildRequest(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_CancelBuildRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_CancelBuildRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.CancelBuildRequest.class, - com.google.cloudbuild.v1.CancelBuildRequest.Builder.class); - } - - public static final int NAME_FIELD_NUMBER = 4; - private volatile java.lang.Object name_; - /** - * - * - *
-   * The name of the `Build` to cancel.
-   * Format: `projects/{project}/locations/{location}/builds/{build}`
-   * 
- * - * string name = 4 [(.google.api.resource_reference) = { ... } - * - * @return The name. - */ - @java.lang.Override - public java.lang.String getName() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - name_ = s; - return s; - } - } - /** - * - * - *
-   * The name of the `Build` to cancel.
-   * Format: `projects/{project}/locations/{location}/builds/{build}`
-   * 
- * - * string name = 4 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for name. - */ - @java.lang.Override - public com.google.protobuf.ByteString getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int PROJECT_ID_FIELD_NUMBER = 1; - private volatile java.lang.Object projectId_; - /** - * - * - *
-   * Required. ID of the project.
-   * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The projectId. - */ - @java.lang.Override - public java.lang.String getProjectId() { - java.lang.Object ref = projectId_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - projectId_ = s; - return s; - } - } - /** - * - * - *
-   * Required. ID of the project.
-   * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for projectId. - */ - @java.lang.Override - public com.google.protobuf.ByteString getProjectIdBytes() { - java.lang.Object ref = projectId_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - projectId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int ID_FIELD_NUMBER = 2; - private volatile java.lang.Object id_; - /** - * - * - *
-   * Required. ID of the build.
-   * 
- * - * string id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The id. - */ - @java.lang.Override - public java.lang.String getId() { - java.lang.Object ref = id_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - id_ = s; - return s; - } - } - /** - * - * - *
-   * Required. ID of the build.
-   * 
- * - * string id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for id. - */ - @java.lang.Override - public com.google.protobuf.ByteString getIdBytes() { - java.lang.Object ref = id_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - id_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(projectId_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, projectId_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(id_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, id_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 4, name_); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(projectId_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, projectId_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(id_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, id_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, name_); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.CancelBuildRequest)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.CancelBuildRequest other = - (com.google.cloudbuild.v1.CancelBuildRequest) obj; - - if (!getName().equals(other.getName())) return false; - if (!getProjectId().equals(other.getProjectId())) return false; - if (!getId().equals(other.getId())) return false; - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + NAME_FIELD_NUMBER; - hash = (53 * hash) + getName().hashCode(); - hash = (37 * hash) + PROJECT_ID_FIELD_NUMBER; - hash = (53 * hash) + getProjectId().hashCode(); - hash = (37 * hash) + ID_FIELD_NUMBER; - hash = (53 * hash) + getId().hashCode(); - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.CancelBuildRequest parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.CancelBuildRequest parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.CancelBuildRequest parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.CancelBuildRequest parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.CancelBuildRequest parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.CancelBuildRequest parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.CancelBuildRequest parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.CancelBuildRequest parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.CancelBuildRequest parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.CancelBuildRequest parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.CancelBuildRequest parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.CancelBuildRequest parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.CancelBuildRequest prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * Request to cancel an ongoing build.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.CancelBuildRequest} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.CancelBuildRequest) - com.google.cloudbuild.v1.CancelBuildRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_CancelBuildRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_CancelBuildRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.CancelBuildRequest.class, - com.google.cloudbuild.v1.CancelBuildRequest.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.CancelBuildRequest.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - name_ = ""; - - projectId_ = ""; - - id_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_CancelBuildRequest_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.CancelBuildRequest getDefaultInstanceForType() { - return com.google.cloudbuild.v1.CancelBuildRequest.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.CancelBuildRequest build() { - com.google.cloudbuild.v1.CancelBuildRequest result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.CancelBuildRequest buildPartial() { - com.google.cloudbuild.v1.CancelBuildRequest result = - new com.google.cloudbuild.v1.CancelBuildRequest(this); - result.name_ = name_; - result.projectId_ = projectId_; - result.id_ = id_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.CancelBuildRequest) { - return mergeFrom((com.google.cloudbuild.v1.CancelBuildRequest) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.CancelBuildRequest other) { - if (other == com.google.cloudbuild.v1.CancelBuildRequest.getDefaultInstance()) return this; - if (!other.getName().isEmpty()) { - name_ = other.name_; - onChanged(); - } - if (!other.getProjectId().isEmpty()) { - projectId_ = other.projectId_; - onChanged(); - } - if (!other.getId().isEmpty()) { - id_ = other.id_; - onChanged(); - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - projectId_ = input.readStringRequireUtf8(); - - break; - } // case 10 - case 18: - { - id_ = input.readStringRequireUtf8(); - - break; - } // case 18 - case 34: - { - name_ = input.readStringRequireUtf8(); - - break; - } // case 34 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private java.lang.Object name_ = ""; - /** - * - * - *
-     * The name of the `Build` to cancel.
-     * Format: `projects/{project}/locations/{location}/builds/{build}`
-     * 
- * - * string name = 4 [(.google.api.resource_reference) = { ... } - * - * @return The name. - */ - public java.lang.String getName() { - java.lang.Object ref = name_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - name_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * The name of the `Build` to cancel.
-     * Format: `projects/{project}/locations/{location}/builds/{build}`
-     * 
- * - * string name = 4 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for name. - */ - public com.google.protobuf.ByteString getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * The name of the `Build` to cancel.
-     * Format: `projects/{project}/locations/{location}/builds/{build}`
-     * 
- * - * string name = 4 [(.google.api.resource_reference) = { ... } - * - * @param value The name to set. - * @return This builder for chaining. - */ - public Builder setName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - name_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the `Build` to cancel.
-     * Format: `projects/{project}/locations/{location}/builds/{build}`
-     * 
- * - * string name = 4 [(.google.api.resource_reference) = { ... } - * - * @return This builder for chaining. - */ - public Builder clearName() { - - name_ = getDefaultInstance().getName(); - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the `Build` to cancel.
-     * Format: `projects/{project}/locations/{location}/builds/{build}`
-     * 
- * - * string name = 4 [(.google.api.resource_reference) = { ... } - * - * @param value The bytes for name to set. - * @return This builder for chaining. - */ - public Builder setNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - name_ = value; - onChanged(); - return this; - } - - private java.lang.Object projectId_ = ""; - /** - * - * - *
-     * Required. ID of the project.
-     * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The projectId. - */ - public java.lang.String getProjectId() { - java.lang.Object ref = projectId_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - projectId_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Required. ID of the project.
-     * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for projectId. - */ - public com.google.protobuf.ByteString getProjectIdBytes() { - java.lang.Object ref = projectId_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - projectId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Required. ID of the project.
-     * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @param value The projectId to set. - * @return This builder for chaining. - */ - public Builder setProjectId(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - projectId_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Required. ID of the project.
-     * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return This builder for chaining. - */ - public Builder clearProjectId() { - - projectId_ = getDefaultInstance().getProjectId(); - onChanged(); - return this; - } - /** - * - * - *
-     * Required. ID of the project.
-     * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @param value The bytes for projectId to set. - * @return This builder for chaining. - */ - public Builder setProjectIdBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - projectId_ = value; - onChanged(); - return this; - } - - private java.lang.Object id_ = ""; - /** - * - * - *
-     * Required. ID of the build.
-     * 
- * - * string id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The id. - */ - public java.lang.String getId() { - java.lang.Object ref = id_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - id_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Required. ID of the build.
-     * 
- * - * string id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for id. - */ - public com.google.protobuf.ByteString getIdBytes() { - java.lang.Object ref = id_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - id_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Required. ID of the build.
-     * 
- * - * string id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @param value The id to set. - * @return This builder for chaining. - */ - public Builder setId(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - id_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Required. ID of the build.
-     * 
- * - * string id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @return This builder for chaining. - */ - public Builder clearId() { - - id_ = getDefaultInstance().getId(); - onChanged(); - return this; - } - /** - * - * - *
-     * Required. ID of the build.
-     * 
- * - * string id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @param value The bytes for id to set. - * @return This builder for chaining. - */ - public Builder setIdBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - id_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.CancelBuildRequest) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.CancelBuildRequest) - private static final com.google.cloudbuild.v1.CancelBuildRequest DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.CancelBuildRequest(); - } - - public static com.google.cloudbuild.v1.CancelBuildRequest getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public CancelBuildRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.CancelBuildRequest getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CancelBuildRequestOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CancelBuildRequestOrBuilder.java deleted file mode 100644 index 724e092e..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CancelBuildRequestOrBuilder.java +++ /dev/null @@ -1,102 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface CancelBuildRequestOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.CancelBuildRequest) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The name of the `Build` to cancel.
-   * Format: `projects/{project}/locations/{location}/builds/{build}`
-   * 
- * - * string name = 4 [(.google.api.resource_reference) = { ... } - * - * @return The name. - */ - java.lang.String getName(); - /** - * - * - *
-   * The name of the `Build` to cancel.
-   * Format: `projects/{project}/locations/{location}/builds/{build}`
-   * 
- * - * string name = 4 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for name. - */ - com.google.protobuf.ByteString getNameBytes(); - - /** - * - * - *
-   * Required. ID of the project.
-   * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The projectId. - */ - java.lang.String getProjectId(); - /** - * - * - *
-   * Required. ID of the project.
-   * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for projectId. - */ - com.google.protobuf.ByteString getProjectIdBytes(); - - /** - * - * - *
-   * Required. ID of the build.
-   * 
- * - * string id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The id. - */ - java.lang.String getId(); - /** - * - * - *
-   * Required. ID of the build.
-   * 
- * - * string id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for id. - */ - com.google.protobuf.ByteString getIdBytes(); -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Cloudbuild.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Cloudbuild.java deleted file mode 100644 index ed1609e7..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Cloudbuild.java +++ /dev/null @@ -1,1550 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public final class Cloudbuild { - private Cloudbuild() {} - - public static void registerAllExtensions(com.google.protobuf.ExtensionRegistryLite registry) {} - - public static void registerAllExtensions(com.google.protobuf.ExtensionRegistry registry) { - registerAllExtensions((com.google.protobuf.ExtensionRegistryLite) registry); - } - - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_RetryBuildRequest_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_RetryBuildRequest_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_RunBuildTriggerRequest_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_RunBuildTriggerRequest_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_StorageSource_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_StorageSource_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_RepoSource_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_RepoSource_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_RepoSource_SubstitutionsEntry_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_RepoSource_SubstitutionsEntry_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_StorageSourceManifest_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_StorageSourceManifest_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_Source_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_Source_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_BuiltImage_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_BuiltImage_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_BuildStep_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_BuildStep_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_Volume_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_Volume_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_Results_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_Results_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_ArtifactResult_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_ArtifactResult_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_Build_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_Build_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_Build_Warning_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_Build_Warning_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_Build_FailureInfo_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_Build_FailureInfo_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_Build_SubstitutionsEntry_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_Build_SubstitutionsEntry_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_Build_TimingEntry_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_Build_TimingEntry_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_Artifacts_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_Artifacts_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_Artifacts_ArtifactObjects_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_Artifacts_ArtifactObjects_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_TimeSpan_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_TimeSpan_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_BuildOperationMetadata_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_BuildOperationMetadata_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_SourceProvenance_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_SourceProvenance_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_SourceProvenance_FileHashesEntry_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_SourceProvenance_FileHashesEntry_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_FileHashes_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_FileHashes_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_Hash_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_Hash_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_Secrets_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_Secrets_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_InlineSecret_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_InlineSecret_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_InlineSecret_EnvMapEntry_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_InlineSecret_EnvMapEntry_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_SecretManagerSecret_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_SecretManagerSecret_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_Secret_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_Secret_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_Secret_SecretEnvEntry_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_Secret_SecretEnvEntry_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_CreateBuildRequest_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_CreateBuildRequest_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_GetBuildRequest_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_GetBuildRequest_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_ListBuildsRequest_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_ListBuildsRequest_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_ListBuildsResponse_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_ListBuildsResponse_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_CancelBuildRequest_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_CancelBuildRequest_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_ApproveBuildRequest_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_ApproveBuildRequest_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_BuildApproval_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_BuildApproval_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_ApprovalConfig_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_ApprovalConfig_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_ApprovalResult_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_ApprovalResult_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_BuildTrigger_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_BuildTrigger_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_BuildTrigger_SubstitutionsEntry_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_BuildTrigger_SubstitutionsEntry_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_GitHubEventsConfig_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_GitHubEventsConfig_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_PubsubConfig_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_PubsubConfig_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_WebhookConfig_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_WebhookConfig_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_PullRequestFilter_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_PullRequestFilter_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_PushFilter_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_PushFilter_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_CreateBuildTriggerRequest_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_CreateBuildTriggerRequest_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_GetBuildTriggerRequest_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_GetBuildTriggerRequest_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_ListBuildTriggersRequest_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_ListBuildTriggersRequest_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_ListBuildTriggersResponse_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_ListBuildTriggersResponse_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_DeleteBuildTriggerRequest_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_DeleteBuildTriggerRequest_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_UpdateBuildTriggerRequest_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_UpdateBuildTriggerRequest_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_BuildOptions_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_BuildOptions_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_BuildOptions_PoolOption_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_BuildOptions_PoolOption_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_ReceiveTriggerWebhookRequest_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_ReceiveTriggerWebhookRequest_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_ReceiveTriggerWebhookResponse_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_ReceiveTriggerWebhookResponse_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_WorkerPool_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_WorkerPool_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_WorkerPool_AnnotationsEntry_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_WorkerPool_AnnotationsEntry_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_PrivatePoolV1Config_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_PrivatePoolV1Config_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_PrivatePoolV1Config_WorkerConfig_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_PrivatePoolV1Config_WorkerConfig_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_PrivatePoolV1Config_NetworkConfig_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_PrivatePoolV1Config_NetworkConfig_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_CreateWorkerPoolRequest_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_CreateWorkerPoolRequest_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_GetWorkerPoolRequest_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_GetWorkerPoolRequest_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_DeleteWorkerPoolRequest_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_DeleteWorkerPoolRequest_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_UpdateWorkerPoolRequest_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_UpdateWorkerPoolRequest_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_ListWorkerPoolsRequest_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_ListWorkerPoolsRequest_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_ListWorkerPoolsResponse_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_ListWorkerPoolsResponse_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_CreateWorkerPoolOperationMetadata_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_CreateWorkerPoolOperationMetadata_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_UpdateWorkerPoolOperationMetadata_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_UpdateWorkerPoolOperationMetadata_fieldAccessorTable; - static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_devtools_cloudbuild_v1_DeleteWorkerPoolOperationMetadata_descriptor; - static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internal_static_google_devtools_cloudbuild_v1_DeleteWorkerPoolOperationMetadata_fieldAccessorTable; - - public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { - return descriptor; - } - - private static com.google.protobuf.Descriptors.FileDescriptor descriptor; - - static { - java.lang.String[] descriptorData = { - "\n.google/devtools/cloudbuild/v1/cloudbui" - + "ld.proto\022\035google.devtools.cloudbuild.v1\032" - + "\034google/api/annotations.proto\032\027google/ap" - + "i/client.proto\032\037google/api/field_behavio" - + "r.proto\032\031google/api/httpbody.proto\032\031goog" - + "le/api/resource.proto\032#google/longrunnin" - + "g/operations.proto\032\036google/protobuf/dura" - + "tion.proto\032\033google/protobuf/empty.proto\032" - + " google/protobuf/field_mask.proto\032\037googl" - + "e/protobuf/timestamp.proto\"q\n\021RetryBuild" - + "Request\0222\n\004name\030\003 \001(\tB$\372A!\n\037cloudbuild.g" - + "oogleapis.com/Build\022\027\n\nproject_id\030\001 \001(\tB" - + "\003\340A\002\022\017\n\002id\030\002 \001(\tB\003\340A\002\"\300\001\n\026RunBuildTrigge" - + "rRequest\0229\n\004name\030\004 \001(\tB+\372A(\n&cloudbuild." - + "googleapis.com/BuildTrigger\022\027\n\nproject_i" - + "d\030\001 \001(\tB\003\340A\002\022\027\n\ntrigger_id\030\002 \001(\tB\003\340A\002\0229\n" - + "\006source\030\003 \001(\0132).google.devtools.cloudbui" - + "ld.v1.RepoSource\"C\n\rStorageSource\022\016\n\006buc" - + "ket\030\001 \001(\t\022\016\n\006object\030\002 \001(\t\022\022\n\ngeneration\030" - + "\003 \001(\003\"\256\002\n\nRepoSource\022\022\n\nproject_id\030\001 \001(\t" - + "\022\021\n\trepo_name\030\002 \001(\t\022\025\n\013branch_name\030\003 \001(\t" - + "H\000\022\022\n\010tag_name\030\004 \001(\tH\000\022\024\n\ncommit_sha\030\005 \001" - + "(\tH\000\022\013\n\003dir\030\007 \001(\t\022\024\n\014invert_regex\030\010 \001(\010\022" - + "S\n\rsubstitutions\030\t \003(\0132<.google.devtools" - + ".cloudbuild.v1.RepoSource.SubstitutionsE" - + "ntry\0324\n\022SubstitutionsEntry\022\013\n\003key\030\001 \001(\t\022" - + "\r\n\005value\030\002 \001(\t:\0028\001B\n\n\010revision\"K\n\025Storag" - + "eSourceManifest\022\016\n\006bucket\030\001 \001(\t\022\016\n\006objec" - + "t\030\002 \001(\t\022\022\n\ngeneration\030\003 \001(\003\"\365\001\n\006Source\022F" - + "\n\016storage_source\030\002 \001(\0132,.google.devtools" - + ".cloudbuild.v1.StorageSourceH\000\022@\n\013repo_s" - + "ource\030\003 \001(\0132).google.devtools.cloudbuild" - + ".v1.RepoSourceH\000\022W\n\027storage_source_manif" - + "est\030\010 \001(\01324.google.devtools.cloudbuild.v" - + "1.StorageSourceManifestH\000B\010\n\006source\"m\n\nB" - + "uiltImage\022\014\n\004name\030\001 \001(\t\022\016\n\006digest\030\003 \001(\t\022" - + "A\n\013push_timing\030\004 \001(\0132\'.google.devtools.c" - + "loudbuild.v1.TimeSpanB\003\340A\003\"\276\003\n\tBuildStep" - + "\022\014\n\004name\030\001 \001(\t\022\013\n\003env\030\002 \003(\t\022\014\n\004args\030\003 \003(" - + "\t\022\013\n\003dir\030\004 \001(\t\022\n\n\002id\030\005 \001(\t\022\020\n\010wait_for\030\006" - + " \003(\t\022\022\n\nentrypoint\030\007 \001(\t\022\022\n\nsecret_env\030\010" - + " \003(\t\0226\n\007volumes\030\t \003(\0132%.google.devtools." - + "cloudbuild.v1.Volume\022<\n\006timing\030\n \001(\0132\'.g" - + "oogle.devtools.cloudbuild.v1.TimeSpanB\003\340" - + "A\003\022A\n\013pull_timing\030\r \001(\0132\'.google.devtool" - + "s.cloudbuild.v1.TimeSpanB\003\340A\003\022*\n\007timeout" - + "\030\013 \001(\0132\031.google.protobuf.Duration\022@\n\006sta" - + "tus\030\014 \001(\0162+.google.devtools.cloudbuild.v" - + "1.Build.StatusB\003\340A\003\022\016\n\006script\030\023 \001(\t\"$\n\006V" - + "olume\022\014\n\004name\030\001 \001(\t\022\014\n\004path\030\002 \001(\t\"\357\001\n\007Re" - + "sults\0229\n\006images\030\002 \003(\0132).google.devtools." - + "cloudbuild.v1.BuiltImage\022\031\n\021build_step_i" - + "mages\030\003 \003(\t\022\031\n\021artifact_manifest\030\004 \001(\t\022\025" - + "\n\rnum_artifacts\030\005 \001(\003\022\032\n\022build_step_outp" - + "uts\030\006 \003(\014\022@\n\017artifact_timing\030\007 \001(\0132\'.goo" - + "gle.devtools.cloudbuild.v1.TimeSpan\"`\n\016A" - + "rtifactResult\022\020\n\010location\030\001 \001(\t\022<\n\tfile_" - + "hash\030\002 \003(\0132).google.devtools.cloudbuild." - + "v1.FileHashes\"\240\022\n\005Build\022\021\n\004name\030- \001(\tB\003\340" - + "A\003\022\017\n\002id\030\001 \001(\tB\003\340A\003\022\027\n\nproject_id\030\020 \001(\tB" - + "\003\340A\003\022@\n\006status\030\002 \001(\0162+.google.devtools.c" - + "loudbuild.v1.Build.StatusB\003\340A\003\022\032\n\rstatus" - + "_detail\030\030 \001(\tB\003\340A\003\0225\n\006source\030\003 \001(\0132%.goo" - + "gle.devtools.cloudbuild.v1.Source\0227\n\005ste" - + "ps\030\013 \003(\0132(.google.devtools.cloudbuild.v1" - + ".BuildStep\022<\n\007results\030\n \001(\0132&.google.dev" - + "tools.cloudbuild.v1.ResultsB\003\340A\003\0224\n\013crea" - + "te_time\030\006 \001(\0132\032.google.protobuf.Timestam" - + "pB\003\340A\003\0223\n\nstart_time\030\007 \001(\0132\032.google.prot" - + "obuf.TimestampB\003\340A\003\0224\n\013finish_time\030\010 \001(\013" - + "2\032.google.protobuf.TimestampB\003\340A\003\022*\n\007tim" - + "eout\030\014 \001(\0132\031.google.protobuf.Duration\022\016\n" - + "\006images\030\r \003(\t\022,\n\tqueue_ttl\030( \001(\0132\031.googl" - + "e.protobuf.Duration\022;\n\tartifacts\030% \001(\0132(" - + ".google.devtools.cloudbuild.v1.Artifacts" - + "\022\023\n\013logs_bucket\030\023 \001(\t\022O\n\021source_provenan" - + "ce\030\025 \001(\0132/.google.devtools.cloudbuild.v1" - + ".SourceProvenanceB\003\340A\003\022\035\n\020build_trigger_" - + "id\030\026 \001(\tB\003\340A\003\022<\n\007options\030\027 \001(\0132+.google." - + "devtools.cloudbuild.v1.BuildOptions\022\024\n\007l" - + "og_url\030\031 \001(\tB\003\340A\003\022N\n\rsubstitutions\030\035 \003(\013" - + "27.google.devtools.cloudbuild.v1.Build.S" - + "ubstitutionsEntry\022\014\n\004tags\030\037 \003(\t\0226\n\007secre" - + "ts\030 \003(\0132%.google.devtools.cloudbuild.v1" - + ".Secret\022E\n\006timing\030! \003(\01320.google.devtool" - + "s.cloudbuild.v1.Build.TimingEntryB\003\340A\003\022C" - + "\n\010approval\030, \001(\0132,.google.devtools.cloud" - + "build.v1.BuildApprovalB\003\340A\003\022?\n\017service_a" - + "ccount\030* \001(\tB&\372A#\n!iam.googleapis.com/Se" - + "rviceAccount\022A\n\021available_secrets\030/ \001(\0132" - + "&.google.devtools.cloudbuild.v1.Secrets\022" - + "C\n\010warnings\0301 \003(\0132,.google.devtools.clou" - + "dbuild.v1.Build.WarningB\003\340A\003\022K\n\014failure_" - + "info\0303 \001(\01320.google.devtools.cloudbuild." - + "v1.Build.FailureInfoB\003\340A\003\032\250\001\n\007Warning\022\014\n" - + "\004text\030\001 \001(\t\022G\n\010priority\030\002 \001(\01625.google.d" - + "evtools.cloudbuild.v1.Build.Warning.Prio" - + "rity\"F\n\010Priority\022\030\n\024PRIORITY_UNSPECIFIED" - + "\020\000\022\010\n\004INFO\020\001\022\013\n\007WARNING\020\002\022\t\n\005ALERT\020\003\032\236\002\n" - + "\013FailureInfo\022J\n\004type\030\001 \001(\0162<.google.devt" - + "ools.cloudbuild.v1.Build.FailureInfo.Fai" - + "lureType\022\016\n\006detail\030\002 \001(\t\"\262\001\n\013FailureType" - + "\022\034\n\030FAILURE_TYPE_UNSPECIFIED\020\000\022\017\n\013PUSH_F" - + "AILED\020\001\022\030\n\024PUSH_IMAGE_NOT_FOUND\020\002\022\027\n\023PUS" - + "H_NOT_AUTHORIZED\020\003\022\023\n\017LOGGING_FAILURE\020\004\022" - + "\023\n\017USER_BUILD_STEP\020\005\022\027\n\023FETCH_SOURCE_FAI" - + "LED\020\006\0324\n\022SubstitutionsEntry\022\013\n\003key\030\001 \001(\t" - + "\022\r\n\005value\030\002 \001(\t:\0028\001\032V\n\013TimingEntry\022\013\n\003ke" - + "y\030\001 \001(\t\0226\n\005value\030\002 \001(\0132\'.google.devtools" - + ".cloudbuild.v1.TimeSpan:\0028\001\"\231\001\n\006Status\022\022" - + "\n\016STATUS_UNKNOWN\020\000\022\013\n\007PENDING\020\n\022\n\n\006QUEUE" - + "D\020\001\022\013\n\007WORKING\020\002\022\013\n\007SUCCESS\020\003\022\013\n\007FAILURE" - + "\020\004\022\022\n\016INTERNAL_ERROR\020\005\022\013\n\007TIMEOUT\020\006\022\r\n\tC" - + "ANCELLED\020\007\022\013\n\007EXPIRED\020\t:\177\352A|\n\037cloudbuild" - + ".googleapis.com/Build\022!projects/{project" - + "}/builds/{build}\0226projects/{project}/loc" - + "ations/{location}/builds/{build}\"\330\001\n\tArt" - + "ifacts\022\016\n\006images\030\001 \003(\t\022I\n\007objects\030\002 \001(\0132" - + "8.google.devtools.cloudbuild.v1.Artifact" - + "s.ArtifactObjects\032p\n\017ArtifactObjects\022\020\n\010" - + "location\030\001 \001(\t\022\r\n\005paths\030\002 \003(\t\022<\n\006timing\030" - + "\003 \001(\0132\'.google.devtools.cloudbuild.v1.Ti" - + "meSpanB\003\340A\003\"h\n\010TimeSpan\022.\n\nstart_time\030\001 " - + "\001(\0132\032.google.protobuf.Timestamp\022,\n\010end_t" - + "ime\030\002 \001(\0132\032.google.protobuf.Timestamp\"M\n" - + "\026BuildOperationMetadata\0223\n\005build\030\001 \001(\0132$" - + ".google.devtools.cloudbuild.v1.Build\"\303\003\n" - + "\020SourceProvenance\022M\n\027resolved_storage_so" - + "urce\030\003 \001(\0132,.google.devtools.cloudbuild." - + "v1.StorageSource\022G\n\024resolved_repo_source" - + "\030\006 \001(\0132).google.devtools.cloudbuild.v1.R" - + "epoSource\022^\n resolved_storage_source_man" - + "ifest\030\t \001(\01324.google.devtools.cloudbuild" - + ".v1.StorageSourceManifest\022Y\n\013file_hashes" - + "\030\004 \003(\0132?.google.devtools.cloudbuild.v1.S" - + "ourceProvenance.FileHashesEntryB\003\340A\003\032\\\n\017" - + "FileHashesEntry\022\013\n\003key\030\001 \001(\t\0228\n\005value\030\002 " - + "\001(\0132).google.devtools.cloudbuild.v1.File" - + "Hashes:\0028\001\"D\n\nFileHashes\0226\n\tfile_hash\030\001 " - + "\003(\0132#.google.devtools.cloudbuild.v1.Hash" - + "\"|\n\004Hash\022:\n\004type\030\001 \001(\0162,.google.devtools" - + ".cloudbuild.v1.Hash.HashType\022\r\n\005value\030\002 " - + "\001(\014\")\n\010HashType\022\010\n\004NONE\020\000\022\n\n\006SHA256\020\001\022\007\n" - + "\003MD5\020\002\"\222\001\n\007Secrets\022J\n\016secret_manager\030\001 \003" - + "(\01322.google.devtools.cloudbuild.v1.Secre" - + "tManagerSecret\022;\n\006inline\030\002 \003(\0132+.google." - + "devtools.cloudbuild.v1.InlineSecret\"\305\001\n\014" - + "InlineSecret\022<\n\014kms_key_name\030\001 \001(\tB&\372A#\n" - + "!cloudkms.googleapis.com/CryptoKey\022H\n\007en" - + "v_map\030\002 \003(\01327.google.devtools.cloudbuild" - + ".v1.InlineSecret.EnvMapEntry\032-\n\013EnvMapEn" - + "try\022\013\n\003key\030\001 \001(\t\022\r\n\005value\030\002 \001(\014:\0028\001\"i\n\023S" - + "ecretManagerSecret\022E\n\014version_name\030\001 \001(\t" - + "B/\372A,\n*secretmanager.googleapis.com/Secr" - + "etVersion\022\013\n\003env\030\002 \001(\t\"\232\001\n\006Secret\022\024\n\014kms" - + "_key_name\030\001 \001(\t\022H\n\nsecret_env\030\003 \003(\01324.go" - + "ogle.devtools.cloudbuild.v1.Secret.Secre" - + "tEnvEntry\0320\n\016SecretEnvEntry\022\013\n\003key\030\001 \001(\t" - + "\022\r\n\005value\030\002 \001(\014:\0028\001\"\235\001\n\022CreateBuildReque" - + "st\0224\n\006parent\030\004 \001(\tB$\372A!\022\037cloudbuild.goog" - + "leapis.com/Build\022\027\n\nproject_id\030\001 \001(\tB\003\340A" - + "\002\0228\n\005build\030\002 \001(\0132$.google.devtools.cloud" - + "build.v1.BuildB\003\340A\002\"o\n\017GetBuildRequest\0222" - + "\n\004name\030\004 \001(\tB$\372A!\n\037cloudbuild.googleapis" - + ".com/Build\022\027\n\nproject_id\030\001 \001(\tB\003\340A\002\022\017\n\002i" - + "d\030\002 \001(\tB\003\340A\002\"\231\001\n\021ListBuildsRequest\0224\n\006pa" - + "rent\030\t \001(\tB$\372A!\022\037cloudbuild.googleapis.c" - + "om/Build\022\027\n\nproject_id\030\001 \001(\tB\003\340A\002\022\021\n\tpag" - + "e_size\030\002 \001(\005\022\022\n\npage_token\030\003 \001(\t\022\016\n\006filt" - + "er\030\010 \001(\t\"c\n\022ListBuildsResponse\0224\n\006builds" - + "\030\001 \003(\0132$.google.devtools.cloudbuild.v1.B" - + "uild\022\027\n\017next_page_token\030\002 \001(\t\"r\n\022CancelB" - + "uildRequest\0222\n\004name\030\004 \001(\tB$\372A!\n\037cloudbui" - + "ld.googleapis.com/Build\022\027\n\nproject_id\030\001 " - + "\001(\tB\003\340A\002\022\017\n\002id\030\002 \001(\tB\003\340A\002\"p\n\023ApproveBuil" - + "dRequest\022\021\n\004name\030\001 \001(\tB\003\340A\002\022F\n\017approval_" - + "result\030\002 \001(\0132-.google.devtools.cloudbuil" - + "d.v1.ApprovalResult\"\267\002\n\rBuildApproval\022F\n" - + "\005state\030\001 \001(\01622.google.devtools.cloudbuil" - + "d.v1.BuildApproval.StateB\003\340A\003\022B\n\006config\030" - + "\002 \001(\0132-.google.devtools.cloudbuild.v1.Ap" - + "provalConfigB\003\340A\003\022B\n\006result\030\003 \001(\0132-.goog" - + "le.devtools.cloudbuild.v1.ApprovalResult" - + "B\003\340A\003\"V\n\005State\022\025\n\021STATE_UNSPECIFIED\020\000\022\013\n" - + "\007PENDING\020\001\022\014\n\010APPROVED\020\002\022\014\n\010REJECTED\020\003\022\r" - + "\n\tCANCELLED\020\005\"+\n\016ApprovalConfig\022\031\n\021appro" - + "val_required\030\001 \001(\010\"\240\002\n\016ApprovalResult\022\035\n" - + "\020approver_account\030\002 \001(\tB\003\340A\003\0226\n\rapproval" - + "_time\030\003 \001(\0132\032.google.protobuf.TimestampB" - + "\003\340A\003\022M\n\010decision\030\004 \001(\01626.google.devtools" - + ".cloudbuild.v1.ApprovalResult.DecisionB\003" - + "\340A\002\022\024\n\007comment\030\005 \001(\tB\003\340A\001\022\020\n\003url\030\006 \001(\tB\003" - + "\340A\001\"@\n\010Decision\022\030\n\024DECISION_UNSPECIFIED\020" - + "\000\022\014\n\010APPROVED\020\001\022\014\n\010REJECTED\020\002\"\353\007\n\014BuildT" - + "rigger\022\025\n\rresource_name\030\" \001(\t\022\017\n\002id\030\001 \001(" - + "\tB\003\340A\003\022\023\n\013description\030\n \001(\t\022\014\n\004name\030\025 \001(" - + "\t\022\014\n\004tags\030\023 \003(\t\022C\n\020trigger_template\030\007 \001(" - + "\0132).google.devtools.cloudbuild.v1.RepoSo" - + "urce\022A\n\006github\030\r \001(\01321.google.devtools.c" - + "loudbuild.v1.GitHubEventsConfig\022B\n\rpubsu" - + "b_config\030\035 \001(\0132+.google.devtools.cloudbu" - + "ild.v1.PubsubConfig\022D\n\016webhook_config\030\037 " - + "\001(\0132,.google.devtools.cloudbuild.v1.Webh" - + "ookConfig\022\024\n\nautodetect\030\022 \001(\010H\000\0225\n\005build" - + "\030\004 \001(\0132$.google.devtools.cloudbuild.v1.B" - + "uildH\000\022\022\n\010filename\030\010 \001(\tH\000\0224\n\013create_tim" - + "e\030\005 \001(\0132\032.google.protobuf.TimestampB\003\340A\003" - + "\022\020\n\010disabled\030\t \001(\010\022U\n\rsubstitutions\030\013 \003(" - + "\0132>.google.devtools.cloudbuild.v1.BuildT" - + "rigger.SubstitutionsEntry\022\025\n\rignored_fil" - + "es\030\017 \003(\t\022\026\n\016included_files\030\020 \003(\t\022\023\n\006filt" - + "er\030\036 \001(\tB\003\340A\001\022?\n\017service_account\030! \001(\tB&" - + "\372A#\n!iam.googleapis.com/ServiceAccount\0324" - + "\n\022SubstitutionsEntry\022\013\n\003key\030\001 \001(\t\022\r\n\005val" - + "ue\030\002 \001(\t:\0028\001:\242\001\352A\236\001\n&cloudbuild.googleap" - + "is.com/BuildTrigger\022%projects/{project}/" - + "triggers/{trigger}\022:projects/{project}/l" - + "ocations/{location}/triggers/{trigger}*\010" - + "triggers2\007triggerB\020\n\016build_template\"\334\001\n\022" - + "GitHubEventsConfig\022\033\n\017installation_id\030\001 " - + "\001(\003B\002\030\001\022\r\n\005owner\030\006 \001(\t\022\014\n\004name\030\007 \001(\t\022H\n\014" - + "pull_request\030\004 \001(\01320.google.devtools.clo" - + "udbuild.v1.PullRequestFilterH\000\0229\n\004push\030\005" - + " \001(\0132).google.devtools.cloudbuild.v1.Pus" - + "hFilterH\000B\007\n\005event\"\377\002\n\014PubsubConfig\022@\n\014s" - + "ubscription\030\001 \001(\tB*\340A\003\372A$\n\"pubsub.google" - + "apis.com/Subscription\022/\n\005topic\030\002 \001(\tB \372A" - + "\035\n\033pubsub.googleapis.com/Topic\022E\n\025servic" - + "e_account_email\030\003 \001(\tB&\372A#\n!iam.googleap" - + "is.com/ServiceAccount\022@\n\005state\030\004 \001(\01621.g" - + "oogle.devtools.cloudbuild.v1.PubsubConfi" - + "g.State\"s\n\005State\022\025\n\021STATE_UNSPECIFIED\020\000\022" - + "\006\n\002OK\020\001\022\030\n\024SUBSCRIPTION_DELETED\020\002\022\021\n\rTOP" - + "IC_DELETED\020\003\022\036\n\032SUBSCRIPTION_MISCONFIGUR" - + "ED\020\004\"\343\001\n\rWebhookConfig\022D\n\006secret\030\003 \001(\tB2" - + "\340A\002\372A,\n*secretmanager.googleapis.com/Sec" - + "retVersionH\000\022A\n\005state\030\004 \001(\01622.google.dev" - + "tools.cloudbuild.v1.WebhookConfig.State\"" - + ":\n\005State\022\025\n\021STATE_UNSPECIFIED\020\000\022\006\n\002OK\020\001\022" - + "\022\n\016SECRET_DELETED\020\002B\r\n\013auth_method\"\224\002\n\021P" - + "ullRequestFilter\022\020\n\006branch\030\002 \001(\tH\000\022X\n\017co" - + "mment_control\030\005 \001(\0162?.google.devtools.cl" - + "oudbuild.v1.PullRequestFilter.CommentCon" - + "trol\022\024\n\014invert_regex\030\006 \001(\010\"r\n\016CommentCon" - + "trol\022\025\n\021COMMENTS_DISABLED\020\000\022\024\n\020COMMENTS_" - + "ENABLED\020\001\0223\n/COMMENTS_ENABLED_FOR_EXTERN" - + "AL_CONTRIBUTORS_ONLY\020\002B\t\n\007git_ref\"N\n\nPus" - + "hFilter\022\020\n\006branch\030\002 \001(\tH\000\022\r\n\003tag\030\003 \001(\tH\000" - + "\022\024\n\014invert_regex\030\004 \001(\010B\t\n\007git_ref\"\264\001\n\031Cr" - + "eateBuildTriggerRequest\022;\n\006parent\030\003 \001(\tB" - + "+\372A(\022&cloudbuild.googleapis.com/BuildTri" - + "gger\022\027\n\nproject_id\030\001 \001(\tB\003\340A\002\022A\n\007trigger" - + "\030\002 \001(\0132+.google.devtools.cloudbuild.v1.B" - + "uildTriggerB\003\340A\002\"\205\001\n\026GetBuildTriggerRequ" - + "est\0229\n\004name\030\003 \001(\tB+\372A(\n&cloudbuild.googl" - + "eapis.com/BuildTrigger\022\027\n\nproject_id\030\001 \001" - + "(\tB\003\340A\002\022\027\n\ntrigger_id\030\002 \001(\tB\003\340A\002\"\227\001\n\030Lis" - + "tBuildTriggersRequest\022;\n\006parent\030\004 \001(\tB+\372" - + "A(\022&cloudbuild.googleapis.com/BuildTrigg" - + "er\022\027\n\nproject_id\030\001 \001(\tB\003\340A\002\022\021\n\tpage_size" - + "\030\002 \001(\005\022\022\n\npage_token\030\003 \001(\t\"s\n\031ListBuildT" - + "riggersResponse\022=\n\010triggers\030\001 \003(\0132+.goog" - + "le.devtools.cloudbuild.v1.BuildTrigger\022\027" - + "\n\017next_page_token\030\002 \001(\t\"\210\001\n\031DeleteBuildT" - + "riggerRequest\0229\n\004name\030\003 \001(\tB+\372A(\n&cloudb" - + "uild.googleapis.com/BuildTrigger\022\027\n\nproj" - + "ect_id\030\001 \001(\tB\003\340A\002\022\027\n\ntrigger_id\030\002 \001(\tB\003\340" - + "A\002\"\220\001\n\031UpdateBuildTriggerRequest\022\027\n\nproj" - + "ect_id\030\001 \001(\tB\003\340A\002\022\027\n\ntrigger_id\030\002 \001(\tB\003\340" - + "A\002\022A\n\007trigger\030\003 \001(\0132+.google.devtools.cl" - + "oudbuild.v1.BuildTriggerB\003\340A\002\"\334\t\n\014BuildO" - + "ptions\022L\n\026source_provenance_hash\030\001 \003(\0162," - + ".google.devtools.cloudbuild.v1.Hash.Hash" - + "Type\022Y\n\027requested_verify_option\030\002 \001(\01628." - + "google.devtools.cloudbuild.v1.BuildOptio" - + "ns.VerifyOption\022M\n\014machine_type\030\003 \001(\01627." - + "google.devtools.cloudbuild.v1.BuildOptio" - + "ns.MachineType\022\024\n\014disk_size_gb\030\006 \001(\003\022[\n\023" - + "substitution_option\030\004 \001(\0162>.google.devto" - + "ols.cloudbuild.v1.BuildOptions.Substitut" - + "ionOption\022\035\n\025dynamic_substitutions\030\021 \001(\010" - + "\022\\\n\024log_streaming_option\030\005 \001(\0162>.google." - + "devtools.cloudbuild.v1.BuildOptions.LogS" - + "treamingOption\022\027\n\013worker_pool\030\007 \001(\tB\002\030\001\022" - + "I\n\004pool\030\023 \001(\01326.google.devtools.cloudbui" - + "ld.v1.BuildOptions.PoolOptionB\003\340A\001\022H\n\007lo" - + "gging\030\013 \001(\01627.google.devtools.cloudbuild" - + ".v1.BuildOptions.LoggingMode\022\013\n\003env\030\014 \003(" - + "\t\022\022\n\nsecret_env\030\r \003(\t\0226\n\007volumes\030\016 \003(\0132%" - + ".google.devtools.cloudbuild.v1.Volume\032E\n" - + "\nPoolOption\0227\n\004name\030\001 \001(\tB)\372A&\n$cloudbui" - + "ld.googleapis.com/WorkerPool\".\n\014VerifyOp" - + "tion\022\020\n\014NOT_VERIFIED\020\000\022\014\n\010VERIFIED\020\001\"h\n\013" - + "MachineType\022\017\n\013UNSPECIFIED\020\000\022\020\n\014N1_HIGHC" - + "PU_8\020\001\022\021\n\rN1_HIGHCPU_32\020\002\022\020\n\014E2_HIGHCPU_" - + "8\020\005\022\021\n\rE2_HIGHCPU_32\020\006\"5\n\022SubstitutionOp" - + "tion\022\016\n\nMUST_MATCH\020\000\022\017\n\013ALLOW_LOOSE\020\001\"G\n" - + "\022LogStreamingOption\022\022\n\016STREAM_DEFAULT\020\000\022" - + "\r\n\tSTREAM_ON\020\001\022\016\n\nSTREAM_OFF\020\002\"|\n\013Loggin" - + "gMode\022\027\n\023LOGGING_UNSPECIFIED\020\000\022\n\n\006LEGACY" - + "\020\001\022\014\n\010GCS_ONLY\020\002\022\030\n\020STACKDRIVER_ONLY\020\003\032\002" - + "\010\001\022\026\n\022CLOUD_LOGGING_ONLY\020\005\022\010\n\004NONE\020\004\"\205\001\n" - + "\034ReceiveTriggerWebhookRequest\022\014\n\004name\030\005 " - + "\001(\t\022\"\n\004body\030\001 \001(\0132\024.google.api.HttpBody\022" - + "\022\n\nproject_id\030\002 \001(\t\022\017\n\007trigger\030\003 \001(\t\022\016\n\006" - + "secret\030\004 \001(\t\"\037\n\035ReceiveTriggerWebhookRes" - + "ponse\"\210\006\n\nWorkerPool\022\021\n\004name\030\001 \001(\tB\003\340A\003\022" - + "\024\n\014display_name\030\002 \001(\t\022\020\n\003uid\030\003 \001(\tB\003\340A\003\022" - + "O\n\013annotations\030\004 \003(\0132:.google.devtools.c" - + "loudbuild.v1.WorkerPool.AnnotationsEntry" - + "\0224\n\013create_time\030\005 \001(\0132\032.google.protobuf." - + "TimestampB\003\340A\003\0224\n\013update_time\030\006 \001(\0132\032.go" - + "ogle.protobuf.TimestampB\003\340A\003\0224\n\013delete_t" - + "ime\030\007 \001(\0132\032.google.protobuf.TimestampB\003\340" - + "A\003\022C\n\005state\030\010 \001(\0162/.google.devtools.clou" - + "dbuild.v1.WorkerPool.StateB\003\340A\003\022T\n\026priva" - + "te_pool_v1_config\030\014 \001(\01322.google.devtool" - + "s.cloudbuild.v1.PrivatePoolV1ConfigH\000\022\021\n" - + "\004etag\030\013 \001(\tB\003\340A\003\0322\n\020AnnotationsEntry\022\013\n\003" - + "key\030\001 \001(\t\022\r\n\005value\030\002 \001(\t:\0028\001\"T\n\005State\022\025\n" - + "\021STATE_UNSPECIFIED\020\000\022\014\n\010CREATING\020\001\022\013\n\007RU" - + "NNING\020\002\022\014\n\010DELETING\020\003\022\013\n\007DELETED\020\004:\211\001\352A\205" - + "\001\n$cloudbuild.googleapis.com/WorkerPool\022" - + "Aprojects/{project}/locations/{location}" - + "/workerPools/{worker_pool}*\013workerPools2" - + "\nworkerPoolR\001\001B\010\n\006config\"\226\004\n\023PrivatePool" - + "V1Config\022V\n\rworker_config\030\001 \001(\0132?.google" - + ".devtools.cloudbuild.v1.PrivatePoolV1Con" - + "fig.WorkerConfig\022X\n\016network_config\030\002 \001(\013" - + "2@.google.devtools.cloudbuild.v1.Private" - + "PoolV1Config.NetworkConfig\032:\n\014WorkerConf" - + "ig\022\024\n\014machine_type\030\001 \001(\t\022\024\n\014disk_size_gb" - + "\030\002 \001(\003\032\220\002\n\rNetworkConfig\022A\n\016peered_netwo" - + "rk\030\001 \001(\tB)\340A\005\340A\002\372A \n\036compute.googleapis." - + "com/Network\022d\n\regress_option\030\002 \001(\0162M.goo" - + "gle.devtools.cloudbuild.v1.PrivatePoolV1" - + "Config.NetworkConfig.EgressOption\"V\n\014Egr" - + "essOption\022\035\n\031EGRESS_OPTION_UNSPECIFIED\020\000" - + "\022\024\n\020NO_PUBLIC_EGRESS\020\001\022\021\n\rPUBLIC_EGRESS\020" - + "\002\"\320\001\n\027CreateWorkerPoolRequest\0229\n\006parent\030" - + "\001 \001(\tB)\340A\002\372A#\n!locations.googleapis.com/" - + "Location\022C\n\013worker_pool\030\002 \001(\0132).google.d" - + "evtools.cloudbuild.v1.WorkerPoolB\003\340A\002\022\036\n" - + "\016worker_pool_id\030\003 \001(\tB\006\340A\005\340A\002\022\025\n\rvalidat" - + "e_only\030\004 \001(\010\"R\n\024GetWorkerPoolRequest\022:\n\004" - + "name\030\001 \001(\tB,\340A\002\372A&\n$cloudbuild.googleapi" - + "s.com/WorkerPool\"\221\001\n\027DeleteWorkerPoolReq" - + "uest\022:\n\004name\030\001 \001(\tB,\340A\002\372A&\n$cloudbuild.g" - + "oogleapis.com/WorkerPool\022\014\n\004etag\030\002 \001(\t\022\025" - + "\n\rallow_missing\030\003 \001(\010\022\025\n\rvalidate_only\030\004" - + " \001(\010\"\246\001\n\027UpdateWorkerPoolRequest\022C\n\013work" - + "er_pool\030\001 \001(\0132).google.devtools.cloudbui" - + "ld.v1.WorkerPoolB\003\340A\002\022/\n\013update_mask\030\002 \001" - + "(\0132\032.google.protobuf.FieldMask\022\025\n\rvalida" - + "te_only\030\004 \001(\010\"z\n\026ListWorkerPoolsRequest\022" - + "9\n\006parent\030\001 \001(\tB)\340A\002\372A#\n!locations.googl" - + "eapis.com/Location\022\021\n\tpage_size\030\002 \001(\005\022\022\n" - + "\npage_token\030\003 \001(\t\"s\n\027ListWorkerPoolsResp" - + "onse\022?\n\014worker_pools\030\001 \003(\0132).google.devt" - + "ools.cloudbuild.v1.WorkerPool\022\027\n\017next_pa" - + "ge_token\030\002 \001(\t\"\307\001\n!CreateWorkerPoolOpera" - + "tionMetadata\022>\n\013worker_pool\030\001 \001(\tB)\372A&\n$" - + "cloudbuild.googleapis.com/WorkerPool\022/\n\013" - + "create_time\030\002 \001(\0132\032.google.protobuf.Time" - + "stamp\0221\n\rcomplete_time\030\003 \001(\0132\032.google.pr" - + "otobuf.Timestamp\"\307\001\n!UpdateWorkerPoolOpe" - + "rationMetadata\022>\n\013worker_pool\030\001 \001(\tB)\372A&" - + "\n$cloudbuild.googleapis.com/WorkerPool\022/" - + "\n\013create_time\030\002 \001(\0132\032.google.protobuf.Ti" - + "mestamp\0221\n\rcomplete_time\030\003 \001(\0132\032.google." - + "protobuf.Timestamp\"\307\001\n!DeleteWorkerPoolO" - + "perationMetadata\022>\n\013worker_pool\030\001 \001(\tB)\372" - + "A&\n$cloudbuild.googleapis.com/WorkerPool" - + "\022/\n\013create_time\030\002 \001(\0132\032.google.protobuf." - + "Timestamp\0221\n\rcomplete_time\030\003 \001(\0132\032.googl" - + "e.protobuf.Timestamp2\266#\n\nCloudBuild\022\373\001\n\013" - + "CreateBuild\0221.google.devtools.cloudbuild" - + ".v1.CreateBuildRequest\032\035.google.longrunn" - + "ing.Operation\"\231\001\202\323\344\223\002^\" /v1/projects/{pr" - + "oject_id}/builds:\005buildZ3\"*/v1/{parent=p" - + "rojects/*/locations/*}/builds:\005build\332A\020p" - + "roject_id,build\312A\037\n\005Build\022\026BuildOperatio" - + "nMetadata\022\315\001\n\010GetBuild\022..google.devtools" - + ".cloudbuild.v1.GetBuildRequest\032$.google." - + "devtools.cloudbuild.v1.Build\"k\202\323\344\223\002U\022%/v" - + "1/projects/{project_id}/builds/{id}Z,\022*/" - + "v1/{name=projects/*/locations/*/builds/*" - + "}\332A\rproject_id,id\022\335\001\n\nListBuilds\0220.googl" - + "e.devtools.cloudbuild.v1.ListBuildsReque" - + "st\0321.google.devtools.cloudbuild.v1.ListB" - + "uildsResponse\"j\202\323\344\223\002P\022 /v1/projects/{pro" - + "ject_id}/buildsZ,\022*/v1/{parent=projects/" - + "*/locations/*}/builds\332A\021project_id,filte" - + "r\022\347\001\n\013CancelBuild\0221.google.devtools.clou" - + "dbuild.v1.CancelBuildRequest\032$.google.de" - + "vtools.cloudbuild.v1.Build\"\177\202\323\344\223\002i\",/v1/" - + "projects/{project_id}/builds/{id}:cancel" - + ":\001*Z6\"1/v1/{name=projects/*/locations/*/" - + "builds/*}:cancel:\001*\332A\rproject_id,id\022\377\001\n\n" - + "RetryBuild\0220.google.devtools.cloudbuild.", - "v1.RetryBuildRequest\032\035.google.longrunnin" - + "g.Operation\"\237\001\202\323\344\223\002g\"+/v1/projects/{proj" - + "ect_id}/builds/{id}:retry:\001*Z5\"0/v1/{nam" - + "e=projects/*/locations/*/builds/*}:retry" - + ":\001*\332A\rproject_id,id\312A\037\n\005Build\022\026BuildOper" - + "ationMetadata\022\207\002\n\014ApproveBuild\0222.google." - + "devtools.cloudbuild.v1.ApproveBuildReque" - + "st\032\035.google.longrunning.Operation\"\243\001\202\323\344\223" - + "\002d\"&/v1/{name=projects/*/builds/*}:appro" - + "ve:\001*Z7\"2/v1/{name=projects/*/locations/" - + "*/builds/*}:approve:\001*\332A\024name,approval_r" - + "esult\312A\037\n\005Build\022\026BuildOperationMetadata\022" - + "\377\001\n\022CreateBuildTrigger\0228.google.devtools" - + ".cloudbuild.v1.CreateBuildTriggerRequest" - + "\032+.google.devtools.cloudbuild.v1.BuildTr" - + "igger\"\201\001\202\323\344\223\002f\"\"/v1/projects/{project_id" - + "}/triggers:\007triggerZ7\",/v1/{parent=proje" - + "cts/*/locations/*}/triggers:\007trigger\332A\022p" - + "roject_id,trigger\022\366\001\n\017GetBuildTrigger\0225." - + "google.devtools.cloudbuild.v1.GetBuildTr" - + "iggerRequest\032+.google.devtools.cloudbuil" - + "d.v1.BuildTrigger\"\177\202\323\344\223\002a\022//v1/projects/" - + "{project_id}/triggers/{trigger_id}Z.\022,/v" - + "1/{name=projects/*/locations/*/triggers/" - + "*}\332A\025project_id,trigger_id\022\357\001\n\021ListBuild" - + "Triggers\0227.google.devtools.cloudbuild.v1" - + ".ListBuildTriggersRequest\0328.google.devto" - + "ols.cloudbuild.v1.ListBuildTriggersRespo" - + "nse\"g\202\323\344\223\002T\022\"/v1/projects/{project_id}/t" - + "riggersZ.\022,/v1/{parent=projects/*/locati" - + "ons/*}/triggers\332A\nproject_id\022\347\001\n\022DeleteB" - + "uildTrigger\0228.google.devtools.cloudbuild" - + ".v1.DeleteBuildTriggerRequest\032\026.google.p" - + "rotobuf.Empty\"\177\202\323\344\223\002a*//v1/projects/{pro" - + "ject_id}/triggers/{trigger_id}Z.*,/v1/{n" - + "ame=projects/*/locations/*/triggers/*}\332A" - + "\025project_id,trigger_id\022\251\002\n\022UpdateBuildTr" - + "igger\0228.google.devtools.cloudbuild.v1.Up" - + "dateBuildTriggerRequest\032+.google.devtool" - + "s.cloudbuild.v1.BuildTrigger\"\253\001\202\323\344\223\002\204\0012/" - + "/v1/projects/{project_id}/triggers/{trig" - + "ger_id}:\007triggerZH2=/v1/{trigger.resourc" - + "e_name=projects/*/locations/*/triggers/*" - + "}:\007trigger\332A\035project_id,trigger_id,trigg" - + "er\022\245\002\n\017RunBuildTrigger\0225.google.devtools" - + ".cloudbuild.v1.RunBuildTriggerRequest\032\035." - + "google.longrunning.Operation\"\273\001\202\323\344\223\002t\"3/" - + "v1/projects/{project_id}/triggers/{trigg" - + "er_id}:run:\006sourceZ5\"0/v1/{name=projects" - + "/*/locations/*/triggers/*}:run:\001*\332A\034proj" - + "ect_id,trigger_id,source\312A\037\n\005Build\022\026Buil" - + "dOperationMetadata\022\225\002\n\025ReceiveTriggerWeb" - + "hook\022;.google.devtools.cloudbuild.v1.Rec" - + "eiveTriggerWebhookRequest\032<.google.devto" - + "ols.cloudbuild.v1.ReceiveTriggerWebhookR" - + "esponse\"\200\001\202\323\344\223\002z\"4/v1/projects/{project_" - + "id}/triggers/{trigger}:webhook:\004bodyZ<\"4" - + "/v1/{name=projects/*/locations/*/trigger" - + "s/*}:webhook:\004body\022\206\002\n\020CreateWorkerPool\022" - + "6.google.devtools.cloudbuild.v1.CreateWo" - + "rkerPoolRequest\032\035.google.longrunning.Ope" - + "ration\"\232\001\202\323\344\223\002>\"//v1/{parent=projects/*/" - + "locations/*}/workerPools:\013worker_pool\332A!" - + "parent,worker_pool,worker_pool_id\312A/\n\nWo" - + "rkerPool\022!CreateWorkerPoolOperationMetad" - + "ata\022\257\001\n\rGetWorkerPool\0223.google.devtools." - + "cloudbuild.v1.GetWorkerPoolRequest\032).goo" - + "gle.devtools.cloudbuild.v1.WorkerPool\">\202" - + "\323\344\223\0021\022//v1/{name=projects/*/locations/*/" - + "workerPools/*}\332A\004name\022\346\001\n\020DeleteWorkerPo" - + "ol\0226.google.devtools.cloudbuild.v1.Delet" - + "eWorkerPoolRequest\032\035.google.longrunning." - + "Operation\"{\202\323\344\223\0021*//v1/{name=projects/*/" - + "locations/*/workerPools/*}\332A\004name\312A:\n\025go" - + "ogle.protobuf.Empty\022!DeleteWorkerPoolOpe" - + "rationMetadata\022\210\002\n\020UpdateWorkerPool\0226.go" - + "ogle.devtools.cloudbuild.v1.UpdateWorker" - + "PoolRequest\032\035.google.longrunning.Operati" - + "on\"\234\001\202\323\344\223\002J2;/v1/{worker_pool.name=proje" - + "cts/*/locations/*/workerPools/*}:\013worker" - + "_pool\332A\027worker_pool,update_mask\312A/\n\nWork" - + "erPool\022!UpdateWorkerPoolOperationMetadat" - + "a\022\302\001\n\017ListWorkerPools\0225.google.devtools." - + "cloudbuild.v1.ListWorkerPoolsRequest\0326.g" - + "oogle.devtools.cloudbuild.v1.ListWorkerP" - + "oolsResponse\"@\202\323\344\223\0021\022//v1/{parent=projec" - + "ts/*/locations/*}/workerPools\332A\006parent\032M" - + "\312A\031cloudbuild.googleapis.com\322A.https://w" - + "ww.googleapis.com/auth/cloud-platformB\222\006" - + "\n\030com.google.cloudbuild.v1P\001ZGgoogle.gol" - + "ang.org/genproto/googleapis/devtools/clo" - + "udbuild/v1;cloudbuild\242\002\003GCB\252\002\032Google.Clo" - + "ud.CloudBuild.V1\352\002\030Google::Cloud::Build:" - + ":V1\352AN\n\036compute.googleapis.com/Network\022," - + "projects/{project}/global/networks/{netw" - + "ork}\352AY\n!iam.googleapis.com/ServiceAccou" - + "nt\0224projects/{project}/serviceAccounts/{" - + "service_account}\352AJ\n#secretmanager.googl" - + "eapis.com/Secret\022#projects/{project}/sec" - + "rets/{secret}\352Ad\n*secretmanager.googleap" - + "is.com/SecretVersion\0226projects/{project}" - + "/secrets/{secret}/versions/{version}\352Ap\n" - + "!cloudkms.googleapis.com/CryptoKey\022Kproj" - + "ects/{project}/locations/{location}/keyR" - + "ings/{keyring}/cryptoKeys/{key}\352AU\n\"pubs" - + "ub.googleapis.com/Subscription\022/projects" - + "/{project}/subscriptions/{subscription}\352" - + "A@\n\033pubsub.googleapis.com/Topic\022!project" - + "s/{project}/topics/{topic}b\006proto3" - }; - descriptor = - com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( - descriptorData, - new com.google.protobuf.Descriptors.FileDescriptor[] { - com.google.api.AnnotationsProto.getDescriptor(), - com.google.api.ClientProto.getDescriptor(), - com.google.api.FieldBehaviorProto.getDescriptor(), - com.google.api.HttpBodyProto.getDescriptor(), - com.google.api.ResourceProto.getDescriptor(), - com.google.longrunning.OperationsProto.getDescriptor(), - com.google.protobuf.DurationProto.getDescriptor(), - com.google.protobuf.EmptyProto.getDescriptor(), - com.google.protobuf.FieldMaskProto.getDescriptor(), - com.google.protobuf.TimestampProto.getDescriptor(), - }); - internal_static_google_devtools_cloudbuild_v1_RetryBuildRequest_descriptor = - getDescriptor().getMessageTypes().get(0); - internal_static_google_devtools_cloudbuild_v1_RetryBuildRequest_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_RetryBuildRequest_descriptor, - new java.lang.String[] { - "Name", "ProjectId", "Id", - }); - internal_static_google_devtools_cloudbuild_v1_RunBuildTriggerRequest_descriptor = - getDescriptor().getMessageTypes().get(1); - internal_static_google_devtools_cloudbuild_v1_RunBuildTriggerRequest_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_RunBuildTriggerRequest_descriptor, - new java.lang.String[] { - "Name", "ProjectId", "TriggerId", "Source", - }); - internal_static_google_devtools_cloudbuild_v1_StorageSource_descriptor = - getDescriptor().getMessageTypes().get(2); - internal_static_google_devtools_cloudbuild_v1_StorageSource_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_StorageSource_descriptor, - new java.lang.String[] { - "Bucket", "Object", "Generation", - }); - internal_static_google_devtools_cloudbuild_v1_RepoSource_descriptor = - getDescriptor().getMessageTypes().get(3); - internal_static_google_devtools_cloudbuild_v1_RepoSource_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_RepoSource_descriptor, - new java.lang.String[] { - "ProjectId", - "RepoName", - "BranchName", - "TagName", - "CommitSha", - "Dir", - "InvertRegex", - "Substitutions", - "Revision", - }); - internal_static_google_devtools_cloudbuild_v1_RepoSource_SubstitutionsEntry_descriptor = - internal_static_google_devtools_cloudbuild_v1_RepoSource_descriptor.getNestedTypes().get(0); - internal_static_google_devtools_cloudbuild_v1_RepoSource_SubstitutionsEntry_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_RepoSource_SubstitutionsEntry_descriptor, - new java.lang.String[] { - "Key", "Value", - }); - internal_static_google_devtools_cloudbuild_v1_StorageSourceManifest_descriptor = - getDescriptor().getMessageTypes().get(4); - internal_static_google_devtools_cloudbuild_v1_StorageSourceManifest_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_StorageSourceManifest_descriptor, - new java.lang.String[] { - "Bucket", "Object", "Generation", - }); - internal_static_google_devtools_cloudbuild_v1_Source_descriptor = - getDescriptor().getMessageTypes().get(5); - internal_static_google_devtools_cloudbuild_v1_Source_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_Source_descriptor, - new java.lang.String[] { - "StorageSource", "RepoSource", "StorageSourceManifest", "Source", - }); - internal_static_google_devtools_cloudbuild_v1_BuiltImage_descriptor = - getDescriptor().getMessageTypes().get(6); - internal_static_google_devtools_cloudbuild_v1_BuiltImage_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_BuiltImage_descriptor, - new java.lang.String[] { - "Name", "Digest", "PushTiming", - }); - internal_static_google_devtools_cloudbuild_v1_BuildStep_descriptor = - getDescriptor().getMessageTypes().get(7); - internal_static_google_devtools_cloudbuild_v1_BuildStep_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_BuildStep_descriptor, - new java.lang.String[] { - "Name", - "Env", - "Args", - "Dir", - "Id", - "WaitFor", - "Entrypoint", - "SecretEnv", - "Volumes", - "Timing", - "PullTiming", - "Timeout", - "Status", - "Script", - }); - internal_static_google_devtools_cloudbuild_v1_Volume_descriptor = - getDescriptor().getMessageTypes().get(8); - internal_static_google_devtools_cloudbuild_v1_Volume_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_Volume_descriptor, - new java.lang.String[] { - "Name", "Path", - }); - internal_static_google_devtools_cloudbuild_v1_Results_descriptor = - getDescriptor().getMessageTypes().get(9); - internal_static_google_devtools_cloudbuild_v1_Results_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_Results_descriptor, - new java.lang.String[] { - "Images", - "BuildStepImages", - "ArtifactManifest", - "NumArtifacts", - "BuildStepOutputs", - "ArtifactTiming", - }); - internal_static_google_devtools_cloudbuild_v1_ArtifactResult_descriptor = - getDescriptor().getMessageTypes().get(10); - internal_static_google_devtools_cloudbuild_v1_ArtifactResult_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_ArtifactResult_descriptor, - new java.lang.String[] { - "Location", "FileHash", - }); - internal_static_google_devtools_cloudbuild_v1_Build_descriptor = - getDescriptor().getMessageTypes().get(11); - internal_static_google_devtools_cloudbuild_v1_Build_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_Build_descriptor, - new java.lang.String[] { - "Name", - "Id", - "ProjectId", - "Status", - "StatusDetail", - "Source", - "Steps", - "Results", - "CreateTime", - "StartTime", - "FinishTime", - "Timeout", - "Images", - "QueueTtl", - "Artifacts", - "LogsBucket", - "SourceProvenance", - "BuildTriggerId", - "Options", - "LogUrl", - "Substitutions", - "Tags", - "Secrets", - "Timing", - "Approval", - "ServiceAccount", - "AvailableSecrets", - "Warnings", - "FailureInfo", - }); - internal_static_google_devtools_cloudbuild_v1_Build_Warning_descriptor = - internal_static_google_devtools_cloudbuild_v1_Build_descriptor.getNestedTypes().get(0); - internal_static_google_devtools_cloudbuild_v1_Build_Warning_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_Build_Warning_descriptor, - new java.lang.String[] { - "Text", "Priority", - }); - internal_static_google_devtools_cloudbuild_v1_Build_FailureInfo_descriptor = - internal_static_google_devtools_cloudbuild_v1_Build_descriptor.getNestedTypes().get(1); - internal_static_google_devtools_cloudbuild_v1_Build_FailureInfo_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_Build_FailureInfo_descriptor, - new java.lang.String[] { - "Type", "Detail", - }); - internal_static_google_devtools_cloudbuild_v1_Build_SubstitutionsEntry_descriptor = - internal_static_google_devtools_cloudbuild_v1_Build_descriptor.getNestedTypes().get(2); - internal_static_google_devtools_cloudbuild_v1_Build_SubstitutionsEntry_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_Build_SubstitutionsEntry_descriptor, - new java.lang.String[] { - "Key", "Value", - }); - internal_static_google_devtools_cloudbuild_v1_Build_TimingEntry_descriptor = - internal_static_google_devtools_cloudbuild_v1_Build_descriptor.getNestedTypes().get(3); - internal_static_google_devtools_cloudbuild_v1_Build_TimingEntry_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_Build_TimingEntry_descriptor, - new java.lang.String[] { - "Key", "Value", - }); - internal_static_google_devtools_cloudbuild_v1_Artifacts_descriptor = - getDescriptor().getMessageTypes().get(12); - internal_static_google_devtools_cloudbuild_v1_Artifacts_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_Artifacts_descriptor, - new java.lang.String[] { - "Images", "Objects", - }); - internal_static_google_devtools_cloudbuild_v1_Artifacts_ArtifactObjects_descriptor = - internal_static_google_devtools_cloudbuild_v1_Artifacts_descriptor.getNestedTypes().get(0); - internal_static_google_devtools_cloudbuild_v1_Artifacts_ArtifactObjects_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_Artifacts_ArtifactObjects_descriptor, - new java.lang.String[] { - "Location", "Paths", "Timing", - }); - internal_static_google_devtools_cloudbuild_v1_TimeSpan_descriptor = - getDescriptor().getMessageTypes().get(13); - internal_static_google_devtools_cloudbuild_v1_TimeSpan_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_TimeSpan_descriptor, - new java.lang.String[] { - "StartTime", "EndTime", - }); - internal_static_google_devtools_cloudbuild_v1_BuildOperationMetadata_descriptor = - getDescriptor().getMessageTypes().get(14); - internal_static_google_devtools_cloudbuild_v1_BuildOperationMetadata_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_BuildOperationMetadata_descriptor, - new java.lang.String[] { - "Build", - }); - internal_static_google_devtools_cloudbuild_v1_SourceProvenance_descriptor = - getDescriptor().getMessageTypes().get(15); - internal_static_google_devtools_cloudbuild_v1_SourceProvenance_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_SourceProvenance_descriptor, - new java.lang.String[] { - "ResolvedStorageSource", - "ResolvedRepoSource", - "ResolvedStorageSourceManifest", - "FileHashes", - }); - internal_static_google_devtools_cloudbuild_v1_SourceProvenance_FileHashesEntry_descriptor = - internal_static_google_devtools_cloudbuild_v1_SourceProvenance_descriptor - .getNestedTypes() - .get(0); - internal_static_google_devtools_cloudbuild_v1_SourceProvenance_FileHashesEntry_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_SourceProvenance_FileHashesEntry_descriptor, - new java.lang.String[] { - "Key", "Value", - }); - internal_static_google_devtools_cloudbuild_v1_FileHashes_descriptor = - getDescriptor().getMessageTypes().get(16); - internal_static_google_devtools_cloudbuild_v1_FileHashes_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_FileHashes_descriptor, - new java.lang.String[] { - "FileHash", - }); - internal_static_google_devtools_cloudbuild_v1_Hash_descriptor = - getDescriptor().getMessageTypes().get(17); - internal_static_google_devtools_cloudbuild_v1_Hash_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_Hash_descriptor, - new java.lang.String[] { - "Type", "Value", - }); - internal_static_google_devtools_cloudbuild_v1_Secrets_descriptor = - getDescriptor().getMessageTypes().get(18); - internal_static_google_devtools_cloudbuild_v1_Secrets_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_Secrets_descriptor, - new java.lang.String[] { - "SecretManager", "Inline", - }); - internal_static_google_devtools_cloudbuild_v1_InlineSecret_descriptor = - getDescriptor().getMessageTypes().get(19); - internal_static_google_devtools_cloudbuild_v1_InlineSecret_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_InlineSecret_descriptor, - new java.lang.String[] { - "KmsKeyName", "EnvMap", - }); - internal_static_google_devtools_cloudbuild_v1_InlineSecret_EnvMapEntry_descriptor = - internal_static_google_devtools_cloudbuild_v1_InlineSecret_descriptor - .getNestedTypes() - .get(0); - internal_static_google_devtools_cloudbuild_v1_InlineSecret_EnvMapEntry_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_InlineSecret_EnvMapEntry_descriptor, - new java.lang.String[] { - "Key", "Value", - }); - internal_static_google_devtools_cloudbuild_v1_SecretManagerSecret_descriptor = - getDescriptor().getMessageTypes().get(20); - internal_static_google_devtools_cloudbuild_v1_SecretManagerSecret_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_SecretManagerSecret_descriptor, - new java.lang.String[] { - "VersionName", "Env", - }); - internal_static_google_devtools_cloudbuild_v1_Secret_descriptor = - getDescriptor().getMessageTypes().get(21); - internal_static_google_devtools_cloudbuild_v1_Secret_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_Secret_descriptor, - new java.lang.String[] { - "KmsKeyName", "SecretEnv", - }); - internal_static_google_devtools_cloudbuild_v1_Secret_SecretEnvEntry_descriptor = - internal_static_google_devtools_cloudbuild_v1_Secret_descriptor.getNestedTypes().get(0); - internal_static_google_devtools_cloudbuild_v1_Secret_SecretEnvEntry_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_Secret_SecretEnvEntry_descriptor, - new java.lang.String[] { - "Key", "Value", - }); - internal_static_google_devtools_cloudbuild_v1_CreateBuildRequest_descriptor = - getDescriptor().getMessageTypes().get(22); - internal_static_google_devtools_cloudbuild_v1_CreateBuildRequest_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_CreateBuildRequest_descriptor, - new java.lang.String[] { - "Parent", "ProjectId", "Build", - }); - internal_static_google_devtools_cloudbuild_v1_GetBuildRequest_descriptor = - getDescriptor().getMessageTypes().get(23); - internal_static_google_devtools_cloudbuild_v1_GetBuildRequest_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_GetBuildRequest_descriptor, - new java.lang.String[] { - "Name", "ProjectId", "Id", - }); - internal_static_google_devtools_cloudbuild_v1_ListBuildsRequest_descriptor = - getDescriptor().getMessageTypes().get(24); - internal_static_google_devtools_cloudbuild_v1_ListBuildsRequest_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_ListBuildsRequest_descriptor, - new java.lang.String[] { - "Parent", "ProjectId", "PageSize", "PageToken", "Filter", - }); - internal_static_google_devtools_cloudbuild_v1_ListBuildsResponse_descriptor = - getDescriptor().getMessageTypes().get(25); - internal_static_google_devtools_cloudbuild_v1_ListBuildsResponse_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_ListBuildsResponse_descriptor, - new java.lang.String[] { - "Builds", "NextPageToken", - }); - internal_static_google_devtools_cloudbuild_v1_CancelBuildRequest_descriptor = - getDescriptor().getMessageTypes().get(26); - internal_static_google_devtools_cloudbuild_v1_CancelBuildRequest_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_CancelBuildRequest_descriptor, - new java.lang.String[] { - "Name", "ProjectId", "Id", - }); - internal_static_google_devtools_cloudbuild_v1_ApproveBuildRequest_descriptor = - getDescriptor().getMessageTypes().get(27); - internal_static_google_devtools_cloudbuild_v1_ApproveBuildRequest_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_ApproveBuildRequest_descriptor, - new java.lang.String[] { - "Name", "ApprovalResult", - }); - internal_static_google_devtools_cloudbuild_v1_BuildApproval_descriptor = - getDescriptor().getMessageTypes().get(28); - internal_static_google_devtools_cloudbuild_v1_BuildApproval_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_BuildApproval_descriptor, - new java.lang.String[] { - "State", "Config", "Result", - }); - internal_static_google_devtools_cloudbuild_v1_ApprovalConfig_descriptor = - getDescriptor().getMessageTypes().get(29); - internal_static_google_devtools_cloudbuild_v1_ApprovalConfig_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_ApprovalConfig_descriptor, - new java.lang.String[] { - "ApprovalRequired", - }); - internal_static_google_devtools_cloudbuild_v1_ApprovalResult_descriptor = - getDescriptor().getMessageTypes().get(30); - internal_static_google_devtools_cloudbuild_v1_ApprovalResult_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_ApprovalResult_descriptor, - new java.lang.String[] { - "ApproverAccount", "ApprovalTime", "Decision", "Comment", "Url", - }); - internal_static_google_devtools_cloudbuild_v1_BuildTrigger_descriptor = - getDescriptor().getMessageTypes().get(31); - internal_static_google_devtools_cloudbuild_v1_BuildTrigger_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_BuildTrigger_descriptor, - new java.lang.String[] { - "ResourceName", - "Id", - "Description", - "Name", - "Tags", - "TriggerTemplate", - "Github", - "PubsubConfig", - "WebhookConfig", - "Autodetect", - "Build", - "Filename", - "CreateTime", - "Disabled", - "Substitutions", - "IgnoredFiles", - "IncludedFiles", - "Filter", - "ServiceAccount", - "BuildTemplate", - }); - internal_static_google_devtools_cloudbuild_v1_BuildTrigger_SubstitutionsEntry_descriptor = - internal_static_google_devtools_cloudbuild_v1_BuildTrigger_descriptor - .getNestedTypes() - .get(0); - internal_static_google_devtools_cloudbuild_v1_BuildTrigger_SubstitutionsEntry_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_BuildTrigger_SubstitutionsEntry_descriptor, - new java.lang.String[] { - "Key", "Value", - }); - internal_static_google_devtools_cloudbuild_v1_GitHubEventsConfig_descriptor = - getDescriptor().getMessageTypes().get(32); - internal_static_google_devtools_cloudbuild_v1_GitHubEventsConfig_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_GitHubEventsConfig_descriptor, - new java.lang.String[] { - "InstallationId", "Owner", "Name", "PullRequest", "Push", "Event", - }); - internal_static_google_devtools_cloudbuild_v1_PubsubConfig_descriptor = - getDescriptor().getMessageTypes().get(33); - internal_static_google_devtools_cloudbuild_v1_PubsubConfig_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_PubsubConfig_descriptor, - new java.lang.String[] { - "Subscription", "Topic", "ServiceAccountEmail", "State", - }); - internal_static_google_devtools_cloudbuild_v1_WebhookConfig_descriptor = - getDescriptor().getMessageTypes().get(34); - internal_static_google_devtools_cloudbuild_v1_WebhookConfig_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_WebhookConfig_descriptor, - new java.lang.String[] { - "Secret", "State", "AuthMethod", - }); - internal_static_google_devtools_cloudbuild_v1_PullRequestFilter_descriptor = - getDescriptor().getMessageTypes().get(35); - internal_static_google_devtools_cloudbuild_v1_PullRequestFilter_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_PullRequestFilter_descriptor, - new java.lang.String[] { - "Branch", "CommentControl", "InvertRegex", "GitRef", - }); - internal_static_google_devtools_cloudbuild_v1_PushFilter_descriptor = - getDescriptor().getMessageTypes().get(36); - internal_static_google_devtools_cloudbuild_v1_PushFilter_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_PushFilter_descriptor, - new java.lang.String[] { - "Branch", "Tag", "InvertRegex", "GitRef", - }); - internal_static_google_devtools_cloudbuild_v1_CreateBuildTriggerRequest_descriptor = - getDescriptor().getMessageTypes().get(37); - internal_static_google_devtools_cloudbuild_v1_CreateBuildTriggerRequest_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_CreateBuildTriggerRequest_descriptor, - new java.lang.String[] { - "Parent", "ProjectId", "Trigger", - }); - internal_static_google_devtools_cloudbuild_v1_GetBuildTriggerRequest_descriptor = - getDescriptor().getMessageTypes().get(38); - internal_static_google_devtools_cloudbuild_v1_GetBuildTriggerRequest_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_GetBuildTriggerRequest_descriptor, - new java.lang.String[] { - "Name", "ProjectId", "TriggerId", - }); - internal_static_google_devtools_cloudbuild_v1_ListBuildTriggersRequest_descriptor = - getDescriptor().getMessageTypes().get(39); - internal_static_google_devtools_cloudbuild_v1_ListBuildTriggersRequest_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_ListBuildTriggersRequest_descriptor, - new java.lang.String[] { - "Parent", "ProjectId", "PageSize", "PageToken", - }); - internal_static_google_devtools_cloudbuild_v1_ListBuildTriggersResponse_descriptor = - getDescriptor().getMessageTypes().get(40); - internal_static_google_devtools_cloudbuild_v1_ListBuildTriggersResponse_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_ListBuildTriggersResponse_descriptor, - new java.lang.String[] { - "Triggers", "NextPageToken", - }); - internal_static_google_devtools_cloudbuild_v1_DeleteBuildTriggerRequest_descriptor = - getDescriptor().getMessageTypes().get(41); - internal_static_google_devtools_cloudbuild_v1_DeleteBuildTriggerRequest_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_DeleteBuildTriggerRequest_descriptor, - new java.lang.String[] { - "Name", "ProjectId", "TriggerId", - }); - internal_static_google_devtools_cloudbuild_v1_UpdateBuildTriggerRequest_descriptor = - getDescriptor().getMessageTypes().get(42); - internal_static_google_devtools_cloudbuild_v1_UpdateBuildTriggerRequest_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_UpdateBuildTriggerRequest_descriptor, - new java.lang.String[] { - "ProjectId", "TriggerId", "Trigger", - }); - internal_static_google_devtools_cloudbuild_v1_BuildOptions_descriptor = - getDescriptor().getMessageTypes().get(43); - internal_static_google_devtools_cloudbuild_v1_BuildOptions_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_BuildOptions_descriptor, - new java.lang.String[] { - "SourceProvenanceHash", - "RequestedVerifyOption", - "MachineType", - "DiskSizeGb", - "SubstitutionOption", - "DynamicSubstitutions", - "LogStreamingOption", - "WorkerPool", - "Pool", - "Logging", - "Env", - "SecretEnv", - "Volumes", - }); - internal_static_google_devtools_cloudbuild_v1_BuildOptions_PoolOption_descriptor = - internal_static_google_devtools_cloudbuild_v1_BuildOptions_descriptor - .getNestedTypes() - .get(0); - internal_static_google_devtools_cloudbuild_v1_BuildOptions_PoolOption_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_BuildOptions_PoolOption_descriptor, - new java.lang.String[] { - "Name", - }); - internal_static_google_devtools_cloudbuild_v1_ReceiveTriggerWebhookRequest_descriptor = - getDescriptor().getMessageTypes().get(44); - internal_static_google_devtools_cloudbuild_v1_ReceiveTriggerWebhookRequest_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_ReceiveTriggerWebhookRequest_descriptor, - new java.lang.String[] { - "Name", "Body", "ProjectId", "Trigger", "Secret", - }); - internal_static_google_devtools_cloudbuild_v1_ReceiveTriggerWebhookResponse_descriptor = - getDescriptor().getMessageTypes().get(45); - internal_static_google_devtools_cloudbuild_v1_ReceiveTriggerWebhookResponse_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_ReceiveTriggerWebhookResponse_descriptor, - new java.lang.String[] {}); - internal_static_google_devtools_cloudbuild_v1_WorkerPool_descriptor = - getDescriptor().getMessageTypes().get(46); - internal_static_google_devtools_cloudbuild_v1_WorkerPool_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_WorkerPool_descriptor, - new java.lang.String[] { - "Name", - "DisplayName", - "Uid", - "Annotations", - "CreateTime", - "UpdateTime", - "DeleteTime", - "State", - "PrivatePoolV1Config", - "Etag", - "Config", - }); - internal_static_google_devtools_cloudbuild_v1_WorkerPool_AnnotationsEntry_descriptor = - internal_static_google_devtools_cloudbuild_v1_WorkerPool_descriptor.getNestedTypes().get(0); - internal_static_google_devtools_cloudbuild_v1_WorkerPool_AnnotationsEntry_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_WorkerPool_AnnotationsEntry_descriptor, - new java.lang.String[] { - "Key", "Value", - }); - internal_static_google_devtools_cloudbuild_v1_PrivatePoolV1Config_descriptor = - getDescriptor().getMessageTypes().get(47); - internal_static_google_devtools_cloudbuild_v1_PrivatePoolV1Config_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_PrivatePoolV1Config_descriptor, - new java.lang.String[] { - "WorkerConfig", "NetworkConfig", - }); - internal_static_google_devtools_cloudbuild_v1_PrivatePoolV1Config_WorkerConfig_descriptor = - internal_static_google_devtools_cloudbuild_v1_PrivatePoolV1Config_descriptor - .getNestedTypes() - .get(0); - internal_static_google_devtools_cloudbuild_v1_PrivatePoolV1Config_WorkerConfig_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_PrivatePoolV1Config_WorkerConfig_descriptor, - new java.lang.String[] { - "MachineType", "DiskSizeGb", - }); - internal_static_google_devtools_cloudbuild_v1_PrivatePoolV1Config_NetworkConfig_descriptor = - internal_static_google_devtools_cloudbuild_v1_PrivatePoolV1Config_descriptor - .getNestedTypes() - .get(1); - internal_static_google_devtools_cloudbuild_v1_PrivatePoolV1Config_NetworkConfig_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_PrivatePoolV1Config_NetworkConfig_descriptor, - new java.lang.String[] { - "PeeredNetwork", "EgressOption", - }); - internal_static_google_devtools_cloudbuild_v1_CreateWorkerPoolRequest_descriptor = - getDescriptor().getMessageTypes().get(48); - internal_static_google_devtools_cloudbuild_v1_CreateWorkerPoolRequest_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_CreateWorkerPoolRequest_descriptor, - new java.lang.String[] { - "Parent", "WorkerPool", "WorkerPoolId", "ValidateOnly", - }); - internal_static_google_devtools_cloudbuild_v1_GetWorkerPoolRequest_descriptor = - getDescriptor().getMessageTypes().get(49); - internal_static_google_devtools_cloudbuild_v1_GetWorkerPoolRequest_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_GetWorkerPoolRequest_descriptor, - new java.lang.String[] { - "Name", - }); - internal_static_google_devtools_cloudbuild_v1_DeleteWorkerPoolRequest_descriptor = - getDescriptor().getMessageTypes().get(50); - internal_static_google_devtools_cloudbuild_v1_DeleteWorkerPoolRequest_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_DeleteWorkerPoolRequest_descriptor, - new java.lang.String[] { - "Name", "Etag", "AllowMissing", "ValidateOnly", - }); - internal_static_google_devtools_cloudbuild_v1_UpdateWorkerPoolRequest_descriptor = - getDescriptor().getMessageTypes().get(51); - internal_static_google_devtools_cloudbuild_v1_UpdateWorkerPoolRequest_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_UpdateWorkerPoolRequest_descriptor, - new java.lang.String[] { - "WorkerPool", "UpdateMask", "ValidateOnly", - }); - internal_static_google_devtools_cloudbuild_v1_ListWorkerPoolsRequest_descriptor = - getDescriptor().getMessageTypes().get(52); - internal_static_google_devtools_cloudbuild_v1_ListWorkerPoolsRequest_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_ListWorkerPoolsRequest_descriptor, - new java.lang.String[] { - "Parent", "PageSize", "PageToken", - }); - internal_static_google_devtools_cloudbuild_v1_ListWorkerPoolsResponse_descriptor = - getDescriptor().getMessageTypes().get(53); - internal_static_google_devtools_cloudbuild_v1_ListWorkerPoolsResponse_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_ListWorkerPoolsResponse_descriptor, - new java.lang.String[] { - "WorkerPools", "NextPageToken", - }); - internal_static_google_devtools_cloudbuild_v1_CreateWorkerPoolOperationMetadata_descriptor = - getDescriptor().getMessageTypes().get(54); - internal_static_google_devtools_cloudbuild_v1_CreateWorkerPoolOperationMetadata_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_CreateWorkerPoolOperationMetadata_descriptor, - new java.lang.String[] { - "WorkerPool", "CreateTime", "CompleteTime", - }); - internal_static_google_devtools_cloudbuild_v1_UpdateWorkerPoolOperationMetadata_descriptor = - getDescriptor().getMessageTypes().get(55); - internal_static_google_devtools_cloudbuild_v1_UpdateWorkerPoolOperationMetadata_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_UpdateWorkerPoolOperationMetadata_descriptor, - new java.lang.String[] { - "WorkerPool", "CreateTime", "CompleteTime", - }); - internal_static_google_devtools_cloudbuild_v1_DeleteWorkerPoolOperationMetadata_descriptor = - getDescriptor().getMessageTypes().get(56); - internal_static_google_devtools_cloudbuild_v1_DeleteWorkerPoolOperationMetadata_fieldAccessorTable = - new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_devtools_cloudbuild_v1_DeleteWorkerPoolOperationMetadata_descriptor, - new java.lang.String[] { - "WorkerPool", "CreateTime", "CompleteTime", - }); - com.google.protobuf.ExtensionRegistry registry = - com.google.protobuf.ExtensionRegistry.newInstance(); - registry.add(com.google.api.ClientProto.defaultHost); - registry.add(com.google.api.FieldBehaviorProto.fieldBehavior); - registry.add(com.google.api.AnnotationsProto.http); - registry.add(com.google.api.ClientProto.methodSignature); - registry.add(com.google.api.ClientProto.oauthScopes); - registry.add(com.google.api.ResourceProto.resource); - registry.add(com.google.api.ResourceProto.resourceDefinition); - registry.add(com.google.api.ResourceProto.resourceReference); - registry.add(com.google.longrunning.OperationsProto.operationInfo); - com.google.protobuf.Descriptors.FileDescriptor.internalUpdateFileDescriptor( - descriptor, registry); - com.google.api.AnnotationsProto.getDescriptor(); - com.google.api.ClientProto.getDescriptor(); - com.google.api.FieldBehaviorProto.getDescriptor(); - com.google.api.HttpBodyProto.getDescriptor(); - com.google.api.ResourceProto.getDescriptor(); - com.google.longrunning.OperationsProto.getDescriptor(); - com.google.protobuf.DurationProto.getDescriptor(); - com.google.protobuf.EmptyProto.getDescriptor(); - com.google.protobuf.FieldMaskProto.getDescriptor(); - com.google.protobuf.TimestampProto.getDescriptor(); - } - - // @@protoc_insertion_point(outer_class_scope) -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CreateBuildRequest.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CreateBuildRequest.java deleted file mode 100644 index 931ea670..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CreateBuildRequest.java +++ /dev/null @@ -1,1079 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * Request to create a new build.
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.CreateBuildRequest} - */ -public final class CreateBuildRequest extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.CreateBuildRequest) - CreateBuildRequestOrBuilder { - private static final long serialVersionUID = 0L; - // Use CreateBuildRequest.newBuilder() to construct. - private CreateBuildRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private CreateBuildRequest() { - parent_ = ""; - projectId_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new CreateBuildRequest(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_CreateBuildRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_CreateBuildRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.CreateBuildRequest.class, - com.google.cloudbuild.v1.CreateBuildRequest.Builder.class); - } - - public static final int PARENT_FIELD_NUMBER = 4; - private volatile java.lang.Object parent_; - /** - * - * - *
-   * The parent resource where this build will be created.
-   * Format: `projects/{project}/locations/{location}`
-   * 
- * - * string parent = 4 [(.google.api.resource_reference) = { ... } - * - * @return The parent. - */ - @java.lang.Override - public java.lang.String getParent() { - java.lang.Object ref = parent_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - parent_ = s; - return s; - } - } - /** - * - * - *
-   * The parent resource where this build will be created.
-   * Format: `projects/{project}/locations/{location}`
-   * 
- * - * string parent = 4 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for parent. - */ - @java.lang.Override - public com.google.protobuf.ByteString getParentBytes() { - java.lang.Object ref = parent_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - parent_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int PROJECT_ID_FIELD_NUMBER = 1; - private volatile java.lang.Object projectId_; - /** - * - * - *
-   * Required. ID of the project.
-   * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The projectId. - */ - @java.lang.Override - public java.lang.String getProjectId() { - java.lang.Object ref = projectId_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - projectId_ = s; - return s; - } - } - /** - * - * - *
-   * Required. ID of the project.
-   * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for projectId. - */ - @java.lang.Override - public com.google.protobuf.ByteString getProjectIdBytes() { - java.lang.Object ref = projectId_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - projectId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int BUILD_FIELD_NUMBER = 2; - private com.google.cloudbuild.v1.Build build_; - /** - * - * - *
-   * Required. Build resource to create.
-   * 
- * - * .google.devtools.cloudbuild.v1.Build build = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * - * @return Whether the build field is set. - */ - @java.lang.Override - public boolean hasBuild() { - return build_ != null; - } - /** - * - * - *
-   * Required. Build resource to create.
-   * 
- * - * .google.devtools.cloudbuild.v1.Build build = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * - * @return The build. - */ - @java.lang.Override - public com.google.cloudbuild.v1.Build getBuild() { - return build_ == null ? com.google.cloudbuild.v1.Build.getDefaultInstance() : build_; - } - /** - * - * - *
-   * Required. Build resource to create.
-   * 
- * - * .google.devtools.cloudbuild.v1.Build build = 2 [(.google.api.field_behavior) = REQUIRED]; - * - */ - @java.lang.Override - public com.google.cloudbuild.v1.BuildOrBuilder getBuildOrBuilder() { - return getBuild(); - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(projectId_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, projectId_); - } - if (build_ != null) { - output.writeMessage(2, getBuild()); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 4, parent_); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(projectId_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, projectId_); - } - if (build_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getBuild()); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, parent_); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.CreateBuildRequest)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.CreateBuildRequest other = - (com.google.cloudbuild.v1.CreateBuildRequest) obj; - - if (!getParent().equals(other.getParent())) return false; - if (!getProjectId().equals(other.getProjectId())) return false; - if (hasBuild() != other.hasBuild()) return false; - if (hasBuild()) { - if (!getBuild().equals(other.getBuild())) return false; - } - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + PARENT_FIELD_NUMBER; - hash = (53 * hash) + getParent().hashCode(); - hash = (37 * hash) + PROJECT_ID_FIELD_NUMBER; - hash = (53 * hash) + getProjectId().hashCode(); - if (hasBuild()) { - hash = (37 * hash) + BUILD_FIELD_NUMBER; - hash = (53 * hash) + getBuild().hashCode(); - } - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.CreateBuildRequest parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.CreateBuildRequest parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.CreateBuildRequest parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.CreateBuildRequest parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.CreateBuildRequest parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.CreateBuildRequest parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.CreateBuildRequest parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.CreateBuildRequest parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.CreateBuildRequest parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.CreateBuildRequest parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.CreateBuildRequest parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.CreateBuildRequest parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.CreateBuildRequest prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * Request to create a new build.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.CreateBuildRequest} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.CreateBuildRequest) - com.google.cloudbuild.v1.CreateBuildRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_CreateBuildRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_CreateBuildRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.CreateBuildRequest.class, - com.google.cloudbuild.v1.CreateBuildRequest.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.CreateBuildRequest.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - parent_ = ""; - - projectId_ = ""; - - if (buildBuilder_ == null) { - build_ = null; - } else { - build_ = null; - buildBuilder_ = null; - } - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_CreateBuildRequest_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.CreateBuildRequest getDefaultInstanceForType() { - return com.google.cloudbuild.v1.CreateBuildRequest.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.CreateBuildRequest build() { - com.google.cloudbuild.v1.CreateBuildRequest result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.CreateBuildRequest buildPartial() { - com.google.cloudbuild.v1.CreateBuildRequest result = - new com.google.cloudbuild.v1.CreateBuildRequest(this); - result.parent_ = parent_; - result.projectId_ = projectId_; - if (buildBuilder_ == null) { - result.build_ = build_; - } else { - result.build_ = buildBuilder_.build(); - } - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.CreateBuildRequest) { - return mergeFrom((com.google.cloudbuild.v1.CreateBuildRequest) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.CreateBuildRequest other) { - if (other == com.google.cloudbuild.v1.CreateBuildRequest.getDefaultInstance()) return this; - if (!other.getParent().isEmpty()) { - parent_ = other.parent_; - onChanged(); - } - if (!other.getProjectId().isEmpty()) { - projectId_ = other.projectId_; - onChanged(); - } - if (other.hasBuild()) { - mergeBuild(other.getBuild()); - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - projectId_ = input.readStringRequireUtf8(); - - break; - } // case 10 - case 18: - { - input.readMessage(getBuildFieldBuilder().getBuilder(), extensionRegistry); - - break; - } // case 18 - case 34: - { - parent_ = input.readStringRequireUtf8(); - - break; - } // case 34 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private java.lang.Object parent_ = ""; - /** - * - * - *
-     * The parent resource where this build will be created.
-     * Format: `projects/{project}/locations/{location}`
-     * 
- * - * string parent = 4 [(.google.api.resource_reference) = { ... } - * - * @return The parent. - */ - public java.lang.String getParent() { - java.lang.Object ref = parent_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - parent_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * The parent resource where this build will be created.
-     * Format: `projects/{project}/locations/{location}`
-     * 
- * - * string parent = 4 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for parent. - */ - public com.google.protobuf.ByteString getParentBytes() { - java.lang.Object ref = parent_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - parent_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * The parent resource where this build will be created.
-     * Format: `projects/{project}/locations/{location}`
-     * 
- * - * string parent = 4 [(.google.api.resource_reference) = { ... } - * - * @param value The parent to set. - * @return This builder for chaining. - */ - public Builder setParent(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - parent_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The parent resource where this build will be created.
-     * Format: `projects/{project}/locations/{location}`
-     * 
- * - * string parent = 4 [(.google.api.resource_reference) = { ... } - * - * @return This builder for chaining. - */ - public Builder clearParent() { - - parent_ = getDefaultInstance().getParent(); - onChanged(); - return this; - } - /** - * - * - *
-     * The parent resource where this build will be created.
-     * Format: `projects/{project}/locations/{location}`
-     * 
- * - * string parent = 4 [(.google.api.resource_reference) = { ... } - * - * @param value The bytes for parent to set. - * @return This builder for chaining. - */ - public Builder setParentBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - parent_ = value; - onChanged(); - return this; - } - - private java.lang.Object projectId_ = ""; - /** - * - * - *
-     * Required. ID of the project.
-     * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The projectId. - */ - public java.lang.String getProjectId() { - java.lang.Object ref = projectId_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - projectId_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Required. ID of the project.
-     * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for projectId. - */ - public com.google.protobuf.ByteString getProjectIdBytes() { - java.lang.Object ref = projectId_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - projectId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Required. ID of the project.
-     * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @param value The projectId to set. - * @return This builder for chaining. - */ - public Builder setProjectId(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - projectId_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Required. ID of the project.
-     * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return This builder for chaining. - */ - public Builder clearProjectId() { - - projectId_ = getDefaultInstance().getProjectId(); - onChanged(); - return this; - } - /** - * - * - *
-     * Required. ID of the project.
-     * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @param value The bytes for projectId to set. - * @return This builder for chaining. - */ - public Builder setProjectIdBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - projectId_ = value; - onChanged(); - return this; - } - - private com.google.cloudbuild.v1.Build build_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.Build, - com.google.cloudbuild.v1.Build.Builder, - com.google.cloudbuild.v1.BuildOrBuilder> - buildBuilder_; - /** - * - * - *
-     * Required. Build resource to create.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.Build build = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * - * @return Whether the build field is set. - */ - public boolean hasBuild() { - return buildBuilder_ != null || build_ != null; - } - /** - * - * - *
-     * Required. Build resource to create.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.Build build = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * - * @return The build. - */ - public com.google.cloudbuild.v1.Build getBuild() { - if (buildBuilder_ == null) { - return build_ == null ? com.google.cloudbuild.v1.Build.getDefaultInstance() : build_; - } else { - return buildBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Required. Build resource to create.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.Build build = 2 [(.google.api.field_behavior) = REQUIRED]; - * - */ - public Builder setBuild(com.google.cloudbuild.v1.Build value) { - if (buildBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - build_ = value; - onChanged(); - } else { - buildBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * Required. Build resource to create.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.Build build = 2 [(.google.api.field_behavior) = REQUIRED]; - * - */ - public Builder setBuild(com.google.cloudbuild.v1.Build.Builder builderForValue) { - if (buildBuilder_ == null) { - build_ = builderForValue.build(); - onChanged(); - } else { - buildBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Required. Build resource to create.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.Build build = 2 [(.google.api.field_behavior) = REQUIRED]; - * - */ - public Builder mergeBuild(com.google.cloudbuild.v1.Build value) { - if (buildBuilder_ == null) { - if (build_ != null) { - build_ = - com.google.cloudbuild.v1.Build.newBuilder(build_).mergeFrom(value).buildPartial(); - } else { - build_ = value; - } - onChanged(); - } else { - buildBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * Required. Build resource to create.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.Build build = 2 [(.google.api.field_behavior) = REQUIRED]; - * - */ - public Builder clearBuild() { - if (buildBuilder_ == null) { - build_ = null; - onChanged(); - } else { - build_ = null; - buildBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Required. Build resource to create.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.Build build = 2 [(.google.api.field_behavior) = REQUIRED]; - * - */ - public com.google.cloudbuild.v1.Build.Builder getBuildBuilder() { - - onChanged(); - return getBuildFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Required. Build resource to create.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.Build build = 2 [(.google.api.field_behavior) = REQUIRED]; - * - */ - public com.google.cloudbuild.v1.BuildOrBuilder getBuildOrBuilder() { - if (buildBuilder_ != null) { - return buildBuilder_.getMessageOrBuilder(); - } else { - return build_ == null ? com.google.cloudbuild.v1.Build.getDefaultInstance() : build_; - } - } - /** - * - * - *
-     * Required. Build resource to create.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.Build build = 2 [(.google.api.field_behavior) = REQUIRED]; - * - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.Build, - com.google.cloudbuild.v1.Build.Builder, - com.google.cloudbuild.v1.BuildOrBuilder> - getBuildFieldBuilder() { - if (buildBuilder_ == null) { - buildBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.Build, - com.google.cloudbuild.v1.Build.Builder, - com.google.cloudbuild.v1.BuildOrBuilder>( - getBuild(), getParentForChildren(), isClean()); - build_ = null; - } - return buildBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.CreateBuildRequest) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.CreateBuildRequest) - private static final com.google.cloudbuild.v1.CreateBuildRequest DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.CreateBuildRequest(); - } - - public static com.google.cloudbuild.v1.CreateBuildRequest getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public CreateBuildRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.CreateBuildRequest getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CreateBuildRequestOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CreateBuildRequestOrBuilder.java deleted file mode 100644 index bbe3b199..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CreateBuildRequestOrBuilder.java +++ /dev/null @@ -1,115 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface CreateBuildRequestOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.CreateBuildRequest) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The parent resource where this build will be created.
-   * Format: `projects/{project}/locations/{location}`
-   * 
- * - * string parent = 4 [(.google.api.resource_reference) = { ... } - * - * @return The parent. - */ - java.lang.String getParent(); - /** - * - * - *
-   * The parent resource where this build will be created.
-   * Format: `projects/{project}/locations/{location}`
-   * 
- * - * string parent = 4 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for parent. - */ - com.google.protobuf.ByteString getParentBytes(); - - /** - * - * - *
-   * Required. ID of the project.
-   * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The projectId. - */ - java.lang.String getProjectId(); - /** - * - * - *
-   * Required. ID of the project.
-   * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for projectId. - */ - com.google.protobuf.ByteString getProjectIdBytes(); - - /** - * - * - *
-   * Required. Build resource to create.
-   * 
- * - * .google.devtools.cloudbuild.v1.Build build = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * - * @return Whether the build field is set. - */ - boolean hasBuild(); - /** - * - * - *
-   * Required. Build resource to create.
-   * 
- * - * .google.devtools.cloudbuild.v1.Build build = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * - * @return The build. - */ - com.google.cloudbuild.v1.Build getBuild(); - /** - * - * - *
-   * Required. Build resource to create.
-   * 
- * - * .google.devtools.cloudbuild.v1.Build build = 2 [(.google.api.field_behavior) = REQUIRED]; - * - */ - com.google.cloudbuild.v1.BuildOrBuilder getBuildOrBuilder(); -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CreateBuildTriggerRequest.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CreateBuildTriggerRequest.java deleted file mode 100644 index 4eab64ab..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CreateBuildTriggerRequest.java +++ /dev/null @@ -1,1089 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * Request to create a new `BuildTrigger`.
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.CreateBuildTriggerRequest} - */ -public final class CreateBuildTriggerRequest extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.CreateBuildTriggerRequest) - CreateBuildTriggerRequestOrBuilder { - private static final long serialVersionUID = 0L; - // Use CreateBuildTriggerRequest.newBuilder() to construct. - private CreateBuildTriggerRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private CreateBuildTriggerRequest() { - parent_ = ""; - projectId_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new CreateBuildTriggerRequest(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_CreateBuildTriggerRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_CreateBuildTriggerRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.CreateBuildTriggerRequest.class, - com.google.cloudbuild.v1.CreateBuildTriggerRequest.Builder.class); - } - - public static final int PARENT_FIELD_NUMBER = 3; - private volatile java.lang.Object parent_; - /** - * - * - *
-   * The parent resource where this trigger will be created.
-   * Format: `projects/{project}/locations/{location}`
-   * 
- * - * string parent = 3 [(.google.api.resource_reference) = { ... } - * - * @return The parent. - */ - @java.lang.Override - public java.lang.String getParent() { - java.lang.Object ref = parent_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - parent_ = s; - return s; - } - } - /** - * - * - *
-   * The parent resource where this trigger will be created.
-   * Format: `projects/{project}/locations/{location}`
-   * 
- * - * string parent = 3 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for parent. - */ - @java.lang.Override - public com.google.protobuf.ByteString getParentBytes() { - java.lang.Object ref = parent_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - parent_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int PROJECT_ID_FIELD_NUMBER = 1; - private volatile java.lang.Object projectId_; - /** - * - * - *
-   * Required. ID of the project for which to configure automatic builds.
-   * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The projectId. - */ - @java.lang.Override - public java.lang.String getProjectId() { - java.lang.Object ref = projectId_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - projectId_ = s; - return s; - } - } - /** - * - * - *
-   * Required. ID of the project for which to configure automatic builds.
-   * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for projectId. - */ - @java.lang.Override - public com.google.protobuf.ByteString getProjectIdBytes() { - java.lang.Object ref = projectId_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - projectId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int TRIGGER_FIELD_NUMBER = 2; - private com.google.cloudbuild.v1.BuildTrigger trigger_; - /** - * - * - *
-   * Required. `BuildTrigger` to create.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.BuildTrigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * - * @return Whether the trigger field is set. - */ - @java.lang.Override - public boolean hasTrigger() { - return trigger_ != null; - } - /** - * - * - *
-   * Required. `BuildTrigger` to create.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.BuildTrigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * - * @return The trigger. - */ - @java.lang.Override - public com.google.cloudbuild.v1.BuildTrigger getTrigger() { - return trigger_ == null ? com.google.cloudbuild.v1.BuildTrigger.getDefaultInstance() : trigger_; - } - /** - * - * - *
-   * Required. `BuildTrigger` to create.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.BuildTrigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; - * - */ - @java.lang.Override - public com.google.cloudbuild.v1.BuildTriggerOrBuilder getTriggerOrBuilder() { - return getTrigger(); - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(projectId_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, projectId_); - } - if (trigger_ != null) { - output.writeMessage(2, getTrigger()); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 3, parent_); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(projectId_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, projectId_); - } - if (trigger_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getTrigger()); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, parent_); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.CreateBuildTriggerRequest)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.CreateBuildTriggerRequest other = - (com.google.cloudbuild.v1.CreateBuildTriggerRequest) obj; - - if (!getParent().equals(other.getParent())) return false; - if (!getProjectId().equals(other.getProjectId())) return false; - if (hasTrigger() != other.hasTrigger()) return false; - if (hasTrigger()) { - if (!getTrigger().equals(other.getTrigger())) return false; - } - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + PARENT_FIELD_NUMBER; - hash = (53 * hash) + getParent().hashCode(); - hash = (37 * hash) + PROJECT_ID_FIELD_NUMBER; - hash = (53 * hash) + getProjectId().hashCode(); - if (hasTrigger()) { - hash = (37 * hash) + TRIGGER_FIELD_NUMBER; - hash = (53 * hash) + getTrigger().hashCode(); - } - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.CreateBuildTriggerRequest parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.CreateBuildTriggerRequest parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.CreateBuildTriggerRequest parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.CreateBuildTriggerRequest parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.CreateBuildTriggerRequest parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.CreateBuildTriggerRequest parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.CreateBuildTriggerRequest parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.CreateBuildTriggerRequest parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.CreateBuildTriggerRequest parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.CreateBuildTriggerRequest parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.CreateBuildTriggerRequest parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.CreateBuildTriggerRequest parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.CreateBuildTriggerRequest prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * Request to create a new `BuildTrigger`.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.CreateBuildTriggerRequest} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.CreateBuildTriggerRequest) - com.google.cloudbuild.v1.CreateBuildTriggerRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_CreateBuildTriggerRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_CreateBuildTriggerRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.CreateBuildTriggerRequest.class, - com.google.cloudbuild.v1.CreateBuildTriggerRequest.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.CreateBuildTriggerRequest.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - parent_ = ""; - - projectId_ = ""; - - if (triggerBuilder_ == null) { - trigger_ = null; - } else { - trigger_ = null; - triggerBuilder_ = null; - } - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_CreateBuildTriggerRequest_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.CreateBuildTriggerRequest getDefaultInstanceForType() { - return com.google.cloudbuild.v1.CreateBuildTriggerRequest.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.CreateBuildTriggerRequest build() { - com.google.cloudbuild.v1.CreateBuildTriggerRequest result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.CreateBuildTriggerRequest buildPartial() { - com.google.cloudbuild.v1.CreateBuildTriggerRequest result = - new com.google.cloudbuild.v1.CreateBuildTriggerRequest(this); - result.parent_ = parent_; - result.projectId_ = projectId_; - if (triggerBuilder_ == null) { - result.trigger_ = trigger_; - } else { - result.trigger_ = triggerBuilder_.build(); - } - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.CreateBuildTriggerRequest) { - return mergeFrom((com.google.cloudbuild.v1.CreateBuildTriggerRequest) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.CreateBuildTriggerRequest other) { - if (other == com.google.cloudbuild.v1.CreateBuildTriggerRequest.getDefaultInstance()) - return this; - if (!other.getParent().isEmpty()) { - parent_ = other.parent_; - onChanged(); - } - if (!other.getProjectId().isEmpty()) { - projectId_ = other.projectId_; - onChanged(); - } - if (other.hasTrigger()) { - mergeTrigger(other.getTrigger()); - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - projectId_ = input.readStringRequireUtf8(); - - break; - } // case 10 - case 18: - { - input.readMessage(getTriggerFieldBuilder().getBuilder(), extensionRegistry); - - break; - } // case 18 - case 26: - { - parent_ = input.readStringRequireUtf8(); - - break; - } // case 26 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private java.lang.Object parent_ = ""; - /** - * - * - *
-     * The parent resource where this trigger will be created.
-     * Format: `projects/{project}/locations/{location}`
-     * 
- * - * string parent = 3 [(.google.api.resource_reference) = { ... } - * - * @return The parent. - */ - public java.lang.String getParent() { - java.lang.Object ref = parent_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - parent_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * The parent resource where this trigger will be created.
-     * Format: `projects/{project}/locations/{location}`
-     * 
- * - * string parent = 3 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for parent. - */ - public com.google.protobuf.ByteString getParentBytes() { - java.lang.Object ref = parent_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - parent_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * The parent resource where this trigger will be created.
-     * Format: `projects/{project}/locations/{location}`
-     * 
- * - * string parent = 3 [(.google.api.resource_reference) = { ... } - * - * @param value The parent to set. - * @return This builder for chaining. - */ - public Builder setParent(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - parent_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The parent resource where this trigger will be created.
-     * Format: `projects/{project}/locations/{location}`
-     * 
- * - * string parent = 3 [(.google.api.resource_reference) = { ... } - * - * @return This builder for chaining. - */ - public Builder clearParent() { - - parent_ = getDefaultInstance().getParent(); - onChanged(); - return this; - } - /** - * - * - *
-     * The parent resource where this trigger will be created.
-     * Format: `projects/{project}/locations/{location}`
-     * 
- * - * string parent = 3 [(.google.api.resource_reference) = { ... } - * - * @param value The bytes for parent to set. - * @return This builder for chaining. - */ - public Builder setParentBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - parent_ = value; - onChanged(); - return this; - } - - private java.lang.Object projectId_ = ""; - /** - * - * - *
-     * Required. ID of the project for which to configure automatic builds.
-     * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The projectId. - */ - public java.lang.String getProjectId() { - java.lang.Object ref = projectId_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - projectId_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Required. ID of the project for which to configure automatic builds.
-     * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for projectId. - */ - public com.google.protobuf.ByteString getProjectIdBytes() { - java.lang.Object ref = projectId_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - projectId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Required. ID of the project for which to configure automatic builds.
-     * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @param value The projectId to set. - * @return This builder for chaining. - */ - public Builder setProjectId(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - projectId_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Required. ID of the project for which to configure automatic builds.
-     * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return This builder for chaining. - */ - public Builder clearProjectId() { - - projectId_ = getDefaultInstance().getProjectId(); - onChanged(); - return this; - } - /** - * - * - *
-     * Required. ID of the project for which to configure automatic builds.
-     * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @param value The bytes for projectId to set. - * @return This builder for chaining. - */ - public Builder setProjectIdBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - projectId_ = value; - onChanged(); - return this; - } - - private com.google.cloudbuild.v1.BuildTrigger trigger_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.BuildTrigger, - com.google.cloudbuild.v1.BuildTrigger.Builder, - com.google.cloudbuild.v1.BuildTriggerOrBuilder> - triggerBuilder_; - /** - * - * - *
-     * Required. `BuildTrigger` to create.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.BuildTrigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * - * @return Whether the trigger field is set. - */ - public boolean hasTrigger() { - return triggerBuilder_ != null || trigger_ != null; - } - /** - * - * - *
-     * Required. `BuildTrigger` to create.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.BuildTrigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * - * @return The trigger. - */ - public com.google.cloudbuild.v1.BuildTrigger getTrigger() { - if (triggerBuilder_ == null) { - return trigger_ == null - ? com.google.cloudbuild.v1.BuildTrigger.getDefaultInstance() - : trigger_; - } else { - return triggerBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Required. `BuildTrigger` to create.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.BuildTrigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; - * - */ - public Builder setTrigger(com.google.cloudbuild.v1.BuildTrigger value) { - if (triggerBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - trigger_ = value; - onChanged(); - } else { - triggerBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * Required. `BuildTrigger` to create.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.BuildTrigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; - * - */ - public Builder setTrigger(com.google.cloudbuild.v1.BuildTrigger.Builder builderForValue) { - if (triggerBuilder_ == null) { - trigger_ = builderForValue.build(); - onChanged(); - } else { - triggerBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Required. `BuildTrigger` to create.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.BuildTrigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; - * - */ - public Builder mergeTrigger(com.google.cloudbuild.v1.BuildTrigger value) { - if (triggerBuilder_ == null) { - if (trigger_ != null) { - trigger_ = - com.google.cloudbuild.v1.BuildTrigger.newBuilder(trigger_) - .mergeFrom(value) - .buildPartial(); - } else { - trigger_ = value; - } - onChanged(); - } else { - triggerBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * Required. `BuildTrigger` to create.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.BuildTrigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; - * - */ - public Builder clearTrigger() { - if (triggerBuilder_ == null) { - trigger_ = null; - onChanged(); - } else { - trigger_ = null; - triggerBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Required. `BuildTrigger` to create.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.BuildTrigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; - * - */ - public com.google.cloudbuild.v1.BuildTrigger.Builder getTriggerBuilder() { - - onChanged(); - return getTriggerFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Required. `BuildTrigger` to create.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.BuildTrigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; - * - */ - public com.google.cloudbuild.v1.BuildTriggerOrBuilder getTriggerOrBuilder() { - if (triggerBuilder_ != null) { - return triggerBuilder_.getMessageOrBuilder(); - } else { - return trigger_ == null - ? com.google.cloudbuild.v1.BuildTrigger.getDefaultInstance() - : trigger_; - } - } - /** - * - * - *
-     * Required. `BuildTrigger` to create.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.BuildTrigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; - * - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.BuildTrigger, - com.google.cloudbuild.v1.BuildTrigger.Builder, - com.google.cloudbuild.v1.BuildTriggerOrBuilder> - getTriggerFieldBuilder() { - if (triggerBuilder_ == null) { - triggerBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.BuildTrigger, - com.google.cloudbuild.v1.BuildTrigger.Builder, - com.google.cloudbuild.v1.BuildTriggerOrBuilder>( - getTrigger(), getParentForChildren(), isClean()); - trigger_ = null; - } - return triggerBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.CreateBuildTriggerRequest) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.CreateBuildTriggerRequest) - private static final com.google.cloudbuild.v1.CreateBuildTriggerRequest DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.CreateBuildTriggerRequest(); - } - - public static com.google.cloudbuild.v1.CreateBuildTriggerRequest getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public CreateBuildTriggerRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.CreateBuildTriggerRequest getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CreateBuildTriggerRequestOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CreateBuildTriggerRequestOrBuilder.java deleted file mode 100644 index 4c277c16..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CreateBuildTriggerRequestOrBuilder.java +++ /dev/null @@ -1,118 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface CreateBuildTriggerRequestOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.CreateBuildTriggerRequest) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The parent resource where this trigger will be created.
-   * Format: `projects/{project}/locations/{location}`
-   * 
- * - * string parent = 3 [(.google.api.resource_reference) = { ... } - * - * @return The parent. - */ - java.lang.String getParent(); - /** - * - * - *
-   * The parent resource where this trigger will be created.
-   * Format: `projects/{project}/locations/{location}`
-   * 
- * - * string parent = 3 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for parent. - */ - com.google.protobuf.ByteString getParentBytes(); - - /** - * - * - *
-   * Required. ID of the project for which to configure automatic builds.
-   * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The projectId. - */ - java.lang.String getProjectId(); - /** - * - * - *
-   * Required. ID of the project for which to configure automatic builds.
-   * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for projectId. - */ - com.google.protobuf.ByteString getProjectIdBytes(); - - /** - * - * - *
-   * Required. `BuildTrigger` to create.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.BuildTrigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * - * @return Whether the trigger field is set. - */ - boolean hasTrigger(); - /** - * - * - *
-   * Required. `BuildTrigger` to create.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.BuildTrigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * - * @return The trigger. - */ - com.google.cloudbuild.v1.BuildTrigger getTrigger(); - /** - * - * - *
-   * Required. `BuildTrigger` to create.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.BuildTrigger trigger = 2 [(.google.api.field_behavior) = REQUIRED]; - * - */ - com.google.cloudbuild.v1.BuildTriggerOrBuilder getTriggerOrBuilder(); -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CreateWorkerPoolOperationMetadata.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CreateWorkerPoolOperationMetadata.java deleted file mode 100644 index 51eb3660..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CreateWorkerPoolOperationMetadata.java +++ /dev/null @@ -1,1161 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * Metadata for the `CreateWorkerPool` operation.
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.CreateWorkerPoolOperationMetadata} - */ -public final class CreateWorkerPoolOperationMetadata extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.CreateWorkerPoolOperationMetadata) - CreateWorkerPoolOperationMetadataOrBuilder { - private static final long serialVersionUID = 0L; - // Use CreateWorkerPoolOperationMetadata.newBuilder() to construct. - private CreateWorkerPoolOperationMetadata( - com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private CreateWorkerPoolOperationMetadata() { - workerPool_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new CreateWorkerPoolOperationMetadata(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_CreateWorkerPoolOperationMetadata_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_CreateWorkerPoolOperationMetadata_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.CreateWorkerPoolOperationMetadata.class, - com.google.cloudbuild.v1.CreateWorkerPoolOperationMetadata.Builder.class); - } - - public static final int WORKER_POOL_FIELD_NUMBER = 1; - private volatile java.lang.Object workerPool_; - /** - * - * - *
-   * The resource name of the `WorkerPool` to create.
-   * Format:
-   * `projects/{project}/locations/{location}/workerPools/{worker_pool}`.
-   * 
- * - * string worker_pool = 1 [(.google.api.resource_reference) = { ... } - * - * @return The workerPool. - */ - @java.lang.Override - public java.lang.String getWorkerPool() { - java.lang.Object ref = workerPool_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - workerPool_ = s; - return s; - } - } - /** - * - * - *
-   * The resource name of the `WorkerPool` to create.
-   * Format:
-   * `projects/{project}/locations/{location}/workerPools/{worker_pool}`.
-   * 
- * - * string worker_pool = 1 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for workerPool. - */ - @java.lang.Override - public com.google.protobuf.ByteString getWorkerPoolBytes() { - java.lang.Object ref = workerPool_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - workerPool_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int CREATE_TIME_FIELD_NUMBER = 2; - private com.google.protobuf.Timestamp createTime_; - /** - * - * - *
-   * Time the operation was created.
-   * 
- * - * .google.protobuf.Timestamp create_time = 2; - * - * @return Whether the createTime field is set. - */ - @java.lang.Override - public boolean hasCreateTime() { - return createTime_ != null; - } - /** - * - * - *
-   * Time the operation was created.
-   * 
- * - * .google.protobuf.Timestamp create_time = 2; - * - * @return The createTime. - */ - @java.lang.Override - public com.google.protobuf.Timestamp getCreateTime() { - return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; - } - /** - * - * - *
-   * Time the operation was created.
-   * 
- * - * .google.protobuf.Timestamp create_time = 2; - */ - @java.lang.Override - public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { - return getCreateTime(); - } - - public static final int COMPLETE_TIME_FIELD_NUMBER = 3; - private com.google.protobuf.Timestamp completeTime_; - /** - * - * - *
-   * Time the operation was completed.
-   * 
- * - * .google.protobuf.Timestamp complete_time = 3; - * - * @return Whether the completeTime field is set. - */ - @java.lang.Override - public boolean hasCompleteTime() { - return completeTime_ != null; - } - /** - * - * - *
-   * Time the operation was completed.
-   * 
- * - * .google.protobuf.Timestamp complete_time = 3; - * - * @return The completeTime. - */ - @java.lang.Override - public com.google.protobuf.Timestamp getCompleteTime() { - return completeTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : completeTime_; - } - /** - * - * - *
-   * Time the operation was completed.
-   * 
- * - * .google.protobuf.Timestamp complete_time = 3; - */ - @java.lang.Override - public com.google.protobuf.TimestampOrBuilder getCompleteTimeOrBuilder() { - return getCompleteTime(); - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(workerPool_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, workerPool_); - } - if (createTime_ != null) { - output.writeMessage(2, getCreateTime()); - } - if (completeTime_ != null) { - output.writeMessage(3, getCompleteTime()); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(workerPool_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, workerPool_); - } - if (createTime_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getCreateTime()); - } - if (completeTime_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getCompleteTime()); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.CreateWorkerPoolOperationMetadata)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.CreateWorkerPoolOperationMetadata other = - (com.google.cloudbuild.v1.CreateWorkerPoolOperationMetadata) obj; - - if (!getWorkerPool().equals(other.getWorkerPool())) return false; - if (hasCreateTime() != other.hasCreateTime()) return false; - if (hasCreateTime()) { - if (!getCreateTime().equals(other.getCreateTime())) return false; - } - if (hasCompleteTime() != other.hasCompleteTime()) return false; - if (hasCompleteTime()) { - if (!getCompleteTime().equals(other.getCompleteTime())) return false; - } - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + WORKER_POOL_FIELD_NUMBER; - hash = (53 * hash) + getWorkerPool().hashCode(); - if (hasCreateTime()) { - hash = (37 * hash) + CREATE_TIME_FIELD_NUMBER; - hash = (53 * hash) + getCreateTime().hashCode(); - } - if (hasCompleteTime()) { - hash = (37 * hash) + COMPLETE_TIME_FIELD_NUMBER; - hash = (53 * hash) + getCompleteTime().hashCode(); - } - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.CreateWorkerPoolOperationMetadata parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.CreateWorkerPoolOperationMetadata parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.CreateWorkerPoolOperationMetadata parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.CreateWorkerPoolOperationMetadata parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.CreateWorkerPoolOperationMetadata parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.CreateWorkerPoolOperationMetadata parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.CreateWorkerPoolOperationMetadata parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.CreateWorkerPoolOperationMetadata parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.CreateWorkerPoolOperationMetadata parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.CreateWorkerPoolOperationMetadata parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.CreateWorkerPoolOperationMetadata parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.CreateWorkerPoolOperationMetadata parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder( - com.google.cloudbuild.v1.CreateWorkerPoolOperationMetadata prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * Metadata for the `CreateWorkerPool` operation.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.CreateWorkerPoolOperationMetadata} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.CreateWorkerPoolOperationMetadata) - com.google.cloudbuild.v1.CreateWorkerPoolOperationMetadataOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_CreateWorkerPoolOperationMetadata_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_CreateWorkerPoolOperationMetadata_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.CreateWorkerPoolOperationMetadata.class, - com.google.cloudbuild.v1.CreateWorkerPoolOperationMetadata.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.CreateWorkerPoolOperationMetadata.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - workerPool_ = ""; - - if (createTimeBuilder_ == null) { - createTime_ = null; - } else { - createTime_ = null; - createTimeBuilder_ = null; - } - if (completeTimeBuilder_ == null) { - completeTime_ = null; - } else { - completeTime_ = null; - completeTimeBuilder_ = null; - } - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_CreateWorkerPoolOperationMetadata_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.CreateWorkerPoolOperationMetadata getDefaultInstanceForType() { - return com.google.cloudbuild.v1.CreateWorkerPoolOperationMetadata.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.CreateWorkerPoolOperationMetadata build() { - com.google.cloudbuild.v1.CreateWorkerPoolOperationMetadata result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.CreateWorkerPoolOperationMetadata buildPartial() { - com.google.cloudbuild.v1.CreateWorkerPoolOperationMetadata result = - new com.google.cloudbuild.v1.CreateWorkerPoolOperationMetadata(this); - result.workerPool_ = workerPool_; - if (createTimeBuilder_ == null) { - result.createTime_ = createTime_; - } else { - result.createTime_ = createTimeBuilder_.build(); - } - if (completeTimeBuilder_ == null) { - result.completeTime_ = completeTime_; - } else { - result.completeTime_ = completeTimeBuilder_.build(); - } - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.CreateWorkerPoolOperationMetadata) { - return mergeFrom((com.google.cloudbuild.v1.CreateWorkerPoolOperationMetadata) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.CreateWorkerPoolOperationMetadata other) { - if (other == com.google.cloudbuild.v1.CreateWorkerPoolOperationMetadata.getDefaultInstance()) - return this; - if (!other.getWorkerPool().isEmpty()) { - workerPool_ = other.workerPool_; - onChanged(); - } - if (other.hasCreateTime()) { - mergeCreateTime(other.getCreateTime()); - } - if (other.hasCompleteTime()) { - mergeCompleteTime(other.getCompleteTime()); - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - workerPool_ = input.readStringRequireUtf8(); - - break; - } // case 10 - case 18: - { - input.readMessage(getCreateTimeFieldBuilder().getBuilder(), extensionRegistry); - - break; - } // case 18 - case 26: - { - input.readMessage(getCompleteTimeFieldBuilder().getBuilder(), extensionRegistry); - - break; - } // case 26 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private java.lang.Object workerPool_ = ""; - /** - * - * - *
-     * The resource name of the `WorkerPool` to create.
-     * Format:
-     * `projects/{project}/locations/{location}/workerPools/{worker_pool}`.
-     * 
- * - * string worker_pool = 1 [(.google.api.resource_reference) = { ... } - * - * @return The workerPool. - */ - public java.lang.String getWorkerPool() { - java.lang.Object ref = workerPool_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - workerPool_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * The resource name of the `WorkerPool` to create.
-     * Format:
-     * `projects/{project}/locations/{location}/workerPools/{worker_pool}`.
-     * 
- * - * string worker_pool = 1 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for workerPool. - */ - public com.google.protobuf.ByteString getWorkerPoolBytes() { - java.lang.Object ref = workerPool_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - workerPool_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * The resource name of the `WorkerPool` to create.
-     * Format:
-     * `projects/{project}/locations/{location}/workerPools/{worker_pool}`.
-     * 
- * - * string worker_pool = 1 [(.google.api.resource_reference) = { ... } - * - * @param value The workerPool to set. - * @return This builder for chaining. - */ - public Builder setWorkerPool(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - workerPool_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The resource name of the `WorkerPool` to create.
-     * Format:
-     * `projects/{project}/locations/{location}/workerPools/{worker_pool}`.
-     * 
- * - * string worker_pool = 1 [(.google.api.resource_reference) = { ... } - * - * @return This builder for chaining. - */ - public Builder clearWorkerPool() { - - workerPool_ = getDefaultInstance().getWorkerPool(); - onChanged(); - return this; - } - /** - * - * - *
-     * The resource name of the `WorkerPool` to create.
-     * Format:
-     * `projects/{project}/locations/{location}/workerPools/{worker_pool}`.
-     * 
- * - * string worker_pool = 1 [(.google.api.resource_reference) = { ... } - * - * @param value The bytes for workerPool to set. - * @return This builder for chaining. - */ - public Builder setWorkerPoolBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - workerPool_ = value; - onChanged(); - return this; - } - - private com.google.protobuf.Timestamp createTime_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - createTimeBuilder_; - /** - * - * - *
-     * Time the operation was created.
-     * 
- * - * .google.protobuf.Timestamp create_time = 2; - * - * @return Whether the createTime field is set. - */ - public boolean hasCreateTime() { - return createTimeBuilder_ != null || createTime_ != null; - } - /** - * - * - *
-     * Time the operation was created.
-     * 
- * - * .google.protobuf.Timestamp create_time = 2; - * - * @return The createTime. - */ - public com.google.protobuf.Timestamp getCreateTime() { - if (createTimeBuilder_ == null) { - return createTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : createTime_; - } else { - return createTimeBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Time the operation was created.
-     * 
- * - * .google.protobuf.Timestamp create_time = 2; - */ - public Builder setCreateTime(com.google.protobuf.Timestamp value) { - if (createTimeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - createTime_ = value; - onChanged(); - } else { - createTimeBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * Time the operation was created.
-     * 
- * - * .google.protobuf.Timestamp create_time = 2; - */ - public Builder setCreateTime(com.google.protobuf.Timestamp.Builder builderForValue) { - if (createTimeBuilder_ == null) { - createTime_ = builderForValue.build(); - onChanged(); - } else { - createTimeBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Time the operation was created.
-     * 
- * - * .google.protobuf.Timestamp create_time = 2; - */ - public Builder mergeCreateTime(com.google.protobuf.Timestamp value) { - if (createTimeBuilder_ == null) { - if (createTime_ != null) { - createTime_ = - com.google.protobuf.Timestamp.newBuilder(createTime_).mergeFrom(value).buildPartial(); - } else { - createTime_ = value; - } - onChanged(); - } else { - createTimeBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * Time the operation was created.
-     * 
- * - * .google.protobuf.Timestamp create_time = 2; - */ - public Builder clearCreateTime() { - if (createTimeBuilder_ == null) { - createTime_ = null; - onChanged(); - } else { - createTime_ = null; - createTimeBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Time the operation was created.
-     * 
- * - * .google.protobuf.Timestamp create_time = 2; - */ - public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder() { - - onChanged(); - return getCreateTimeFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Time the operation was created.
-     * 
- * - * .google.protobuf.Timestamp create_time = 2; - */ - public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { - if (createTimeBuilder_ != null) { - return createTimeBuilder_.getMessageOrBuilder(); - } else { - return createTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : createTime_; - } - } - /** - * - * - *
-     * Time the operation was created.
-     * 
- * - * .google.protobuf.Timestamp create_time = 2; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - getCreateTimeFieldBuilder() { - if (createTimeBuilder_ == null) { - createTimeBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder>( - getCreateTime(), getParentForChildren(), isClean()); - createTime_ = null; - } - return createTimeBuilder_; - } - - private com.google.protobuf.Timestamp completeTime_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - completeTimeBuilder_; - /** - * - * - *
-     * Time the operation was completed.
-     * 
- * - * .google.protobuf.Timestamp complete_time = 3; - * - * @return Whether the completeTime field is set. - */ - public boolean hasCompleteTime() { - return completeTimeBuilder_ != null || completeTime_ != null; - } - /** - * - * - *
-     * Time the operation was completed.
-     * 
- * - * .google.protobuf.Timestamp complete_time = 3; - * - * @return The completeTime. - */ - public com.google.protobuf.Timestamp getCompleteTime() { - if (completeTimeBuilder_ == null) { - return completeTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : completeTime_; - } else { - return completeTimeBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Time the operation was completed.
-     * 
- * - * .google.protobuf.Timestamp complete_time = 3; - */ - public Builder setCompleteTime(com.google.protobuf.Timestamp value) { - if (completeTimeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - completeTime_ = value; - onChanged(); - } else { - completeTimeBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * Time the operation was completed.
-     * 
- * - * .google.protobuf.Timestamp complete_time = 3; - */ - public Builder setCompleteTime(com.google.protobuf.Timestamp.Builder builderForValue) { - if (completeTimeBuilder_ == null) { - completeTime_ = builderForValue.build(); - onChanged(); - } else { - completeTimeBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Time the operation was completed.
-     * 
- * - * .google.protobuf.Timestamp complete_time = 3; - */ - public Builder mergeCompleteTime(com.google.protobuf.Timestamp value) { - if (completeTimeBuilder_ == null) { - if (completeTime_ != null) { - completeTime_ = - com.google.protobuf.Timestamp.newBuilder(completeTime_) - .mergeFrom(value) - .buildPartial(); - } else { - completeTime_ = value; - } - onChanged(); - } else { - completeTimeBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * Time the operation was completed.
-     * 
- * - * .google.protobuf.Timestamp complete_time = 3; - */ - public Builder clearCompleteTime() { - if (completeTimeBuilder_ == null) { - completeTime_ = null; - onChanged(); - } else { - completeTime_ = null; - completeTimeBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Time the operation was completed.
-     * 
- * - * .google.protobuf.Timestamp complete_time = 3; - */ - public com.google.protobuf.Timestamp.Builder getCompleteTimeBuilder() { - - onChanged(); - return getCompleteTimeFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Time the operation was completed.
-     * 
- * - * .google.protobuf.Timestamp complete_time = 3; - */ - public com.google.protobuf.TimestampOrBuilder getCompleteTimeOrBuilder() { - if (completeTimeBuilder_ != null) { - return completeTimeBuilder_.getMessageOrBuilder(); - } else { - return completeTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : completeTime_; - } - } - /** - * - * - *
-     * Time the operation was completed.
-     * 
- * - * .google.protobuf.Timestamp complete_time = 3; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - getCompleteTimeFieldBuilder() { - if (completeTimeBuilder_ == null) { - completeTimeBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder>( - getCompleteTime(), getParentForChildren(), isClean()); - completeTime_ = null; - } - return completeTimeBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.CreateWorkerPoolOperationMetadata) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.CreateWorkerPoolOperationMetadata) - private static final com.google.cloudbuild.v1.CreateWorkerPoolOperationMetadata DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.CreateWorkerPoolOperationMetadata(); - } - - public static com.google.cloudbuild.v1.CreateWorkerPoolOperationMetadata getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public CreateWorkerPoolOperationMetadata parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.CreateWorkerPoolOperationMetadata getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CreateWorkerPoolOperationMetadataOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CreateWorkerPoolOperationMetadataOrBuilder.java deleted file mode 100644 index b2fecaac..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CreateWorkerPoolOperationMetadataOrBuilder.java +++ /dev/null @@ -1,124 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface CreateWorkerPoolOperationMetadataOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.CreateWorkerPoolOperationMetadata) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The resource name of the `WorkerPool` to create.
-   * Format:
-   * `projects/{project}/locations/{location}/workerPools/{worker_pool}`.
-   * 
- * - * string worker_pool = 1 [(.google.api.resource_reference) = { ... } - * - * @return The workerPool. - */ - java.lang.String getWorkerPool(); - /** - * - * - *
-   * The resource name of the `WorkerPool` to create.
-   * Format:
-   * `projects/{project}/locations/{location}/workerPools/{worker_pool}`.
-   * 
- * - * string worker_pool = 1 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for workerPool. - */ - com.google.protobuf.ByteString getWorkerPoolBytes(); - - /** - * - * - *
-   * Time the operation was created.
-   * 
- * - * .google.protobuf.Timestamp create_time = 2; - * - * @return Whether the createTime field is set. - */ - boolean hasCreateTime(); - /** - * - * - *
-   * Time the operation was created.
-   * 
- * - * .google.protobuf.Timestamp create_time = 2; - * - * @return The createTime. - */ - com.google.protobuf.Timestamp getCreateTime(); - /** - * - * - *
-   * Time the operation was created.
-   * 
- * - * .google.protobuf.Timestamp create_time = 2; - */ - com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder(); - - /** - * - * - *
-   * Time the operation was completed.
-   * 
- * - * .google.protobuf.Timestamp complete_time = 3; - * - * @return Whether the completeTime field is set. - */ - boolean hasCompleteTime(); - /** - * - * - *
-   * Time the operation was completed.
-   * 
- * - * .google.protobuf.Timestamp complete_time = 3; - * - * @return The completeTime. - */ - com.google.protobuf.Timestamp getCompleteTime(); - /** - * - * - *
-   * Time the operation was completed.
-   * 
- * - * .google.protobuf.Timestamp complete_time = 3; - */ - com.google.protobuf.TimestampOrBuilder getCompleteTimeOrBuilder(); -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CreateWorkerPoolRequest.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CreateWorkerPoolRequest.java deleted file mode 100644 index c9f1b35d..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CreateWorkerPoolRequest.java +++ /dev/null @@ -1,1235 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * Request to create a new `WorkerPool`.
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.CreateWorkerPoolRequest} - */ -public final class CreateWorkerPoolRequest extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.CreateWorkerPoolRequest) - CreateWorkerPoolRequestOrBuilder { - private static final long serialVersionUID = 0L; - // Use CreateWorkerPoolRequest.newBuilder() to construct. - private CreateWorkerPoolRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private CreateWorkerPoolRequest() { - parent_ = ""; - workerPoolId_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new CreateWorkerPoolRequest(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_CreateWorkerPoolRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_CreateWorkerPoolRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.CreateWorkerPoolRequest.class, - com.google.cloudbuild.v1.CreateWorkerPoolRequest.Builder.class); - } - - public static final int PARENT_FIELD_NUMBER = 1; - private volatile java.lang.Object parent_; - /** - * - * - *
-   * Required. The parent resource where this worker pool will be created.
-   * Format: `projects/{project}/locations/{location}`.
-   * 
- * - * - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return The parent. - */ - @java.lang.Override - public java.lang.String getParent() { - java.lang.Object ref = parent_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - parent_ = s; - return s; - } - } - /** - * - * - *
-   * Required. The parent resource where this worker pool will be created.
-   * Format: `projects/{project}/locations/{location}`.
-   * 
- * - * - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return The bytes for parent. - */ - @java.lang.Override - public com.google.protobuf.ByteString getParentBytes() { - java.lang.Object ref = parent_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - parent_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int WORKER_POOL_FIELD_NUMBER = 2; - private com.google.cloudbuild.v1.WorkerPool workerPool_; - /** - * - * - *
-   * Required. `WorkerPool` resource to create.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.WorkerPool worker_pool = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * - * @return Whether the workerPool field is set. - */ - @java.lang.Override - public boolean hasWorkerPool() { - return workerPool_ != null; - } - /** - * - * - *
-   * Required. `WorkerPool` resource to create.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.WorkerPool worker_pool = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * - * @return The workerPool. - */ - @java.lang.Override - public com.google.cloudbuild.v1.WorkerPool getWorkerPool() { - return workerPool_ == null - ? com.google.cloudbuild.v1.WorkerPool.getDefaultInstance() - : workerPool_; - } - /** - * - * - *
-   * Required. `WorkerPool` resource to create.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.WorkerPool worker_pool = 2 [(.google.api.field_behavior) = REQUIRED]; - * - */ - @java.lang.Override - public com.google.cloudbuild.v1.WorkerPoolOrBuilder getWorkerPoolOrBuilder() { - return getWorkerPool(); - } - - public static final int WORKER_POOL_ID_FIELD_NUMBER = 3; - private volatile java.lang.Object workerPoolId_; - /** - * - * - *
-   * Required. Immutable. The ID to use for the `WorkerPool`, which will become
-   * the final component of the resource name.
-   * This value should be 1-63 characters, and valid characters
-   * are /[a-z][0-9]-/.
-   * 
- * - * - * string worker_pool_id = 3 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = REQUIRED]; - * - * - * @return The workerPoolId. - */ - @java.lang.Override - public java.lang.String getWorkerPoolId() { - java.lang.Object ref = workerPoolId_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - workerPoolId_ = s; - return s; - } - } - /** - * - * - *
-   * Required. Immutable. The ID to use for the `WorkerPool`, which will become
-   * the final component of the resource name.
-   * This value should be 1-63 characters, and valid characters
-   * are /[a-z][0-9]-/.
-   * 
- * - * - * string worker_pool_id = 3 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = REQUIRED]; - * - * - * @return The bytes for workerPoolId. - */ - @java.lang.Override - public com.google.protobuf.ByteString getWorkerPoolIdBytes() { - java.lang.Object ref = workerPoolId_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - workerPoolId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int VALIDATE_ONLY_FIELD_NUMBER = 4; - private boolean validateOnly_; - /** - * - * - *
-   * If set, validate the request and preview the response, but do not actually
-   * post it.
-   * 
- * - * bool validate_only = 4; - * - * @return The validateOnly. - */ - @java.lang.Override - public boolean getValidateOnly() { - return validateOnly_; - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, parent_); - } - if (workerPool_ != null) { - output.writeMessage(2, getWorkerPool()); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(workerPoolId_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 3, workerPoolId_); - } - if (validateOnly_ != false) { - output.writeBool(4, validateOnly_); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, parent_); - } - if (workerPool_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getWorkerPool()); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(workerPoolId_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, workerPoolId_); - } - if (validateOnly_ != false) { - size += com.google.protobuf.CodedOutputStream.computeBoolSize(4, validateOnly_); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.CreateWorkerPoolRequest)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.CreateWorkerPoolRequest other = - (com.google.cloudbuild.v1.CreateWorkerPoolRequest) obj; - - if (!getParent().equals(other.getParent())) return false; - if (hasWorkerPool() != other.hasWorkerPool()) return false; - if (hasWorkerPool()) { - if (!getWorkerPool().equals(other.getWorkerPool())) return false; - } - if (!getWorkerPoolId().equals(other.getWorkerPoolId())) return false; - if (getValidateOnly() != other.getValidateOnly()) return false; - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + PARENT_FIELD_NUMBER; - hash = (53 * hash) + getParent().hashCode(); - if (hasWorkerPool()) { - hash = (37 * hash) + WORKER_POOL_FIELD_NUMBER; - hash = (53 * hash) + getWorkerPool().hashCode(); - } - hash = (37 * hash) + WORKER_POOL_ID_FIELD_NUMBER; - hash = (53 * hash) + getWorkerPoolId().hashCode(); - hash = (37 * hash) + VALIDATE_ONLY_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getValidateOnly()); - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.CreateWorkerPoolRequest parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.CreateWorkerPoolRequest parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.CreateWorkerPoolRequest parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.CreateWorkerPoolRequest parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.CreateWorkerPoolRequest parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.CreateWorkerPoolRequest parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.CreateWorkerPoolRequest parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.CreateWorkerPoolRequest parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.CreateWorkerPoolRequest parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.CreateWorkerPoolRequest parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.CreateWorkerPoolRequest parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.CreateWorkerPoolRequest parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.CreateWorkerPoolRequest prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * Request to create a new `WorkerPool`.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.CreateWorkerPoolRequest} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.CreateWorkerPoolRequest) - com.google.cloudbuild.v1.CreateWorkerPoolRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_CreateWorkerPoolRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_CreateWorkerPoolRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.CreateWorkerPoolRequest.class, - com.google.cloudbuild.v1.CreateWorkerPoolRequest.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.CreateWorkerPoolRequest.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - parent_ = ""; - - if (workerPoolBuilder_ == null) { - workerPool_ = null; - } else { - workerPool_ = null; - workerPoolBuilder_ = null; - } - workerPoolId_ = ""; - - validateOnly_ = false; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_CreateWorkerPoolRequest_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.CreateWorkerPoolRequest getDefaultInstanceForType() { - return com.google.cloudbuild.v1.CreateWorkerPoolRequest.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.CreateWorkerPoolRequest build() { - com.google.cloudbuild.v1.CreateWorkerPoolRequest result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.CreateWorkerPoolRequest buildPartial() { - com.google.cloudbuild.v1.CreateWorkerPoolRequest result = - new com.google.cloudbuild.v1.CreateWorkerPoolRequest(this); - result.parent_ = parent_; - if (workerPoolBuilder_ == null) { - result.workerPool_ = workerPool_; - } else { - result.workerPool_ = workerPoolBuilder_.build(); - } - result.workerPoolId_ = workerPoolId_; - result.validateOnly_ = validateOnly_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.CreateWorkerPoolRequest) { - return mergeFrom((com.google.cloudbuild.v1.CreateWorkerPoolRequest) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.CreateWorkerPoolRequest other) { - if (other == com.google.cloudbuild.v1.CreateWorkerPoolRequest.getDefaultInstance()) - return this; - if (!other.getParent().isEmpty()) { - parent_ = other.parent_; - onChanged(); - } - if (other.hasWorkerPool()) { - mergeWorkerPool(other.getWorkerPool()); - } - if (!other.getWorkerPoolId().isEmpty()) { - workerPoolId_ = other.workerPoolId_; - onChanged(); - } - if (other.getValidateOnly() != false) { - setValidateOnly(other.getValidateOnly()); - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - parent_ = input.readStringRequireUtf8(); - - break; - } // case 10 - case 18: - { - input.readMessage(getWorkerPoolFieldBuilder().getBuilder(), extensionRegistry); - - break; - } // case 18 - case 26: - { - workerPoolId_ = input.readStringRequireUtf8(); - - break; - } // case 26 - case 32: - { - validateOnly_ = input.readBool(); - - break; - } // case 32 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private java.lang.Object parent_ = ""; - /** - * - * - *
-     * Required. The parent resource where this worker pool will be created.
-     * Format: `projects/{project}/locations/{location}`.
-     * 
- * - * - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return The parent. - */ - public java.lang.String getParent() { - java.lang.Object ref = parent_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - parent_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Required. The parent resource where this worker pool will be created.
-     * Format: `projects/{project}/locations/{location}`.
-     * 
- * - * - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return The bytes for parent. - */ - public com.google.protobuf.ByteString getParentBytes() { - java.lang.Object ref = parent_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - parent_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Required. The parent resource where this worker pool will be created.
-     * Format: `projects/{project}/locations/{location}`.
-     * 
- * - * - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @param value The parent to set. - * @return This builder for chaining. - */ - public Builder setParent(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - parent_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Required. The parent resource where this worker pool will be created.
-     * Format: `projects/{project}/locations/{location}`.
-     * 
- * - * - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return This builder for chaining. - */ - public Builder clearParent() { - - parent_ = getDefaultInstance().getParent(); - onChanged(); - return this; - } - /** - * - * - *
-     * Required. The parent resource where this worker pool will be created.
-     * Format: `projects/{project}/locations/{location}`.
-     * 
- * - * - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @param value The bytes for parent to set. - * @return This builder for chaining. - */ - public Builder setParentBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - parent_ = value; - onChanged(); - return this; - } - - private com.google.cloudbuild.v1.WorkerPool workerPool_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.WorkerPool, - com.google.cloudbuild.v1.WorkerPool.Builder, - com.google.cloudbuild.v1.WorkerPoolOrBuilder> - workerPoolBuilder_; - /** - * - * - *
-     * Required. `WorkerPool` resource to create.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.WorkerPool worker_pool = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * - * @return Whether the workerPool field is set. - */ - public boolean hasWorkerPool() { - return workerPoolBuilder_ != null || workerPool_ != null; - } - /** - * - * - *
-     * Required. `WorkerPool` resource to create.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.WorkerPool worker_pool = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * - * @return The workerPool. - */ - public com.google.cloudbuild.v1.WorkerPool getWorkerPool() { - if (workerPoolBuilder_ == null) { - return workerPool_ == null - ? com.google.cloudbuild.v1.WorkerPool.getDefaultInstance() - : workerPool_; - } else { - return workerPoolBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Required. `WorkerPool` resource to create.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.WorkerPool worker_pool = 2 [(.google.api.field_behavior) = REQUIRED]; - * - */ - public Builder setWorkerPool(com.google.cloudbuild.v1.WorkerPool value) { - if (workerPoolBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - workerPool_ = value; - onChanged(); - } else { - workerPoolBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * Required. `WorkerPool` resource to create.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.WorkerPool worker_pool = 2 [(.google.api.field_behavior) = REQUIRED]; - * - */ - public Builder setWorkerPool(com.google.cloudbuild.v1.WorkerPool.Builder builderForValue) { - if (workerPoolBuilder_ == null) { - workerPool_ = builderForValue.build(); - onChanged(); - } else { - workerPoolBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Required. `WorkerPool` resource to create.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.WorkerPool worker_pool = 2 [(.google.api.field_behavior) = REQUIRED]; - * - */ - public Builder mergeWorkerPool(com.google.cloudbuild.v1.WorkerPool value) { - if (workerPoolBuilder_ == null) { - if (workerPool_ != null) { - workerPool_ = - com.google.cloudbuild.v1.WorkerPool.newBuilder(workerPool_) - .mergeFrom(value) - .buildPartial(); - } else { - workerPool_ = value; - } - onChanged(); - } else { - workerPoolBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * Required. `WorkerPool` resource to create.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.WorkerPool worker_pool = 2 [(.google.api.field_behavior) = REQUIRED]; - * - */ - public Builder clearWorkerPool() { - if (workerPoolBuilder_ == null) { - workerPool_ = null; - onChanged(); - } else { - workerPool_ = null; - workerPoolBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Required. `WorkerPool` resource to create.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.WorkerPool worker_pool = 2 [(.google.api.field_behavior) = REQUIRED]; - * - */ - public com.google.cloudbuild.v1.WorkerPool.Builder getWorkerPoolBuilder() { - - onChanged(); - return getWorkerPoolFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Required. `WorkerPool` resource to create.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.WorkerPool worker_pool = 2 [(.google.api.field_behavior) = REQUIRED]; - * - */ - public com.google.cloudbuild.v1.WorkerPoolOrBuilder getWorkerPoolOrBuilder() { - if (workerPoolBuilder_ != null) { - return workerPoolBuilder_.getMessageOrBuilder(); - } else { - return workerPool_ == null - ? com.google.cloudbuild.v1.WorkerPool.getDefaultInstance() - : workerPool_; - } - } - /** - * - * - *
-     * Required. `WorkerPool` resource to create.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.WorkerPool worker_pool = 2 [(.google.api.field_behavior) = REQUIRED]; - * - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.WorkerPool, - com.google.cloudbuild.v1.WorkerPool.Builder, - com.google.cloudbuild.v1.WorkerPoolOrBuilder> - getWorkerPoolFieldBuilder() { - if (workerPoolBuilder_ == null) { - workerPoolBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.WorkerPool, - com.google.cloudbuild.v1.WorkerPool.Builder, - com.google.cloudbuild.v1.WorkerPoolOrBuilder>( - getWorkerPool(), getParentForChildren(), isClean()); - workerPool_ = null; - } - return workerPoolBuilder_; - } - - private java.lang.Object workerPoolId_ = ""; - /** - * - * - *
-     * Required. Immutable. The ID to use for the `WorkerPool`, which will become
-     * the final component of the resource name.
-     * This value should be 1-63 characters, and valid characters
-     * are /[a-z][0-9]-/.
-     * 
- * - * - * string worker_pool_id = 3 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = REQUIRED]; - * - * - * @return The workerPoolId. - */ - public java.lang.String getWorkerPoolId() { - java.lang.Object ref = workerPoolId_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - workerPoolId_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Required. Immutable. The ID to use for the `WorkerPool`, which will become
-     * the final component of the resource name.
-     * This value should be 1-63 characters, and valid characters
-     * are /[a-z][0-9]-/.
-     * 
- * - * - * string worker_pool_id = 3 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = REQUIRED]; - * - * - * @return The bytes for workerPoolId. - */ - public com.google.protobuf.ByteString getWorkerPoolIdBytes() { - java.lang.Object ref = workerPoolId_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - workerPoolId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Required. Immutable. The ID to use for the `WorkerPool`, which will become
-     * the final component of the resource name.
-     * This value should be 1-63 characters, and valid characters
-     * are /[a-z][0-9]-/.
-     * 
- * - * - * string worker_pool_id = 3 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = REQUIRED]; - * - * - * @param value The workerPoolId to set. - * @return This builder for chaining. - */ - public Builder setWorkerPoolId(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - workerPoolId_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Required. Immutable. The ID to use for the `WorkerPool`, which will become
-     * the final component of the resource name.
-     * This value should be 1-63 characters, and valid characters
-     * are /[a-z][0-9]-/.
-     * 
- * - * - * string worker_pool_id = 3 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = REQUIRED]; - * - * - * @return This builder for chaining. - */ - public Builder clearWorkerPoolId() { - - workerPoolId_ = getDefaultInstance().getWorkerPoolId(); - onChanged(); - return this; - } - /** - * - * - *
-     * Required. Immutable. The ID to use for the `WorkerPool`, which will become
-     * the final component of the resource name.
-     * This value should be 1-63 characters, and valid characters
-     * are /[a-z][0-9]-/.
-     * 
- * - * - * string worker_pool_id = 3 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = REQUIRED]; - * - * - * @param value The bytes for workerPoolId to set. - * @return This builder for chaining. - */ - public Builder setWorkerPoolIdBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - workerPoolId_ = value; - onChanged(); - return this; - } - - private boolean validateOnly_; - /** - * - * - *
-     * If set, validate the request and preview the response, but do not actually
-     * post it.
-     * 
- * - * bool validate_only = 4; - * - * @return The validateOnly. - */ - @java.lang.Override - public boolean getValidateOnly() { - return validateOnly_; - } - /** - * - * - *
-     * If set, validate the request and preview the response, but do not actually
-     * post it.
-     * 
- * - * bool validate_only = 4; - * - * @param value The validateOnly to set. - * @return This builder for chaining. - */ - public Builder setValidateOnly(boolean value) { - - validateOnly_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * If set, validate the request and preview the response, but do not actually
-     * post it.
-     * 
- * - * bool validate_only = 4; - * - * @return This builder for chaining. - */ - public Builder clearValidateOnly() { - - validateOnly_ = false; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.CreateWorkerPoolRequest) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.CreateWorkerPoolRequest) - private static final com.google.cloudbuild.v1.CreateWorkerPoolRequest DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.CreateWorkerPoolRequest(); - } - - public static com.google.cloudbuild.v1.CreateWorkerPoolRequest getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public CreateWorkerPoolRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.CreateWorkerPoolRequest getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CreateWorkerPoolRequestOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CreateWorkerPoolRequestOrBuilder.java deleted file mode 100644 index c53d30a6..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CreateWorkerPoolRequestOrBuilder.java +++ /dev/null @@ -1,146 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface CreateWorkerPoolRequestOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.CreateWorkerPoolRequest) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * Required. The parent resource where this worker pool will be created.
-   * Format: `projects/{project}/locations/{location}`.
-   * 
- * - * - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return The parent. - */ - java.lang.String getParent(); - /** - * - * - *
-   * Required. The parent resource where this worker pool will be created.
-   * Format: `projects/{project}/locations/{location}`.
-   * 
- * - * - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return The bytes for parent. - */ - com.google.protobuf.ByteString getParentBytes(); - - /** - * - * - *
-   * Required. `WorkerPool` resource to create.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.WorkerPool worker_pool = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * - * @return Whether the workerPool field is set. - */ - boolean hasWorkerPool(); - /** - * - * - *
-   * Required. `WorkerPool` resource to create.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.WorkerPool worker_pool = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * - * @return The workerPool. - */ - com.google.cloudbuild.v1.WorkerPool getWorkerPool(); - /** - * - * - *
-   * Required. `WorkerPool` resource to create.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.WorkerPool worker_pool = 2 [(.google.api.field_behavior) = REQUIRED]; - * - */ - com.google.cloudbuild.v1.WorkerPoolOrBuilder getWorkerPoolOrBuilder(); - - /** - * - * - *
-   * Required. Immutable. The ID to use for the `WorkerPool`, which will become
-   * the final component of the resource name.
-   * This value should be 1-63 characters, and valid characters
-   * are /[a-z][0-9]-/.
-   * 
- * - * - * string worker_pool_id = 3 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = REQUIRED]; - * - * - * @return The workerPoolId. - */ - java.lang.String getWorkerPoolId(); - /** - * - * - *
-   * Required. Immutable. The ID to use for the `WorkerPool`, which will become
-   * the final component of the resource name.
-   * This value should be 1-63 characters, and valid characters
-   * are /[a-z][0-9]-/.
-   * 
- * - * - * string worker_pool_id = 3 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = REQUIRED]; - * - * - * @return The bytes for workerPoolId. - */ - com.google.protobuf.ByteString getWorkerPoolIdBytes(); - - /** - * - * - *
-   * If set, validate the request and preview the response, but do not actually
-   * post it.
-   * 
- * - * bool validate_only = 4; - * - * @return The validateOnly. - */ - boolean getValidateOnly(); -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/DeleteBuildTriggerRequest.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/DeleteBuildTriggerRequest.java deleted file mode 100644 index faa1af31..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/DeleteBuildTriggerRequest.java +++ /dev/null @@ -1,978 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * Request to delete a `BuildTrigger`.
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.DeleteBuildTriggerRequest} - */ -public final class DeleteBuildTriggerRequest extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.DeleteBuildTriggerRequest) - DeleteBuildTriggerRequestOrBuilder { - private static final long serialVersionUID = 0L; - // Use DeleteBuildTriggerRequest.newBuilder() to construct. - private DeleteBuildTriggerRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private DeleteBuildTriggerRequest() { - name_ = ""; - projectId_ = ""; - triggerId_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new DeleteBuildTriggerRequest(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_DeleteBuildTriggerRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_DeleteBuildTriggerRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.DeleteBuildTriggerRequest.class, - com.google.cloudbuild.v1.DeleteBuildTriggerRequest.Builder.class); - } - - public static final int NAME_FIELD_NUMBER = 3; - private volatile java.lang.Object name_; - /** - * - * - *
-   * The name of the `Trigger` to delete.
-   * Format: `projects/{project}/locations/{location}/triggers/{trigger}`
-   * 
- * - * string name = 3 [(.google.api.resource_reference) = { ... } - * - * @return The name. - */ - @java.lang.Override - public java.lang.String getName() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - name_ = s; - return s; - } - } - /** - * - * - *
-   * The name of the `Trigger` to delete.
-   * Format: `projects/{project}/locations/{location}/triggers/{trigger}`
-   * 
- * - * string name = 3 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for name. - */ - @java.lang.Override - public com.google.protobuf.ByteString getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int PROJECT_ID_FIELD_NUMBER = 1; - private volatile java.lang.Object projectId_; - /** - * - * - *
-   * Required. ID of the project that owns the trigger.
-   * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The projectId. - */ - @java.lang.Override - public java.lang.String getProjectId() { - java.lang.Object ref = projectId_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - projectId_ = s; - return s; - } - } - /** - * - * - *
-   * Required. ID of the project that owns the trigger.
-   * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for projectId. - */ - @java.lang.Override - public com.google.protobuf.ByteString getProjectIdBytes() { - java.lang.Object ref = projectId_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - projectId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int TRIGGER_ID_FIELD_NUMBER = 2; - private volatile java.lang.Object triggerId_; - /** - * - * - *
-   * Required. ID of the `BuildTrigger` to delete.
-   * 
- * - * string trigger_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The triggerId. - */ - @java.lang.Override - public java.lang.String getTriggerId() { - java.lang.Object ref = triggerId_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - triggerId_ = s; - return s; - } - } - /** - * - * - *
-   * Required. ID of the `BuildTrigger` to delete.
-   * 
- * - * string trigger_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for triggerId. - */ - @java.lang.Override - public com.google.protobuf.ByteString getTriggerIdBytes() { - java.lang.Object ref = triggerId_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - triggerId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(projectId_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, projectId_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(triggerId_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, triggerId_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 3, name_); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(projectId_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, projectId_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(triggerId_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, triggerId_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, name_); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.DeleteBuildTriggerRequest)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.DeleteBuildTriggerRequest other = - (com.google.cloudbuild.v1.DeleteBuildTriggerRequest) obj; - - if (!getName().equals(other.getName())) return false; - if (!getProjectId().equals(other.getProjectId())) return false; - if (!getTriggerId().equals(other.getTriggerId())) return false; - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + NAME_FIELD_NUMBER; - hash = (53 * hash) + getName().hashCode(); - hash = (37 * hash) + PROJECT_ID_FIELD_NUMBER; - hash = (53 * hash) + getProjectId().hashCode(); - hash = (37 * hash) + TRIGGER_ID_FIELD_NUMBER; - hash = (53 * hash) + getTriggerId().hashCode(); - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.DeleteBuildTriggerRequest parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.DeleteBuildTriggerRequest parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.DeleteBuildTriggerRequest parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.DeleteBuildTriggerRequest parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.DeleteBuildTriggerRequest parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.DeleteBuildTriggerRequest parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.DeleteBuildTriggerRequest parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.DeleteBuildTriggerRequest parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.DeleteBuildTriggerRequest parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.DeleteBuildTriggerRequest parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.DeleteBuildTriggerRequest parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.DeleteBuildTriggerRequest parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.DeleteBuildTriggerRequest prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * Request to delete a `BuildTrigger`.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.DeleteBuildTriggerRequest} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.DeleteBuildTriggerRequest) - com.google.cloudbuild.v1.DeleteBuildTriggerRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_DeleteBuildTriggerRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_DeleteBuildTriggerRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.DeleteBuildTriggerRequest.class, - com.google.cloudbuild.v1.DeleteBuildTriggerRequest.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.DeleteBuildTriggerRequest.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - name_ = ""; - - projectId_ = ""; - - triggerId_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_DeleteBuildTriggerRequest_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.DeleteBuildTriggerRequest getDefaultInstanceForType() { - return com.google.cloudbuild.v1.DeleteBuildTriggerRequest.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.DeleteBuildTriggerRequest build() { - com.google.cloudbuild.v1.DeleteBuildTriggerRequest result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.DeleteBuildTriggerRequest buildPartial() { - com.google.cloudbuild.v1.DeleteBuildTriggerRequest result = - new com.google.cloudbuild.v1.DeleteBuildTriggerRequest(this); - result.name_ = name_; - result.projectId_ = projectId_; - result.triggerId_ = triggerId_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.DeleteBuildTriggerRequest) { - return mergeFrom((com.google.cloudbuild.v1.DeleteBuildTriggerRequest) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.DeleteBuildTriggerRequest other) { - if (other == com.google.cloudbuild.v1.DeleteBuildTriggerRequest.getDefaultInstance()) - return this; - if (!other.getName().isEmpty()) { - name_ = other.name_; - onChanged(); - } - if (!other.getProjectId().isEmpty()) { - projectId_ = other.projectId_; - onChanged(); - } - if (!other.getTriggerId().isEmpty()) { - triggerId_ = other.triggerId_; - onChanged(); - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - projectId_ = input.readStringRequireUtf8(); - - break; - } // case 10 - case 18: - { - triggerId_ = input.readStringRequireUtf8(); - - break; - } // case 18 - case 26: - { - name_ = input.readStringRequireUtf8(); - - break; - } // case 26 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private java.lang.Object name_ = ""; - /** - * - * - *
-     * The name of the `Trigger` to delete.
-     * Format: `projects/{project}/locations/{location}/triggers/{trigger}`
-     * 
- * - * string name = 3 [(.google.api.resource_reference) = { ... } - * - * @return The name. - */ - public java.lang.String getName() { - java.lang.Object ref = name_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - name_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * The name of the `Trigger` to delete.
-     * Format: `projects/{project}/locations/{location}/triggers/{trigger}`
-     * 
- * - * string name = 3 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for name. - */ - public com.google.protobuf.ByteString getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * The name of the `Trigger` to delete.
-     * Format: `projects/{project}/locations/{location}/triggers/{trigger}`
-     * 
- * - * string name = 3 [(.google.api.resource_reference) = { ... } - * - * @param value The name to set. - * @return This builder for chaining. - */ - public Builder setName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - name_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the `Trigger` to delete.
-     * Format: `projects/{project}/locations/{location}/triggers/{trigger}`
-     * 
- * - * string name = 3 [(.google.api.resource_reference) = { ... } - * - * @return This builder for chaining. - */ - public Builder clearName() { - - name_ = getDefaultInstance().getName(); - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the `Trigger` to delete.
-     * Format: `projects/{project}/locations/{location}/triggers/{trigger}`
-     * 
- * - * string name = 3 [(.google.api.resource_reference) = { ... } - * - * @param value The bytes for name to set. - * @return This builder for chaining. - */ - public Builder setNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - name_ = value; - onChanged(); - return this; - } - - private java.lang.Object projectId_ = ""; - /** - * - * - *
-     * Required. ID of the project that owns the trigger.
-     * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The projectId. - */ - public java.lang.String getProjectId() { - java.lang.Object ref = projectId_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - projectId_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Required. ID of the project that owns the trigger.
-     * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for projectId. - */ - public com.google.protobuf.ByteString getProjectIdBytes() { - java.lang.Object ref = projectId_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - projectId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Required. ID of the project that owns the trigger.
-     * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @param value The projectId to set. - * @return This builder for chaining. - */ - public Builder setProjectId(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - projectId_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Required. ID of the project that owns the trigger.
-     * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return This builder for chaining. - */ - public Builder clearProjectId() { - - projectId_ = getDefaultInstance().getProjectId(); - onChanged(); - return this; - } - /** - * - * - *
-     * Required. ID of the project that owns the trigger.
-     * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @param value The bytes for projectId to set. - * @return This builder for chaining. - */ - public Builder setProjectIdBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - projectId_ = value; - onChanged(); - return this; - } - - private java.lang.Object triggerId_ = ""; - /** - * - * - *
-     * Required. ID of the `BuildTrigger` to delete.
-     * 
- * - * string trigger_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The triggerId. - */ - public java.lang.String getTriggerId() { - java.lang.Object ref = triggerId_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - triggerId_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Required. ID of the `BuildTrigger` to delete.
-     * 
- * - * string trigger_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for triggerId. - */ - public com.google.protobuf.ByteString getTriggerIdBytes() { - java.lang.Object ref = triggerId_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - triggerId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Required. ID of the `BuildTrigger` to delete.
-     * 
- * - * string trigger_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @param value The triggerId to set. - * @return This builder for chaining. - */ - public Builder setTriggerId(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - triggerId_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Required. ID of the `BuildTrigger` to delete.
-     * 
- * - * string trigger_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @return This builder for chaining. - */ - public Builder clearTriggerId() { - - triggerId_ = getDefaultInstance().getTriggerId(); - onChanged(); - return this; - } - /** - * - * - *
-     * Required. ID of the `BuildTrigger` to delete.
-     * 
- * - * string trigger_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @param value The bytes for triggerId to set. - * @return This builder for chaining. - */ - public Builder setTriggerIdBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - triggerId_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.DeleteBuildTriggerRequest) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.DeleteBuildTriggerRequest) - private static final com.google.cloudbuild.v1.DeleteBuildTriggerRequest DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.DeleteBuildTriggerRequest(); - } - - public static com.google.cloudbuild.v1.DeleteBuildTriggerRequest getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public DeleteBuildTriggerRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.DeleteBuildTriggerRequest getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/DeleteBuildTriggerRequestOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/DeleteBuildTriggerRequestOrBuilder.java deleted file mode 100644 index 4ac0d214..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/DeleteBuildTriggerRequestOrBuilder.java +++ /dev/null @@ -1,102 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface DeleteBuildTriggerRequestOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.DeleteBuildTriggerRequest) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The name of the `Trigger` to delete.
-   * Format: `projects/{project}/locations/{location}/triggers/{trigger}`
-   * 
- * - * string name = 3 [(.google.api.resource_reference) = { ... } - * - * @return The name. - */ - java.lang.String getName(); - /** - * - * - *
-   * The name of the `Trigger` to delete.
-   * Format: `projects/{project}/locations/{location}/triggers/{trigger}`
-   * 
- * - * string name = 3 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for name. - */ - com.google.protobuf.ByteString getNameBytes(); - - /** - * - * - *
-   * Required. ID of the project that owns the trigger.
-   * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The projectId. - */ - java.lang.String getProjectId(); - /** - * - * - *
-   * Required. ID of the project that owns the trigger.
-   * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for projectId. - */ - com.google.protobuf.ByteString getProjectIdBytes(); - - /** - * - * - *
-   * Required. ID of the `BuildTrigger` to delete.
-   * 
- * - * string trigger_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The triggerId. - */ - java.lang.String getTriggerId(); - /** - * - * - *
-   * Required. ID of the `BuildTrigger` to delete.
-   * 
- * - * string trigger_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for triggerId. - */ - com.google.protobuf.ByteString getTriggerIdBytes(); -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/DeleteWorkerPoolOperationMetadata.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/DeleteWorkerPoolOperationMetadata.java deleted file mode 100644 index 03e78475..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/DeleteWorkerPoolOperationMetadata.java +++ /dev/null @@ -1,1161 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * Metadata for the `DeleteWorkerPool` operation.
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.DeleteWorkerPoolOperationMetadata} - */ -public final class DeleteWorkerPoolOperationMetadata extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.DeleteWorkerPoolOperationMetadata) - DeleteWorkerPoolOperationMetadataOrBuilder { - private static final long serialVersionUID = 0L; - // Use DeleteWorkerPoolOperationMetadata.newBuilder() to construct. - private DeleteWorkerPoolOperationMetadata( - com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private DeleteWorkerPoolOperationMetadata() { - workerPool_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new DeleteWorkerPoolOperationMetadata(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_DeleteWorkerPoolOperationMetadata_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_DeleteWorkerPoolOperationMetadata_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.DeleteWorkerPoolOperationMetadata.class, - com.google.cloudbuild.v1.DeleteWorkerPoolOperationMetadata.Builder.class); - } - - public static final int WORKER_POOL_FIELD_NUMBER = 1; - private volatile java.lang.Object workerPool_; - /** - * - * - *
-   * The resource name of the `WorkerPool` being deleted.
-   * Format:
-   * `projects/{project}/locations/{location}/workerPools/{worker_pool}`.
-   * 
- * - * string worker_pool = 1 [(.google.api.resource_reference) = { ... } - * - * @return The workerPool. - */ - @java.lang.Override - public java.lang.String getWorkerPool() { - java.lang.Object ref = workerPool_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - workerPool_ = s; - return s; - } - } - /** - * - * - *
-   * The resource name of the `WorkerPool` being deleted.
-   * Format:
-   * `projects/{project}/locations/{location}/workerPools/{worker_pool}`.
-   * 
- * - * string worker_pool = 1 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for workerPool. - */ - @java.lang.Override - public com.google.protobuf.ByteString getWorkerPoolBytes() { - java.lang.Object ref = workerPool_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - workerPool_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int CREATE_TIME_FIELD_NUMBER = 2; - private com.google.protobuf.Timestamp createTime_; - /** - * - * - *
-   * Time the operation was created.
-   * 
- * - * .google.protobuf.Timestamp create_time = 2; - * - * @return Whether the createTime field is set. - */ - @java.lang.Override - public boolean hasCreateTime() { - return createTime_ != null; - } - /** - * - * - *
-   * Time the operation was created.
-   * 
- * - * .google.protobuf.Timestamp create_time = 2; - * - * @return The createTime. - */ - @java.lang.Override - public com.google.protobuf.Timestamp getCreateTime() { - return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; - } - /** - * - * - *
-   * Time the operation was created.
-   * 
- * - * .google.protobuf.Timestamp create_time = 2; - */ - @java.lang.Override - public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { - return getCreateTime(); - } - - public static final int COMPLETE_TIME_FIELD_NUMBER = 3; - private com.google.protobuf.Timestamp completeTime_; - /** - * - * - *
-   * Time the operation was completed.
-   * 
- * - * .google.protobuf.Timestamp complete_time = 3; - * - * @return Whether the completeTime field is set. - */ - @java.lang.Override - public boolean hasCompleteTime() { - return completeTime_ != null; - } - /** - * - * - *
-   * Time the operation was completed.
-   * 
- * - * .google.protobuf.Timestamp complete_time = 3; - * - * @return The completeTime. - */ - @java.lang.Override - public com.google.protobuf.Timestamp getCompleteTime() { - return completeTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : completeTime_; - } - /** - * - * - *
-   * Time the operation was completed.
-   * 
- * - * .google.protobuf.Timestamp complete_time = 3; - */ - @java.lang.Override - public com.google.protobuf.TimestampOrBuilder getCompleteTimeOrBuilder() { - return getCompleteTime(); - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(workerPool_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, workerPool_); - } - if (createTime_ != null) { - output.writeMessage(2, getCreateTime()); - } - if (completeTime_ != null) { - output.writeMessage(3, getCompleteTime()); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(workerPool_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, workerPool_); - } - if (createTime_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getCreateTime()); - } - if (completeTime_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getCompleteTime()); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.DeleteWorkerPoolOperationMetadata)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.DeleteWorkerPoolOperationMetadata other = - (com.google.cloudbuild.v1.DeleteWorkerPoolOperationMetadata) obj; - - if (!getWorkerPool().equals(other.getWorkerPool())) return false; - if (hasCreateTime() != other.hasCreateTime()) return false; - if (hasCreateTime()) { - if (!getCreateTime().equals(other.getCreateTime())) return false; - } - if (hasCompleteTime() != other.hasCompleteTime()) return false; - if (hasCompleteTime()) { - if (!getCompleteTime().equals(other.getCompleteTime())) return false; - } - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + WORKER_POOL_FIELD_NUMBER; - hash = (53 * hash) + getWorkerPool().hashCode(); - if (hasCreateTime()) { - hash = (37 * hash) + CREATE_TIME_FIELD_NUMBER; - hash = (53 * hash) + getCreateTime().hashCode(); - } - if (hasCompleteTime()) { - hash = (37 * hash) + COMPLETE_TIME_FIELD_NUMBER; - hash = (53 * hash) + getCompleteTime().hashCode(); - } - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.DeleteWorkerPoolOperationMetadata parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.DeleteWorkerPoolOperationMetadata parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.DeleteWorkerPoolOperationMetadata parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.DeleteWorkerPoolOperationMetadata parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.DeleteWorkerPoolOperationMetadata parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.DeleteWorkerPoolOperationMetadata parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.DeleteWorkerPoolOperationMetadata parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.DeleteWorkerPoolOperationMetadata parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.DeleteWorkerPoolOperationMetadata parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.DeleteWorkerPoolOperationMetadata parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.DeleteWorkerPoolOperationMetadata parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.DeleteWorkerPoolOperationMetadata parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder( - com.google.cloudbuild.v1.DeleteWorkerPoolOperationMetadata prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * Metadata for the `DeleteWorkerPool` operation.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.DeleteWorkerPoolOperationMetadata} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.DeleteWorkerPoolOperationMetadata) - com.google.cloudbuild.v1.DeleteWorkerPoolOperationMetadataOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_DeleteWorkerPoolOperationMetadata_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_DeleteWorkerPoolOperationMetadata_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.DeleteWorkerPoolOperationMetadata.class, - com.google.cloudbuild.v1.DeleteWorkerPoolOperationMetadata.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.DeleteWorkerPoolOperationMetadata.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - workerPool_ = ""; - - if (createTimeBuilder_ == null) { - createTime_ = null; - } else { - createTime_ = null; - createTimeBuilder_ = null; - } - if (completeTimeBuilder_ == null) { - completeTime_ = null; - } else { - completeTime_ = null; - completeTimeBuilder_ = null; - } - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_DeleteWorkerPoolOperationMetadata_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.DeleteWorkerPoolOperationMetadata getDefaultInstanceForType() { - return com.google.cloudbuild.v1.DeleteWorkerPoolOperationMetadata.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.DeleteWorkerPoolOperationMetadata build() { - com.google.cloudbuild.v1.DeleteWorkerPoolOperationMetadata result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.DeleteWorkerPoolOperationMetadata buildPartial() { - com.google.cloudbuild.v1.DeleteWorkerPoolOperationMetadata result = - new com.google.cloudbuild.v1.DeleteWorkerPoolOperationMetadata(this); - result.workerPool_ = workerPool_; - if (createTimeBuilder_ == null) { - result.createTime_ = createTime_; - } else { - result.createTime_ = createTimeBuilder_.build(); - } - if (completeTimeBuilder_ == null) { - result.completeTime_ = completeTime_; - } else { - result.completeTime_ = completeTimeBuilder_.build(); - } - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.DeleteWorkerPoolOperationMetadata) { - return mergeFrom((com.google.cloudbuild.v1.DeleteWorkerPoolOperationMetadata) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.DeleteWorkerPoolOperationMetadata other) { - if (other == com.google.cloudbuild.v1.DeleteWorkerPoolOperationMetadata.getDefaultInstance()) - return this; - if (!other.getWorkerPool().isEmpty()) { - workerPool_ = other.workerPool_; - onChanged(); - } - if (other.hasCreateTime()) { - mergeCreateTime(other.getCreateTime()); - } - if (other.hasCompleteTime()) { - mergeCompleteTime(other.getCompleteTime()); - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - workerPool_ = input.readStringRequireUtf8(); - - break; - } // case 10 - case 18: - { - input.readMessage(getCreateTimeFieldBuilder().getBuilder(), extensionRegistry); - - break; - } // case 18 - case 26: - { - input.readMessage(getCompleteTimeFieldBuilder().getBuilder(), extensionRegistry); - - break; - } // case 26 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private java.lang.Object workerPool_ = ""; - /** - * - * - *
-     * The resource name of the `WorkerPool` being deleted.
-     * Format:
-     * `projects/{project}/locations/{location}/workerPools/{worker_pool}`.
-     * 
- * - * string worker_pool = 1 [(.google.api.resource_reference) = { ... } - * - * @return The workerPool. - */ - public java.lang.String getWorkerPool() { - java.lang.Object ref = workerPool_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - workerPool_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * The resource name of the `WorkerPool` being deleted.
-     * Format:
-     * `projects/{project}/locations/{location}/workerPools/{worker_pool}`.
-     * 
- * - * string worker_pool = 1 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for workerPool. - */ - public com.google.protobuf.ByteString getWorkerPoolBytes() { - java.lang.Object ref = workerPool_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - workerPool_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * The resource name of the `WorkerPool` being deleted.
-     * Format:
-     * `projects/{project}/locations/{location}/workerPools/{worker_pool}`.
-     * 
- * - * string worker_pool = 1 [(.google.api.resource_reference) = { ... } - * - * @param value The workerPool to set. - * @return This builder for chaining. - */ - public Builder setWorkerPool(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - workerPool_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The resource name of the `WorkerPool` being deleted.
-     * Format:
-     * `projects/{project}/locations/{location}/workerPools/{worker_pool}`.
-     * 
- * - * string worker_pool = 1 [(.google.api.resource_reference) = { ... } - * - * @return This builder for chaining. - */ - public Builder clearWorkerPool() { - - workerPool_ = getDefaultInstance().getWorkerPool(); - onChanged(); - return this; - } - /** - * - * - *
-     * The resource name of the `WorkerPool` being deleted.
-     * Format:
-     * `projects/{project}/locations/{location}/workerPools/{worker_pool}`.
-     * 
- * - * string worker_pool = 1 [(.google.api.resource_reference) = { ... } - * - * @param value The bytes for workerPool to set. - * @return This builder for chaining. - */ - public Builder setWorkerPoolBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - workerPool_ = value; - onChanged(); - return this; - } - - private com.google.protobuf.Timestamp createTime_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - createTimeBuilder_; - /** - * - * - *
-     * Time the operation was created.
-     * 
- * - * .google.protobuf.Timestamp create_time = 2; - * - * @return Whether the createTime field is set. - */ - public boolean hasCreateTime() { - return createTimeBuilder_ != null || createTime_ != null; - } - /** - * - * - *
-     * Time the operation was created.
-     * 
- * - * .google.protobuf.Timestamp create_time = 2; - * - * @return The createTime. - */ - public com.google.protobuf.Timestamp getCreateTime() { - if (createTimeBuilder_ == null) { - return createTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : createTime_; - } else { - return createTimeBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Time the operation was created.
-     * 
- * - * .google.protobuf.Timestamp create_time = 2; - */ - public Builder setCreateTime(com.google.protobuf.Timestamp value) { - if (createTimeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - createTime_ = value; - onChanged(); - } else { - createTimeBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * Time the operation was created.
-     * 
- * - * .google.protobuf.Timestamp create_time = 2; - */ - public Builder setCreateTime(com.google.protobuf.Timestamp.Builder builderForValue) { - if (createTimeBuilder_ == null) { - createTime_ = builderForValue.build(); - onChanged(); - } else { - createTimeBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Time the operation was created.
-     * 
- * - * .google.protobuf.Timestamp create_time = 2; - */ - public Builder mergeCreateTime(com.google.protobuf.Timestamp value) { - if (createTimeBuilder_ == null) { - if (createTime_ != null) { - createTime_ = - com.google.protobuf.Timestamp.newBuilder(createTime_).mergeFrom(value).buildPartial(); - } else { - createTime_ = value; - } - onChanged(); - } else { - createTimeBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * Time the operation was created.
-     * 
- * - * .google.protobuf.Timestamp create_time = 2; - */ - public Builder clearCreateTime() { - if (createTimeBuilder_ == null) { - createTime_ = null; - onChanged(); - } else { - createTime_ = null; - createTimeBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Time the operation was created.
-     * 
- * - * .google.protobuf.Timestamp create_time = 2; - */ - public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder() { - - onChanged(); - return getCreateTimeFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Time the operation was created.
-     * 
- * - * .google.protobuf.Timestamp create_time = 2; - */ - public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { - if (createTimeBuilder_ != null) { - return createTimeBuilder_.getMessageOrBuilder(); - } else { - return createTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : createTime_; - } - } - /** - * - * - *
-     * Time the operation was created.
-     * 
- * - * .google.protobuf.Timestamp create_time = 2; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - getCreateTimeFieldBuilder() { - if (createTimeBuilder_ == null) { - createTimeBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder>( - getCreateTime(), getParentForChildren(), isClean()); - createTime_ = null; - } - return createTimeBuilder_; - } - - private com.google.protobuf.Timestamp completeTime_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - completeTimeBuilder_; - /** - * - * - *
-     * Time the operation was completed.
-     * 
- * - * .google.protobuf.Timestamp complete_time = 3; - * - * @return Whether the completeTime field is set. - */ - public boolean hasCompleteTime() { - return completeTimeBuilder_ != null || completeTime_ != null; - } - /** - * - * - *
-     * Time the operation was completed.
-     * 
- * - * .google.protobuf.Timestamp complete_time = 3; - * - * @return The completeTime. - */ - public com.google.protobuf.Timestamp getCompleteTime() { - if (completeTimeBuilder_ == null) { - return completeTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : completeTime_; - } else { - return completeTimeBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Time the operation was completed.
-     * 
- * - * .google.protobuf.Timestamp complete_time = 3; - */ - public Builder setCompleteTime(com.google.protobuf.Timestamp value) { - if (completeTimeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - completeTime_ = value; - onChanged(); - } else { - completeTimeBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * Time the operation was completed.
-     * 
- * - * .google.protobuf.Timestamp complete_time = 3; - */ - public Builder setCompleteTime(com.google.protobuf.Timestamp.Builder builderForValue) { - if (completeTimeBuilder_ == null) { - completeTime_ = builderForValue.build(); - onChanged(); - } else { - completeTimeBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Time the operation was completed.
-     * 
- * - * .google.protobuf.Timestamp complete_time = 3; - */ - public Builder mergeCompleteTime(com.google.protobuf.Timestamp value) { - if (completeTimeBuilder_ == null) { - if (completeTime_ != null) { - completeTime_ = - com.google.protobuf.Timestamp.newBuilder(completeTime_) - .mergeFrom(value) - .buildPartial(); - } else { - completeTime_ = value; - } - onChanged(); - } else { - completeTimeBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * Time the operation was completed.
-     * 
- * - * .google.protobuf.Timestamp complete_time = 3; - */ - public Builder clearCompleteTime() { - if (completeTimeBuilder_ == null) { - completeTime_ = null; - onChanged(); - } else { - completeTime_ = null; - completeTimeBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Time the operation was completed.
-     * 
- * - * .google.protobuf.Timestamp complete_time = 3; - */ - public com.google.protobuf.Timestamp.Builder getCompleteTimeBuilder() { - - onChanged(); - return getCompleteTimeFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Time the operation was completed.
-     * 
- * - * .google.protobuf.Timestamp complete_time = 3; - */ - public com.google.protobuf.TimestampOrBuilder getCompleteTimeOrBuilder() { - if (completeTimeBuilder_ != null) { - return completeTimeBuilder_.getMessageOrBuilder(); - } else { - return completeTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : completeTime_; - } - } - /** - * - * - *
-     * Time the operation was completed.
-     * 
- * - * .google.protobuf.Timestamp complete_time = 3; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - getCompleteTimeFieldBuilder() { - if (completeTimeBuilder_ == null) { - completeTimeBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder>( - getCompleteTime(), getParentForChildren(), isClean()); - completeTime_ = null; - } - return completeTimeBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.DeleteWorkerPoolOperationMetadata) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.DeleteWorkerPoolOperationMetadata) - private static final com.google.cloudbuild.v1.DeleteWorkerPoolOperationMetadata DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.DeleteWorkerPoolOperationMetadata(); - } - - public static com.google.cloudbuild.v1.DeleteWorkerPoolOperationMetadata getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public DeleteWorkerPoolOperationMetadata parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.DeleteWorkerPoolOperationMetadata getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/DeleteWorkerPoolOperationMetadataOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/DeleteWorkerPoolOperationMetadataOrBuilder.java deleted file mode 100644 index f4842ae4..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/DeleteWorkerPoolOperationMetadataOrBuilder.java +++ /dev/null @@ -1,124 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface DeleteWorkerPoolOperationMetadataOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.DeleteWorkerPoolOperationMetadata) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The resource name of the `WorkerPool` being deleted.
-   * Format:
-   * `projects/{project}/locations/{location}/workerPools/{worker_pool}`.
-   * 
- * - * string worker_pool = 1 [(.google.api.resource_reference) = { ... } - * - * @return The workerPool. - */ - java.lang.String getWorkerPool(); - /** - * - * - *
-   * The resource name of the `WorkerPool` being deleted.
-   * Format:
-   * `projects/{project}/locations/{location}/workerPools/{worker_pool}`.
-   * 
- * - * string worker_pool = 1 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for workerPool. - */ - com.google.protobuf.ByteString getWorkerPoolBytes(); - - /** - * - * - *
-   * Time the operation was created.
-   * 
- * - * .google.protobuf.Timestamp create_time = 2; - * - * @return Whether the createTime field is set. - */ - boolean hasCreateTime(); - /** - * - * - *
-   * Time the operation was created.
-   * 
- * - * .google.protobuf.Timestamp create_time = 2; - * - * @return The createTime. - */ - com.google.protobuf.Timestamp getCreateTime(); - /** - * - * - *
-   * Time the operation was created.
-   * 
- * - * .google.protobuf.Timestamp create_time = 2; - */ - com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder(); - - /** - * - * - *
-   * Time the operation was completed.
-   * 
- * - * .google.protobuf.Timestamp complete_time = 3; - * - * @return Whether the completeTime field is set. - */ - boolean hasCompleteTime(); - /** - * - * - *
-   * Time the operation was completed.
-   * 
- * - * .google.protobuf.Timestamp complete_time = 3; - * - * @return The completeTime. - */ - com.google.protobuf.Timestamp getCompleteTime(); - /** - * - * - *
-   * Time the operation was completed.
-   * 
- * - * .google.protobuf.Timestamp complete_time = 3; - */ - com.google.protobuf.TimestampOrBuilder getCompleteTimeOrBuilder(); -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/DeleteWorkerPoolRequest.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/DeleteWorkerPoolRequest.java deleted file mode 100644 index 23e433f9..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/DeleteWorkerPoolRequest.java +++ /dev/null @@ -1,1018 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * Request to delete a `WorkerPool`.
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.DeleteWorkerPoolRequest} - */ -public final class DeleteWorkerPoolRequest extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.DeleteWorkerPoolRequest) - DeleteWorkerPoolRequestOrBuilder { - private static final long serialVersionUID = 0L; - // Use DeleteWorkerPoolRequest.newBuilder() to construct. - private DeleteWorkerPoolRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private DeleteWorkerPoolRequest() { - name_ = ""; - etag_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new DeleteWorkerPoolRequest(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_DeleteWorkerPoolRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_DeleteWorkerPoolRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.DeleteWorkerPoolRequest.class, - com.google.cloudbuild.v1.DeleteWorkerPoolRequest.Builder.class); - } - - public static final int NAME_FIELD_NUMBER = 1; - private volatile java.lang.Object name_; - /** - * - * - *
-   * Required. The name of the `WorkerPool` to delete.
-   * Format:
-   * `projects/{project}/locations/{workerPool}/workerPools/{workerPool}`.
-   * 
- * - * - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return The name. - */ - @java.lang.Override - public java.lang.String getName() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - name_ = s; - return s; - } - } - /** - * - * - *
-   * Required. The name of the `WorkerPool` to delete.
-   * Format:
-   * `projects/{project}/locations/{workerPool}/workerPools/{workerPool}`.
-   * 
- * - * - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return The bytes for name. - */ - @java.lang.Override - public com.google.protobuf.ByteString getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int ETAG_FIELD_NUMBER = 2; - private volatile java.lang.Object etag_; - /** - * - * - *
-   * Optional. If this is provided, it must match the server's etag on the
-   * workerpool for the request to be processed.
-   * 
- * - * string etag = 2; - * - * @return The etag. - */ - @java.lang.Override - public java.lang.String getEtag() { - java.lang.Object ref = etag_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - etag_ = s; - return s; - } - } - /** - * - * - *
-   * Optional. If this is provided, it must match the server's etag on the
-   * workerpool for the request to be processed.
-   * 
- * - * string etag = 2; - * - * @return The bytes for etag. - */ - @java.lang.Override - public com.google.protobuf.ByteString getEtagBytes() { - java.lang.Object ref = etag_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - etag_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int ALLOW_MISSING_FIELD_NUMBER = 3; - private boolean allowMissing_; - /** - * - * - *
-   * If set to true, and the `WorkerPool` is not found, the request will succeed
-   * but no action will be taken on the server.
-   * 
- * - * bool allow_missing = 3; - * - * @return The allowMissing. - */ - @java.lang.Override - public boolean getAllowMissing() { - return allowMissing_; - } - - public static final int VALIDATE_ONLY_FIELD_NUMBER = 4; - private boolean validateOnly_; - /** - * - * - *
-   * If set, validate the request and preview the response, but do not actually
-   * post it.
-   * 
- * - * bool validate_only = 4; - * - * @return The validateOnly. - */ - @java.lang.Override - public boolean getValidateOnly() { - return validateOnly_; - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(etag_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, etag_); - } - if (allowMissing_ != false) { - output.writeBool(3, allowMissing_); - } - if (validateOnly_ != false) { - output.writeBool(4, validateOnly_); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(etag_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, etag_); - } - if (allowMissing_ != false) { - size += com.google.protobuf.CodedOutputStream.computeBoolSize(3, allowMissing_); - } - if (validateOnly_ != false) { - size += com.google.protobuf.CodedOutputStream.computeBoolSize(4, validateOnly_); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.DeleteWorkerPoolRequest)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.DeleteWorkerPoolRequest other = - (com.google.cloudbuild.v1.DeleteWorkerPoolRequest) obj; - - if (!getName().equals(other.getName())) return false; - if (!getEtag().equals(other.getEtag())) return false; - if (getAllowMissing() != other.getAllowMissing()) return false; - if (getValidateOnly() != other.getValidateOnly()) return false; - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + NAME_FIELD_NUMBER; - hash = (53 * hash) + getName().hashCode(); - hash = (37 * hash) + ETAG_FIELD_NUMBER; - hash = (53 * hash) + getEtag().hashCode(); - hash = (37 * hash) + ALLOW_MISSING_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getAllowMissing()); - hash = (37 * hash) + VALIDATE_ONLY_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getValidateOnly()); - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.DeleteWorkerPoolRequest parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.DeleteWorkerPoolRequest parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.DeleteWorkerPoolRequest parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.DeleteWorkerPoolRequest parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.DeleteWorkerPoolRequest parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.DeleteWorkerPoolRequest parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.DeleteWorkerPoolRequest parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.DeleteWorkerPoolRequest parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.DeleteWorkerPoolRequest parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.DeleteWorkerPoolRequest parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.DeleteWorkerPoolRequest parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.DeleteWorkerPoolRequest parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.DeleteWorkerPoolRequest prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * Request to delete a `WorkerPool`.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.DeleteWorkerPoolRequest} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.DeleteWorkerPoolRequest) - com.google.cloudbuild.v1.DeleteWorkerPoolRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_DeleteWorkerPoolRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_DeleteWorkerPoolRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.DeleteWorkerPoolRequest.class, - com.google.cloudbuild.v1.DeleteWorkerPoolRequest.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.DeleteWorkerPoolRequest.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - name_ = ""; - - etag_ = ""; - - allowMissing_ = false; - - validateOnly_ = false; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_DeleteWorkerPoolRequest_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.DeleteWorkerPoolRequest getDefaultInstanceForType() { - return com.google.cloudbuild.v1.DeleteWorkerPoolRequest.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.DeleteWorkerPoolRequest build() { - com.google.cloudbuild.v1.DeleteWorkerPoolRequest result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.DeleteWorkerPoolRequest buildPartial() { - com.google.cloudbuild.v1.DeleteWorkerPoolRequest result = - new com.google.cloudbuild.v1.DeleteWorkerPoolRequest(this); - result.name_ = name_; - result.etag_ = etag_; - result.allowMissing_ = allowMissing_; - result.validateOnly_ = validateOnly_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.DeleteWorkerPoolRequest) { - return mergeFrom((com.google.cloudbuild.v1.DeleteWorkerPoolRequest) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.DeleteWorkerPoolRequest other) { - if (other == com.google.cloudbuild.v1.DeleteWorkerPoolRequest.getDefaultInstance()) - return this; - if (!other.getName().isEmpty()) { - name_ = other.name_; - onChanged(); - } - if (!other.getEtag().isEmpty()) { - etag_ = other.etag_; - onChanged(); - } - if (other.getAllowMissing() != false) { - setAllowMissing(other.getAllowMissing()); - } - if (other.getValidateOnly() != false) { - setValidateOnly(other.getValidateOnly()); - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - name_ = input.readStringRequireUtf8(); - - break; - } // case 10 - case 18: - { - etag_ = input.readStringRequireUtf8(); - - break; - } // case 18 - case 24: - { - allowMissing_ = input.readBool(); - - break; - } // case 24 - case 32: - { - validateOnly_ = input.readBool(); - - break; - } // case 32 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private java.lang.Object name_ = ""; - /** - * - * - *
-     * Required. The name of the `WorkerPool` to delete.
-     * Format:
-     * `projects/{project}/locations/{workerPool}/workerPools/{workerPool}`.
-     * 
- * - * - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return The name. - */ - public java.lang.String getName() { - java.lang.Object ref = name_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - name_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Required. The name of the `WorkerPool` to delete.
-     * Format:
-     * `projects/{project}/locations/{workerPool}/workerPools/{workerPool}`.
-     * 
- * - * - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return The bytes for name. - */ - public com.google.protobuf.ByteString getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Required. The name of the `WorkerPool` to delete.
-     * Format:
-     * `projects/{project}/locations/{workerPool}/workerPools/{workerPool}`.
-     * 
- * - * - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @param value The name to set. - * @return This builder for chaining. - */ - public Builder setName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - name_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Required. The name of the `WorkerPool` to delete.
-     * Format:
-     * `projects/{project}/locations/{workerPool}/workerPools/{workerPool}`.
-     * 
- * - * - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return This builder for chaining. - */ - public Builder clearName() { - - name_ = getDefaultInstance().getName(); - onChanged(); - return this; - } - /** - * - * - *
-     * Required. The name of the `WorkerPool` to delete.
-     * Format:
-     * `projects/{project}/locations/{workerPool}/workerPools/{workerPool}`.
-     * 
- * - * - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @param value The bytes for name to set. - * @return This builder for chaining. - */ - public Builder setNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - name_ = value; - onChanged(); - return this; - } - - private java.lang.Object etag_ = ""; - /** - * - * - *
-     * Optional. If this is provided, it must match the server's etag on the
-     * workerpool for the request to be processed.
-     * 
- * - * string etag = 2; - * - * @return The etag. - */ - public java.lang.String getEtag() { - java.lang.Object ref = etag_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - etag_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Optional. If this is provided, it must match the server's etag on the
-     * workerpool for the request to be processed.
-     * 
- * - * string etag = 2; - * - * @return The bytes for etag. - */ - public com.google.protobuf.ByteString getEtagBytes() { - java.lang.Object ref = etag_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - etag_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Optional. If this is provided, it must match the server's etag on the
-     * workerpool for the request to be processed.
-     * 
- * - * string etag = 2; - * - * @param value The etag to set. - * @return This builder for chaining. - */ - public Builder setEtag(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - etag_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Optional. If this is provided, it must match the server's etag on the
-     * workerpool for the request to be processed.
-     * 
- * - * string etag = 2; - * - * @return This builder for chaining. - */ - public Builder clearEtag() { - - etag_ = getDefaultInstance().getEtag(); - onChanged(); - return this; - } - /** - * - * - *
-     * Optional. If this is provided, it must match the server's etag on the
-     * workerpool for the request to be processed.
-     * 
- * - * string etag = 2; - * - * @param value The bytes for etag to set. - * @return This builder for chaining. - */ - public Builder setEtagBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - etag_ = value; - onChanged(); - return this; - } - - private boolean allowMissing_; - /** - * - * - *
-     * If set to true, and the `WorkerPool` is not found, the request will succeed
-     * but no action will be taken on the server.
-     * 
- * - * bool allow_missing = 3; - * - * @return The allowMissing. - */ - @java.lang.Override - public boolean getAllowMissing() { - return allowMissing_; - } - /** - * - * - *
-     * If set to true, and the `WorkerPool` is not found, the request will succeed
-     * but no action will be taken on the server.
-     * 
- * - * bool allow_missing = 3; - * - * @param value The allowMissing to set. - * @return This builder for chaining. - */ - public Builder setAllowMissing(boolean value) { - - allowMissing_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * If set to true, and the `WorkerPool` is not found, the request will succeed
-     * but no action will be taken on the server.
-     * 
- * - * bool allow_missing = 3; - * - * @return This builder for chaining. - */ - public Builder clearAllowMissing() { - - allowMissing_ = false; - onChanged(); - return this; - } - - private boolean validateOnly_; - /** - * - * - *
-     * If set, validate the request and preview the response, but do not actually
-     * post it.
-     * 
- * - * bool validate_only = 4; - * - * @return The validateOnly. - */ - @java.lang.Override - public boolean getValidateOnly() { - return validateOnly_; - } - /** - * - * - *
-     * If set, validate the request and preview the response, but do not actually
-     * post it.
-     * 
- * - * bool validate_only = 4; - * - * @param value The validateOnly to set. - * @return This builder for chaining. - */ - public Builder setValidateOnly(boolean value) { - - validateOnly_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * If set, validate the request and preview the response, but do not actually
-     * post it.
-     * 
- * - * bool validate_only = 4; - * - * @return This builder for chaining. - */ - public Builder clearValidateOnly() { - - validateOnly_ = false; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.DeleteWorkerPoolRequest) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.DeleteWorkerPoolRequest) - private static final com.google.cloudbuild.v1.DeleteWorkerPoolRequest DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.DeleteWorkerPoolRequest(); - } - - public static com.google.cloudbuild.v1.DeleteWorkerPoolRequest getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public DeleteWorkerPoolRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.DeleteWorkerPoolRequest getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/DeleteWorkerPoolRequestOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/DeleteWorkerPoolRequestOrBuilder.java deleted file mode 100644 index 16d76694..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/DeleteWorkerPoolRequestOrBuilder.java +++ /dev/null @@ -1,113 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface DeleteWorkerPoolRequestOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.DeleteWorkerPoolRequest) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * Required. The name of the `WorkerPool` to delete.
-   * Format:
-   * `projects/{project}/locations/{workerPool}/workerPools/{workerPool}`.
-   * 
- * - * - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return The name. - */ - java.lang.String getName(); - /** - * - * - *
-   * Required. The name of the `WorkerPool` to delete.
-   * Format:
-   * `projects/{project}/locations/{workerPool}/workerPools/{workerPool}`.
-   * 
- * - * - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return The bytes for name. - */ - com.google.protobuf.ByteString getNameBytes(); - - /** - * - * - *
-   * Optional. If this is provided, it must match the server's etag on the
-   * workerpool for the request to be processed.
-   * 
- * - * string etag = 2; - * - * @return The etag. - */ - java.lang.String getEtag(); - /** - * - * - *
-   * Optional. If this is provided, it must match the server's etag on the
-   * workerpool for the request to be processed.
-   * 
- * - * string etag = 2; - * - * @return The bytes for etag. - */ - com.google.protobuf.ByteString getEtagBytes(); - - /** - * - * - *
-   * If set to true, and the `WorkerPool` is not found, the request will succeed
-   * but no action will be taken on the server.
-   * 
- * - * bool allow_missing = 3; - * - * @return The allowMissing. - */ - boolean getAllowMissing(); - - /** - * - * - *
-   * If set, validate the request and preview the response, but do not actually
-   * post it.
-   * 
- * - * bool validate_only = 4; - * - * @return The validateOnly. - */ - boolean getValidateOnly(); -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/FileHashes.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/FileHashes.java deleted file mode 100644 index 4955822c..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/FileHashes.java +++ /dev/null @@ -1,920 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * Container message for hashes of byte content of files, used in
- * SourceProvenance messages to verify integrity of source input to the build.
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.FileHashes} - */ -public final class FileHashes extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.FileHashes) - FileHashesOrBuilder { - private static final long serialVersionUID = 0L; - // Use FileHashes.newBuilder() to construct. - private FileHashes(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private FileHashes() { - fileHash_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new FileHashes(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_FileHashes_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_FileHashes_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.FileHashes.class, - com.google.cloudbuild.v1.FileHashes.Builder.class); - } - - public static final int FILE_HASH_FIELD_NUMBER = 1; - private java.util.List fileHash_; - /** - * - * - *
-   * Collection of file hashes.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Hash file_hash = 1; - */ - @java.lang.Override - public java.util.List getFileHashList() { - return fileHash_; - } - /** - * - * - *
-   * Collection of file hashes.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Hash file_hash = 1; - */ - @java.lang.Override - public java.util.List - getFileHashOrBuilderList() { - return fileHash_; - } - /** - * - * - *
-   * Collection of file hashes.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Hash file_hash = 1; - */ - @java.lang.Override - public int getFileHashCount() { - return fileHash_.size(); - } - /** - * - * - *
-   * Collection of file hashes.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Hash file_hash = 1; - */ - @java.lang.Override - public com.google.cloudbuild.v1.Hash getFileHash(int index) { - return fileHash_.get(index); - } - /** - * - * - *
-   * Collection of file hashes.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Hash file_hash = 1; - */ - @java.lang.Override - public com.google.cloudbuild.v1.HashOrBuilder getFileHashOrBuilder(int index) { - return fileHash_.get(index); - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - for (int i = 0; i < fileHash_.size(); i++) { - output.writeMessage(1, fileHash_.get(i)); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - for (int i = 0; i < fileHash_.size(); i++) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, fileHash_.get(i)); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.FileHashes)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.FileHashes other = (com.google.cloudbuild.v1.FileHashes) obj; - - if (!getFileHashList().equals(other.getFileHashList())) return false; - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (getFileHashCount() > 0) { - hash = (37 * hash) + FILE_HASH_FIELD_NUMBER; - hash = (53 * hash) + getFileHashList().hashCode(); - } - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.FileHashes parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.FileHashes parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.FileHashes parseFrom(com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.FileHashes parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.FileHashes parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.FileHashes parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.FileHashes parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.FileHashes parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.FileHashes parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.FileHashes parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.FileHashes parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.FileHashes parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.FileHashes prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * Container message for hashes of byte content of files, used in
-   * SourceProvenance messages to verify integrity of source input to the build.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.FileHashes} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.FileHashes) - com.google.cloudbuild.v1.FileHashesOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_FileHashes_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_FileHashes_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.FileHashes.class, - com.google.cloudbuild.v1.FileHashes.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.FileHashes.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - if (fileHashBuilder_ == null) { - fileHash_ = java.util.Collections.emptyList(); - } else { - fileHash_ = null; - fileHashBuilder_.clear(); - } - bitField0_ = (bitField0_ & ~0x00000001); - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_FileHashes_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.FileHashes getDefaultInstanceForType() { - return com.google.cloudbuild.v1.FileHashes.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.FileHashes build() { - com.google.cloudbuild.v1.FileHashes result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.FileHashes buildPartial() { - com.google.cloudbuild.v1.FileHashes result = new com.google.cloudbuild.v1.FileHashes(this); - int from_bitField0_ = bitField0_; - if (fileHashBuilder_ == null) { - if (((bitField0_ & 0x00000001) != 0)) { - fileHash_ = java.util.Collections.unmodifiableList(fileHash_); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.fileHash_ = fileHash_; - } else { - result.fileHash_ = fileHashBuilder_.build(); - } - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.FileHashes) { - return mergeFrom((com.google.cloudbuild.v1.FileHashes) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.FileHashes other) { - if (other == com.google.cloudbuild.v1.FileHashes.getDefaultInstance()) return this; - if (fileHashBuilder_ == null) { - if (!other.fileHash_.isEmpty()) { - if (fileHash_.isEmpty()) { - fileHash_ = other.fileHash_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureFileHashIsMutable(); - fileHash_.addAll(other.fileHash_); - } - onChanged(); - } - } else { - if (!other.fileHash_.isEmpty()) { - if (fileHashBuilder_.isEmpty()) { - fileHashBuilder_.dispose(); - fileHashBuilder_ = null; - fileHash_ = other.fileHash_; - bitField0_ = (bitField0_ & ~0x00000001); - fileHashBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders - ? getFileHashFieldBuilder() - : null; - } else { - fileHashBuilder_.addAllMessages(other.fileHash_); - } - } - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - com.google.cloudbuild.v1.Hash m = - input.readMessage(com.google.cloudbuild.v1.Hash.parser(), extensionRegistry); - if (fileHashBuilder_ == null) { - ensureFileHashIsMutable(); - fileHash_.add(m); - } else { - fileHashBuilder_.addMessage(m); - } - break; - } // case 10 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private int bitField0_; - - private java.util.List fileHash_ = - java.util.Collections.emptyList(); - - private void ensureFileHashIsMutable() { - if (!((bitField0_ & 0x00000001) != 0)) { - fileHash_ = new java.util.ArrayList(fileHash_); - bitField0_ |= 0x00000001; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloudbuild.v1.Hash, - com.google.cloudbuild.v1.Hash.Builder, - com.google.cloudbuild.v1.HashOrBuilder> - fileHashBuilder_; - - /** - * - * - *
-     * Collection of file hashes.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Hash file_hash = 1; - */ - public java.util.List getFileHashList() { - if (fileHashBuilder_ == null) { - return java.util.Collections.unmodifiableList(fileHash_); - } else { - return fileHashBuilder_.getMessageList(); - } - } - /** - * - * - *
-     * Collection of file hashes.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Hash file_hash = 1; - */ - public int getFileHashCount() { - if (fileHashBuilder_ == null) { - return fileHash_.size(); - } else { - return fileHashBuilder_.getCount(); - } - } - /** - * - * - *
-     * Collection of file hashes.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Hash file_hash = 1; - */ - public com.google.cloudbuild.v1.Hash getFileHash(int index) { - if (fileHashBuilder_ == null) { - return fileHash_.get(index); - } else { - return fileHashBuilder_.getMessage(index); - } - } - /** - * - * - *
-     * Collection of file hashes.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Hash file_hash = 1; - */ - public Builder setFileHash(int index, com.google.cloudbuild.v1.Hash value) { - if (fileHashBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureFileHashIsMutable(); - fileHash_.set(index, value); - onChanged(); - } else { - fileHashBuilder_.setMessage(index, value); - } - return this; - } - /** - * - * - *
-     * Collection of file hashes.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Hash file_hash = 1; - */ - public Builder setFileHash(int index, com.google.cloudbuild.v1.Hash.Builder builderForValue) { - if (fileHashBuilder_ == null) { - ensureFileHashIsMutable(); - fileHash_.set(index, builderForValue.build()); - onChanged(); - } else { - fileHashBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * Collection of file hashes.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Hash file_hash = 1; - */ - public Builder addFileHash(com.google.cloudbuild.v1.Hash value) { - if (fileHashBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureFileHashIsMutable(); - fileHash_.add(value); - onChanged(); - } else { - fileHashBuilder_.addMessage(value); - } - return this; - } - /** - * - * - *
-     * Collection of file hashes.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Hash file_hash = 1; - */ - public Builder addFileHash(int index, com.google.cloudbuild.v1.Hash value) { - if (fileHashBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureFileHashIsMutable(); - fileHash_.add(index, value); - onChanged(); - } else { - fileHashBuilder_.addMessage(index, value); - } - return this; - } - /** - * - * - *
-     * Collection of file hashes.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Hash file_hash = 1; - */ - public Builder addFileHash(com.google.cloudbuild.v1.Hash.Builder builderForValue) { - if (fileHashBuilder_ == null) { - ensureFileHashIsMutable(); - fileHash_.add(builderForValue.build()); - onChanged(); - } else { - fileHashBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * Collection of file hashes.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Hash file_hash = 1; - */ - public Builder addFileHash(int index, com.google.cloudbuild.v1.Hash.Builder builderForValue) { - if (fileHashBuilder_ == null) { - ensureFileHashIsMutable(); - fileHash_.add(index, builderForValue.build()); - onChanged(); - } else { - fileHashBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * Collection of file hashes.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Hash file_hash = 1; - */ - public Builder addAllFileHash( - java.lang.Iterable values) { - if (fileHashBuilder_ == null) { - ensureFileHashIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, fileHash_); - onChanged(); - } else { - fileHashBuilder_.addAllMessages(values); - } - return this; - } - /** - * - * - *
-     * Collection of file hashes.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Hash file_hash = 1; - */ - public Builder clearFileHash() { - if (fileHashBuilder_ == null) { - fileHash_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - } else { - fileHashBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * Collection of file hashes.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Hash file_hash = 1; - */ - public Builder removeFileHash(int index) { - if (fileHashBuilder_ == null) { - ensureFileHashIsMutable(); - fileHash_.remove(index); - onChanged(); - } else { - fileHashBuilder_.remove(index); - } - return this; - } - /** - * - * - *
-     * Collection of file hashes.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Hash file_hash = 1; - */ - public com.google.cloudbuild.v1.Hash.Builder getFileHashBuilder(int index) { - return getFileHashFieldBuilder().getBuilder(index); - } - /** - * - * - *
-     * Collection of file hashes.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Hash file_hash = 1; - */ - public com.google.cloudbuild.v1.HashOrBuilder getFileHashOrBuilder(int index) { - if (fileHashBuilder_ == null) { - return fileHash_.get(index); - } else { - return fileHashBuilder_.getMessageOrBuilder(index); - } - } - /** - * - * - *
-     * Collection of file hashes.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Hash file_hash = 1; - */ - public java.util.List - getFileHashOrBuilderList() { - if (fileHashBuilder_ != null) { - return fileHashBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(fileHash_); - } - } - /** - * - * - *
-     * Collection of file hashes.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Hash file_hash = 1; - */ - public com.google.cloudbuild.v1.Hash.Builder addFileHashBuilder() { - return getFileHashFieldBuilder() - .addBuilder(com.google.cloudbuild.v1.Hash.getDefaultInstance()); - } - /** - * - * - *
-     * Collection of file hashes.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Hash file_hash = 1; - */ - public com.google.cloudbuild.v1.Hash.Builder addFileHashBuilder(int index) { - return getFileHashFieldBuilder() - .addBuilder(index, com.google.cloudbuild.v1.Hash.getDefaultInstance()); - } - /** - * - * - *
-     * Collection of file hashes.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Hash file_hash = 1; - */ - public java.util.List getFileHashBuilderList() { - return getFileHashFieldBuilder().getBuilderList(); - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloudbuild.v1.Hash, - com.google.cloudbuild.v1.Hash.Builder, - com.google.cloudbuild.v1.HashOrBuilder> - getFileHashFieldBuilder() { - if (fileHashBuilder_ == null) { - fileHashBuilder_ = - new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloudbuild.v1.Hash, - com.google.cloudbuild.v1.Hash.Builder, - com.google.cloudbuild.v1.HashOrBuilder>( - fileHash_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); - fileHash_ = null; - } - return fileHashBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.FileHashes) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.FileHashes) - private static final com.google.cloudbuild.v1.FileHashes DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.FileHashes(); - } - - public static com.google.cloudbuild.v1.FileHashes getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public FileHashes parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.FileHashes getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/FileHashesOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/FileHashesOrBuilder.java deleted file mode 100644 index a0f1de56..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/FileHashesOrBuilder.java +++ /dev/null @@ -1,76 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface FileHashesOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.FileHashes) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * Collection of file hashes.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Hash file_hash = 1; - */ - java.util.List getFileHashList(); - /** - * - * - *
-   * Collection of file hashes.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Hash file_hash = 1; - */ - com.google.cloudbuild.v1.Hash getFileHash(int index); - /** - * - * - *
-   * Collection of file hashes.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Hash file_hash = 1; - */ - int getFileHashCount(); - /** - * - * - *
-   * Collection of file hashes.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Hash file_hash = 1; - */ - java.util.List getFileHashOrBuilderList(); - /** - * - * - *
-   * Collection of file hashes.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Hash file_hash = 1; - */ - com.google.cloudbuild.v1.HashOrBuilder getFileHashOrBuilder(int index); -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GetBuildRequest.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GetBuildRequest.java deleted file mode 100644 index 21469ddb..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GetBuildRequest.java +++ /dev/null @@ -1,976 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * Request to get a build.
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.GetBuildRequest} - */ -public final class GetBuildRequest extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.GetBuildRequest) - GetBuildRequestOrBuilder { - private static final long serialVersionUID = 0L; - // Use GetBuildRequest.newBuilder() to construct. - private GetBuildRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private GetBuildRequest() { - name_ = ""; - projectId_ = ""; - id_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new GetBuildRequest(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_GetBuildRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_GetBuildRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.GetBuildRequest.class, - com.google.cloudbuild.v1.GetBuildRequest.Builder.class); - } - - public static final int NAME_FIELD_NUMBER = 4; - private volatile java.lang.Object name_; - /** - * - * - *
-   * The name of the `Build` to retrieve.
-   * Format: `projects/{project}/locations/{location}/builds/{build}`
-   * 
- * - * string name = 4 [(.google.api.resource_reference) = { ... } - * - * @return The name. - */ - @java.lang.Override - public java.lang.String getName() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - name_ = s; - return s; - } - } - /** - * - * - *
-   * The name of the `Build` to retrieve.
-   * Format: `projects/{project}/locations/{location}/builds/{build}`
-   * 
- * - * string name = 4 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for name. - */ - @java.lang.Override - public com.google.protobuf.ByteString getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int PROJECT_ID_FIELD_NUMBER = 1; - private volatile java.lang.Object projectId_; - /** - * - * - *
-   * Required. ID of the project.
-   * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The projectId. - */ - @java.lang.Override - public java.lang.String getProjectId() { - java.lang.Object ref = projectId_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - projectId_ = s; - return s; - } - } - /** - * - * - *
-   * Required. ID of the project.
-   * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for projectId. - */ - @java.lang.Override - public com.google.protobuf.ByteString getProjectIdBytes() { - java.lang.Object ref = projectId_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - projectId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int ID_FIELD_NUMBER = 2; - private volatile java.lang.Object id_; - /** - * - * - *
-   * Required. ID of the build.
-   * 
- * - * string id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The id. - */ - @java.lang.Override - public java.lang.String getId() { - java.lang.Object ref = id_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - id_ = s; - return s; - } - } - /** - * - * - *
-   * Required. ID of the build.
-   * 
- * - * string id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for id. - */ - @java.lang.Override - public com.google.protobuf.ByteString getIdBytes() { - java.lang.Object ref = id_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - id_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(projectId_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, projectId_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(id_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, id_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 4, name_); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(projectId_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, projectId_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(id_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, id_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, name_); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.GetBuildRequest)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.GetBuildRequest other = (com.google.cloudbuild.v1.GetBuildRequest) obj; - - if (!getName().equals(other.getName())) return false; - if (!getProjectId().equals(other.getProjectId())) return false; - if (!getId().equals(other.getId())) return false; - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + NAME_FIELD_NUMBER; - hash = (53 * hash) + getName().hashCode(); - hash = (37 * hash) + PROJECT_ID_FIELD_NUMBER; - hash = (53 * hash) + getProjectId().hashCode(); - hash = (37 * hash) + ID_FIELD_NUMBER; - hash = (53 * hash) + getId().hashCode(); - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.GetBuildRequest parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.GetBuildRequest parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.GetBuildRequest parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.GetBuildRequest parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.GetBuildRequest parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.GetBuildRequest parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.GetBuildRequest parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.GetBuildRequest parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.GetBuildRequest parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.GetBuildRequest parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.GetBuildRequest parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.GetBuildRequest parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.GetBuildRequest prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * Request to get a build.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.GetBuildRequest} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.GetBuildRequest) - com.google.cloudbuild.v1.GetBuildRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_GetBuildRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_GetBuildRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.GetBuildRequest.class, - com.google.cloudbuild.v1.GetBuildRequest.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.GetBuildRequest.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - name_ = ""; - - projectId_ = ""; - - id_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_GetBuildRequest_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.GetBuildRequest getDefaultInstanceForType() { - return com.google.cloudbuild.v1.GetBuildRequest.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.GetBuildRequest build() { - com.google.cloudbuild.v1.GetBuildRequest result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.GetBuildRequest buildPartial() { - com.google.cloudbuild.v1.GetBuildRequest result = - new com.google.cloudbuild.v1.GetBuildRequest(this); - result.name_ = name_; - result.projectId_ = projectId_; - result.id_ = id_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.GetBuildRequest) { - return mergeFrom((com.google.cloudbuild.v1.GetBuildRequest) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.GetBuildRequest other) { - if (other == com.google.cloudbuild.v1.GetBuildRequest.getDefaultInstance()) return this; - if (!other.getName().isEmpty()) { - name_ = other.name_; - onChanged(); - } - if (!other.getProjectId().isEmpty()) { - projectId_ = other.projectId_; - onChanged(); - } - if (!other.getId().isEmpty()) { - id_ = other.id_; - onChanged(); - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - projectId_ = input.readStringRequireUtf8(); - - break; - } // case 10 - case 18: - { - id_ = input.readStringRequireUtf8(); - - break; - } // case 18 - case 34: - { - name_ = input.readStringRequireUtf8(); - - break; - } // case 34 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private java.lang.Object name_ = ""; - /** - * - * - *
-     * The name of the `Build` to retrieve.
-     * Format: `projects/{project}/locations/{location}/builds/{build}`
-     * 
- * - * string name = 4 [(.google.api.resource_reference) = { ... } - * - * @return The name. - */ - public java.lang.String getName() { - java.lang.Object ref = name_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - name_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * The name of the `Build` to retrieve.
-     * Format: `projects/{project}/locations/{location}/builds/{build}`
-     * 
- * - * string name = 4 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for name. - */ - public com.google.protobuf.ByteString getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * The name of the `Build` to retrieve.
-     * Format: `projects/{project}/locations/{location}/builds/{build}`
-     * 
- * - * string name = 4 [(.google.api.resource_reference) = { ... } - * - * @param value The name to set. - * @return This builder for chaining. - */ - public Builder setName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - name_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the `Build` to retrieve.
-     * Format: `projects/{project}/locations/{location}/builds/{build}`
-     * 
- * - * string name = 4 [(.google.api.resource_reference) = { ... } - * - * @return This builder for chaining. - */ - public Builder clearName() { - - name_ = getDefaultInstance().getName(); - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the `Build` to retrieve.
-     * Format: `projects/{project}/locations/{location}/builds/{build}`
-     * 
- * - * string name = 4 [(.google.api.resource_reference) = { ... } - * - * @param value The bytes for name to set. - * @return This builder for chaining. - */ - public Builder setNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - name_ = value; - onChanged(); - return this; - } - - private java.lang.Object projectId_ = ""; - /** - * - * - *
-     * Required. ID of the project.
-     * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The projectId. - */ - public java.lang.String getProjectId() { - java.lang.Object ref = projectId_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - projectId_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Required. ID of the project.
-     * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for projectId. - */ - public com.google.protobuf.ByteString getProjectIdBytes() { - java.lang.Object ref = projectId_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - projectId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Required. ID of the project.
-     * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @param value The projectId to set. - * @return This builder for chaining. - */ - public Builder setProjectId(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - projectId_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Required. ID of the project.
-     * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return This builder for chaining. - */ - public Builder clearProjectId() { - - projectId_ = getDefaultInstance().getProjectId(); - onChanged(); - return this; - } - /** - * - * - *
-     * Required. ID of the project.
-     * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @param value The bytes for projectId to set. - * @return This builder for chaining. - */ - public Builder setProjectIdBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - projectId_ = value; - onChanged(); - return this; - } - - private java.lang.Object id_ = ""; - /** - * - * - *
-     * Required. ID of the build.
-     * 
- * - * string id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The id. - */ - public java.lang.String getId() { - java.lang.Object ref = id_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - id_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Required. ID of the build.
-     * 
- * - * string id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for id. - */ - public com.google.protobuf.ByteString getIdBytes() { - java.lang.Object ref = id_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - id_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Required. ID of the build.
-     * 
- * - * string id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @param value The id to set. - * @return This builder for chaining. - */ - public Builder setId(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - id_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Required. ID of the build.
-     * 
- * - * string id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @return This builder for chaining. - */ - public Builder clearId() { - - id_ = getDefaultInstance().getId(); - onChanged(); - return this; - } - /** - * - * - *
-     * Required. ID of the build.
-     * 
- * - * string id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @param value The bytes for id to set. - * @return This builder for chaining. - */ - public Builder setIdBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - id_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.GetBuildRequest) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.GetBuildRequest) - private static final com.google.cloudbuild.v1.GetBuildRequest DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.GetBuildRequest(); - } - - public static com.google.cloudbuild.v1.GetBuildRequest getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public GetBuildRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.GetBuildRequest getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GetBuildRequestOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GetBuildRequestOrBuilder.java deleted file mode 100644 index 53a7fcf9..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GetBuildRequestOrBuilder.java +++ /dev/null @@ -1,102 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface GetBuildRequestOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.GetBuildRequest) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The name of the `Build` to retrieve.
-   * Format: `projects/{project}/locations/{location}/builds/{build}`
-   * 
- * - * string name = 4 [(.google.api.resource_reference) = { ... } - * - * @return The name. - */ - java.lang.String getName(); - /** - * - * - *
-   * The name of the `Build` to retrieve.
-   * Format: `projects/{project}/locations/{location}/builds/{build}`
-   * 
- * - * string name = 4 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for name. - */ - com.google.protobuf.ByteString getNameBytes(); - - /** - * - * - *
-   * Required. ID of the project.
-   * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The projectId. - */ - java.lang.String getProjectId(); - /** - * - * - *
-   * Required. ID of the project.
-   * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for projectId. - */ - com.google.protobuf.ByteString getProjectIdBytes(); - - /** - * - * - *
-   * Required. ID of the build.
-   * 
- * - * string id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The id. - */ - java.lang.String getId(); - /** - * - * - *
-   * Required. ID of the build.
-   * 
- * - * string id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for id. - */ - com.google.protobuf.ByteString getIdBytes(); -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GetBuildTriggerRequest.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GetBuildTriggerRequest.java deleted file mode 100644 index 9798f12f..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GetBuildTriggerRequest.java +++ /dev/null @@ -1,978 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * Returns the `BuildTrigger` with the specified ID.
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.GetBuildTriggerRequest} - */ -public final class GetBuildTriggerRequest extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.GetBuildTriggerRequest) - GetBuildTriggerRequestOrBuilder { - private static final long serialVersionUID = 0L; - // Use GetBuildTriggerRequest.newBuilder() to construct. - private GetBuildTriggerRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private GetBuildTriggerRequest() { - name_ = ""; - projectId_ = ""; - triggerId_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new GetBuildTriggerRequest(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_GetBuildTriggerRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_GetBuildTriggerRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.GetBuildTriggerRequest.class, - com.google.cloudbuild.v1.GetBuildTriggerRequest.Builder.class); - } - - public static final int NAME_FIELD_NUMBER = 3; - private volatile java.lang.Object name_; - /** - * - * - *
-   * The name of the `Trigger` to retrieve.
-   * Format: `projects/{project}/locations/{location}/triggers/{trigger}`
-   * 
- * - * string name = 3 [(.google.api.resource_reference) = { ... } - * - * @return The name. - */ - @java.lang.Override - public java.lang.String getName() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - name_ = s; - return s; - } - } - /** - * - * - *
-   * The name of the `Trigger` to retrieve.
-   * Format: `projects/{project}/locations/{location}/triggers/{trigger}`
-   * 
- * - * string name = 3 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for name. - */ - @java.lang.Override - public com.google.protobuf.ByteString getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int PROJECT_ID_FIELD_NUMBER = 1; - private volatile java.lang.Object projectId_; - /** - * - * - *
-   * Required. ID of the project that owns the trigger.
-   * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The projectId. - */ - @java.lang.Override - public java.lang.String getProjectId() { - java.lang.Object ref = projectId_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - projectId_ = s; - return s; - } - } - /** - * - * - *
-   * Required. ID of the project that owns the trigger.
-   * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for projectId. - */ - @java.lang.Override - public com.google.protobuf.ByteString getProjectIdBytes() { - java.lang.Object ref = projectId_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - projectId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int TRIGGER_ID_FIELD_NUMBER = 2; - private volatile java.lang.Object triggerId_; - /** - * - * - *
-   * Required. Identifier (`id` or `name`) of the `BuildTrigger` to get.
-   * 
- * - * string trigger_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The triggerId. - */ - @java.lang.Override - public java.lang.String getTriggerId() { - java.lang.Object ref = triggerId_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - triggerId_ = s; - return s; - } - } - /** - * - * - *
-   * Required. Identifier (`id` or `name`) of the `BuildTrigger` to get.
-   * 
- * - * string trigger_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for triggerId. - */ - @java.lang.Override - public com.google.protobuf.ByteString getTriggerIdBytes() { - java.lang.Object ref = triggerId_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - triggerId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(projectId_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, projectId_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(triggerId_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, triggerId_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 3, name_); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(projectId_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, projectId_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(triggerId_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, triggerId_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, name_); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.GetBuildTriggerRequest)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.GetBuildTriggerRequest other = - (com.google.cloudbuild.v1.GetBuildTriggerRequest) obj; - - if (!getName().equals(other.getName())) return false; - if (!getProjectId().equals(other.getProjectId())) return false; - if (!getTriggerId().equals(other.getTriggerId())) return false; - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + NAME_FIELD_NUMBER; - hash = (53 * hash) + getName().hashCode(); - hash = (37 * hash) + PROJECT_ID_FIELD_NUMBER; - hash = (53 * hash) + getProjectId().hashCode(); - hash = (37 * hash) + TRIGGER_ID_FIELD_NUMBER; - hash = (53 * hash) + getTriggerId().hashCode(); - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.GetBuildTriggerRequest parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.GetBuildTriggerRequest parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.GetBuildTriggerRequest parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.GetBuildTriggerRequest parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.GetBuildTriggerRequest parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.GetBuildTriggerRequest parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.GetBuildTriggerRequest parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.GetBuildTriggerRequest parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.GetBuildTriggerRequest parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.GetBuildTriggerRequest parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.GetBuildTriggerRequest parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.GetBuildTriggerRequest parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.GetBuildTriggerRequest prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * Returns the `BuildTrigger` with the specified ID.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.GetBuildTriggerRequest} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.GetBuildTriggerRequest) - com.google.cloudbuild.v1.GetBuildTriggerRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_GetBuildTriggerRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_GetBuildTriggerRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.GetBuildTriggerRequest.class, - com.google.cloudbuild.v1.GetBuildTriggerRequest.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.GetBuildTriggerRequest.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - name_ = ""; - - projectId_ = ""; - - triggerId_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_GetBuildTriggerRequest_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.GetBuildTriggerRequest getDefaultInstanceForType() { - return com.google.cloudbuild.v1.GetBuildTriggerRequest.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.GetBuildTriggerRequest build() { - com.google.cloudbuild.v1.GetBuildTriggerRequest result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.GetBuildTriggerRequest buildPartial() { - com.google.cloudbuild.v1.GetBuildTriggerRequest result = - new com.google.cloudbuild.v1.GetBuildTriggerRequest(this); - result.name_ = name_; - result.projectId_ = projectId_; - result.triggerId_ = triggerId_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.GetBuildTriggerRequest) { - return mergeFrom((com.google.cloudbuild.v1.GetBuildTriggerRequest) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.GetBuildTriggerRequest other) { - if (other == com.google.cloudbuild.v1.GetBuildTriggerRequest.getDefaultInstance()) - return this; - if (!other.getName().isEmpty()) { - name_ = other.name_; - onChanged(); - } - if (!other.getProjectId().isEmpty()) { - projectId_ = other.projectId_; - onChanged(); - } - if (!other.getTriggerId().isEmpty()) { - triggerId_ = other.triggerId_; - onChanged(); - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - projectId_ = input.readStringRequireUtf8(); - - break; - } // case 10 - case 18: - { - triggerId_ = input.readStringRequireUtf8(); - - break; - } // case 18 - case 26: - { - name_ = input.readStringRequireUtf8(); - - break; - } // case 26 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private java.lang.Object name_ = ""; - /** - * - * - *
-     * The name of the `Trigger` to retrieve.
-     * Format: `projects/{project}/locations/{location}/triggers/{trigger}`
-     * 
- * - * string name = 3 [(.google.api.resource_reference) = { ... } - * - * @return The name. - */ - public java.lang.String getName() { - java.lang.Object ref = name_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - name_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * The name of the `Trigger` to retrieve.
-     * Format: `projects/{project}/locations/{location}/triggers/{trigger}`
-     * 
- * - * string name = 3 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for name. - */ - public com.google.protobuf.ByteString getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * The name of the `Trigger` to retrieve.
-     * Format: `projects/{project}/locations/{location}/triggers/{trigger}`
-     * 
- * - * string name = 3 [(.google.api.resource_reference) = { ... } - * - * @param value The name to set. - * @return This builder for chaining. - */ - public Builder setName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - name_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the `Trigger` to retrieve.
-     * Format: `projects/{project}/locations/{location}/triggers/{trigger}`
-     * 
- * - * string name = 3 [(.google.api.resource_reference) = { ... } - * - * @return This builder for chaining. - */ - public Builder clearName() { - - name_ = getDefaultInstance().getName(); - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the `Trigger` to retrieve.
-     * Format: `projects/{project}/locations/{location}/triggers/{trigger}`
-     * 
- * - * string name = 3 [(.google.api.resource_reference) = { ... } - * - * @param value The bytes for name to set. - * @return This builder for chaining. - */ - public Builder setNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - name_ = value; - onChanged(); - return this; - } - - private java.lang.Object projectId_ = ""; - /** - * - * - *
-     * Required. ID of the project that owns the trigger.
-     * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The projectId. - */ - public java.lang.String getProjectId() { - java.lang.Object ref = projectId_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - projectId_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Required. ID of the project that owns the trigger.
-     * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for projectId. - */ - public com.google.protobuf.ByteString getProjectIdBytes() { - java.lang.Object ref = projectId_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - projectId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Required. ID of the project that owns the trigger.
-     * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @param value The projectId to set. - * @return This builder for chaining. - */ - public Builder setProjectId(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - projectId_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Required. ID of the project that owns the trigger.
-     * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return This builder for chaining. - */ - public Builder clearProjectId() { - - projectId_ = getDefaultInstance().getProjectId(); - onChanged(); - return this; - } - /** - * - * - *
-     * Required. ID of the project that owns the trigger.
-     * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @param value The bytes for projectId to set. - * @return This builder for chaining. - */ - public Builder setProjectIdBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - projectId_ = value; - onChanged(); - return this; - } - - private java.lang.Object triggerId_ = ""; - /** - * - * - *
-     * Required. Identifier (`id` or `name`) of the `BuildTrigger` to get.
-     * 
- * - * string trigger_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The triggerId. - */ - public java.lang.String getTriggerId() { - java.lang.Object ref = triggerId_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - triggerId_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Required. Identifier (`id` or `name`) of the `BuildTrigger` to get.
-     * 
- * - * string trigger_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for triggerId. - */ - public com.google.protobuf.ByteString getTriggerIdBytes() { - java.lang.Object ref = triggerId_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - triggerId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Required. Identifier (`id` or `name`) of the `BuildTrigger` to get.
-     * 
- * - * string trigger_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @param value The triggerId to set. - * @return This builder for chaining. - */ - public Builder setTriggerId(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - triggerId_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Required. Identifier (`id` or `name`) of the `BuildTrigger` to get.
-     * 
- * - * string trigger_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @return This builder for chaining. - */ - public Builder clearTriggerId() { - - triggerId_ = getDefaultInstance().getTriggerId(); - onChanged(); - return this; - } - /** - * - * - *
-     * Required. Identifier (`id` or `name`) of the `BuildTrigger` to get.
-     * 
- * - * string trigger_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @param value The bytes for triggerId to set. - * @return This builder for chaining. - */ - public Builder setTriggerIdBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - triggerId_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.GetBuildTriggerRequest) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.GetBuildTriggerRequest) - private static final com.google.cloudbuild.v1.GetBuildTriggerRequest DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.GetBuildTriggerRequest(); - } - - public static com.google.cloudbuild.v1.GetBuildTriggerRequest getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public GetBuildTriggerRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.GetBuildTriggerRequest getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GetBuildTriggerRequestOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GetBuildTriggerRequestOrBuilder.java deleted file mode 100644 index dc659ffd..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GetBuildTriggerRequestOrBuilder.java +++ /dev/null @@ -1,102 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface GetBuildTriggerRequestOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.GetBuildTriggerRequest) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The name of the `Trigger` to retrieve.
-   * Format: `projects/{project}/locations/{location}/triggers/{trigger}`
-   * 
- * - * string name = 3 [(.google.api.resource_reference) = { ... } - * - * @return The name. - */ - java.lang.String getName(); - /** - * - * - *
-   * The name of the `Trigger` to retrieve.
-   * Format: `projects/{project}/locations/{location}/triggers/{trigger}`
-   * 
- * - * string name = 3 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for name. - */ - com.google.protobuf.ByteString getNameBytes(); - - /** - * - * - *
-   * Required. ID of the project that owns the trigger.
-   * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The projectId. - */ - java.lang.String getProjectId(); - /** - * - * - *
-   * Required. ID of the project that owns the trigger.
-   * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for projectId. - */ - com.google.protobuf.ByteString getProjectIdBytes(); - - /** - * - * - *
-   * Required. Identifier (`id` or `name`) of the `BuildTrigger` to get.
-   * 
- * - * string trigger_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The triggerId. - */ - java.lang.String getTriggerId(); - /** - * - * - *
-   * Required. Identifier (`id` or `name`) of the `BuildTrigger` to get.
-   * 
- * - * string trigger_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for triggerId. - */ - com.google.protobuf.ByteString getTriggerIdBytes(); -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GetWorkerPoolRequest.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GetWorkerPoolRequest.java deleted file mode 100644 index 192beb8d..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GetWorkerPoolRequest.java +++ /dev/null @@ -1,635 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * Request to get a `WorkerPool` with the specified name.
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.GetWorkerPoolRequest} - */ -public final class GetWorkerPoolRequest extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.GetWorkerPoolRequest) - GetWorkerPoolRequestOrBuilder { - private static final long serialVersionUID = 0L; - // Use GetWorkerPoolRequest.newBuilder() to construct. - private GetWorkerPoolRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private GetWorkerPoolRequest() { - name_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new GetWorkerPoolRequest(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_GetWorkerPoolRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_GetWorkerPoolRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.GetWorkerPoolRequest.class, - com.google.cloudbuild.v1.GetWorkerPoolRequest.Builder.class); - } - - public static final int NAME_FIELD_NUMBER = 1; - private volatile java.lang.Object name_; - /** - * - * - *
-   * Required. The name of the `WorkerPool` to retrieve.
-   * Format: `projects/{project}/locations/{location}/workerPools/{workerPool}`.
-   * 
- * - * - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return The name. - */ - @java.lang.Override - public java.lang.String getName() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - name_ = s; - return s; - } - } - /** - * - * - *
-   * Required. The name of the `WorkerPool` to retrieve.
-   * Format: `projects/{project}/locations/{location}/workerPools/{workerPool}`.
-   * 
- * - * - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return The bytes for name. - */ - @java.lang.Override - public com.google.protobuf.ByteString getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.GetWorkerPoolRequest)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.GetWorkerPoolRequest other = - (com.google.cloudbuild.v1.GetWorkerPoolRequest) obj; - - if (!getName().equals(other.getName())) return false; - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + NAME_FIELD_NUMBER; - hash = (53 * hash) + getName().hashCode(); - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.GetWorkerPoolRequest parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.GetWorkerPoolRequest parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.GetWorkerPoolRequest parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.GetWorkerPoolRequest parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.GetWorkerPoolRequest parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.GetWorkerPoolRequest parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.GetWorkerPoolRequest parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.GetWorkerPoolRequest parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.GetWorkerPoolRequest parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.GetWorkerPoolRequest parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.GetWorkerPoolRequest parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.GetWorkerPoolRequest parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.GetWorkerPoolRequest prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * Request to get a `WorkerPool` with the specified name.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.GetWorkerPoolRequest} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.GetWorkerPoolRequest) - com.google.cloudbuild.v1.GetWorkerPoolRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_GetWorkerPoolRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_GetWorkerPoolRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.GetWorkerPoolRequest.class, - com.google.cloudbuild.v1.GetWorkerPoolRequest.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.GetWorkerPoolRequest.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - name_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_GetWorkerPoolRequest_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.GetWorkerPoolRequest getDefaultInstanceForType() { - return com.google.cloudbuild.v1.GetWorkerPoolRequest.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.GetWorkerPoolRequest build() { - com.google.cloudbuild.v1.GetWorkerPoolRequest result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.GetWorkerPoolRequest buildPartial() { - com.google.cloudbuild.v1.GetWorkerPoolRequest result = - new com.google.cloudbuild.v1.GetWorkerPoolRequest(this); - result.name_ = name_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.GetWorkerPoolRequest) { - return mergeFrom((com.google.cloudbuild.v1.GetWorkerPoolRequest) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.GetWorkerPoolRequest other) { - if (other == com.google.cloudbuild.v1.GetWorkerPoolRequest.getDefaultInstance()) return this; - if (!other.getName().isEmpty()) { - name_ = other.name_; - onChanged(); - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - name_ = input.readStringRequireUtf8(); - - break; - } // case 10 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private java.lang.Object name_ = ""; - /** - * - * - *
-     * Required. The name of the `WorkerPool` to retrieve.
-     * Format: `projects/{project}/locations/{location}/workerPools/{workerPool}`.
-     * 
- * - * - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return The name. - */ - public java.lang.String getName() { - java.lang.Object ref = name_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - name_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Required. The name of the `WorkerPool` to retrieve.
-     * Format: `projects/{project}/locations/{location}/workerPools/{workerPool}`.
-     * 
- * - * - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return The bytes for name. - */ - public com.google.protobuf.ByteString getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Required. The name of the `WorkerPool` to retrieve.
-     * Format: `projects/{project}/locations/{location}/workerPools/{workerPool}`.
-     * 
- * - * - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @param value The name to set. - * @return This builder for chaining. - */ - public Builder setName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - name_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Required. The name of the `WorkerPool` to retrieve.
-     * Format: `projects/{project}/locations/{location}/workerPools/{workerPool}`.
-     * 
- * - * - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return This builder for chaining. - */ - public Builder clearName() { - - name_ = getDefaultInstance().getName(); - onChanged(); - return this; - } - /** - * - * - *
-     * Required. The name of the `WorkerPool` to retrieve.
-     * Format: `projects/{project}/locations/{location}/workerPools/{workerPool}`.
-     * 
- * - * - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @param value The bytes for name to set. - * @return This builder for chaining. - */ - public Builder setNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - name_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.GetWorkerPoolRequest) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.GetWorkerPoolRequest) - private static final com.google.cloudbuild.v1.GetWorkerPoolRequest DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.GetWorkerPoolRequest(); - } - - public static com.google.cloudbuild.v1.GetWorkerPoolRequest getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public GetWorkerPoolRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.GetWorkerPoolRequest getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GetWorkerPoolRequestOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GetWorkerPoolRequestOrBuilder.java deleted file mode 100644 index 2d8a6c39..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GetWorkerPoolRequestOrBuilder.java +++ /dev/null @@ -1,56 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface GetWorkerPoolRequestOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.GetWorkerPoolRequest) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * Required. The name of the `WorkerPool` to retrieve.
-   * Format: `projects/{project}/locations/{location}/workerPools/{workerPool}`.
-   * 
- * - * - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return The name. - */ - java.lang.String getName(); - /** - * - * - *
-   * Required. The name of the `WorkerPool` to retrieve.
-   * Format: `projects/{project}/locations/{location}/workerPools/{workerPool}`.
-   * 
- * - * - * string name = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return The bytes for name. - */ - com.google.protobuf.ByteString getNameBytes(); -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GitHubEventsConfig.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GitHubEventsConfig.java deleted file mode 100644 index 782d2155..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GitHubEventsConfig.java +++ /dev/null @@ -1,1589 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * GitHubEventsConfig describes the configuration of a trigger that creates a
- * build whenever a GitHub event is received.
- * This message is experimental.
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.GitHubEventsConfig} - */ -public final class GitHubEventsConfig extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.GitHubEventsConfig) - GitHubEventsConfigOrBuilder { - private static final long serialVersionUID = 0L; - // Use GitHubEventsConfig.newBuilder() to construct. - private GitHubEventsConfig(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private GitHubEventsConfig() { - owner_ = ""; - name_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new GitHubEventsConfig(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_GitHubEventsConfig_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_GitHubEventsConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.GitHubEventsConfig.class, - com.google.cloudbuild.v1.GitHubEventsConfig.Builder.class); - } - - private int eventCase_ = 0; - private java.lang.Object event_; - - public enum EventCase - implements - com.google.protobuf.Internal.EnumLite, - com.google.protobuf.AbstractMessage.InternalOneOfEnum { - PULL_REQUEST(4), - PUSH(5), - EVENT_NOT_SET(0); - private final int value; - - private EventCase(int value) { - this.value = value; - } - /** - * @param value The number of the enum to look for. - * @return The enum associated with the given number. - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static EventCase valueOf(int value) { - return forNumber(value); - } - - public static EventCase forNumber(int value) { - switch (value) { - case 4: - return PULL_REQUEST; - case 5: - return PUSH; - case 0: - return EVENT_NOT_SET; - default: - return null; - } - } - - public int getNumber() { - return this.value; - } - }; - - public EventCase getEventCase() { - return EventCase.forNumber(eventCase_); - } - - public static final int INSTALLATION_ID_FIELD_NUMBER = 1; - private long installationId_; - /** - * - * - *
-   * The installationID that emits the GitHub event.
-   * 
- * - * int64 installation_id = 1 [deprecated = true]; - * - * @deprecated google.devtools.cloudbuild.v1.GitHubEventsConfig.installation_id is deprecated. See - * google/devtools/cloudbuild/v1/cloudbuild.proto;l=1396 - * @return The installationId. - */ - @java.lang.Override - @java.lang.Deprecated - public long getInstallationId() { - return installationId_; - } - - public static final int OWNER_FIELD_NUMBER = 6; - private volatile java.lang.Object owner_; - /** - * - * - *
-   * Owner of the repository. For example: The owner for
-   * https://github.com/googlecloudplatform/cloud-builders is
-   * "googlecloudplatform".
-   * 
- * - * string owner = 6; - * - * @return The owner. - */ - @java.lang.Override - public java.lang.String getOwner() { - java.lang.Object ref = owner_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - owner_ = s; - return s; - } - } - /** - * - * - *
-   * Owner of the repository. For example: The owner for
-   * https://github.com/googlecloudplatform/cloud-builders is
-   * "googlecloudplatform".
-   * 
- * - * string owner = 6; - * - * @return The bytes for owner. - */ - @java.lang.Override - public com.google.protobuf.ByteString getOwnerBytes() { - java.lang.Object ref = owner_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - owner_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int NAME_FIELD_NUMBER = 7; - private volatile java.lang.Object name_; - /** - * - * - *
-   * Name of the repository. For example: The name for
-   * https://github.com/googlecloudplatform/cloud-builders is "cloud-builders".
-   * 
- * - * string name = 7; - * - * @return The name. - */ - @java.lang.Override - public java.lang.String getName() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - name_ = s; - return s; - } - } - /** - * - * - *
-   * Name of the repository. For example: The name for
-   * https://github.com/googlecloudplatform/cloud-builders is "cloud-builders".
-   * 
- * - * string name = 7; - * - * @return The bytes for name. - */ - @java.lang.Override - public com.google.protobuf.ByteString getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int PULL_REQUEST_FIELD_NUMBER = 4; - /** - * - * - *
-   * filter to match changes in pull requests.
-   * 
- * - * .google.devtools.cloudbuild.v1.PullRequestFilter pull_request = 4; - * - * @return Whether the pullRequest field is set. - */ - @java.lang.Override - public boolean hasPullRequest() { - return eventCase_ == 4; - } - /** - * - * - *
-   * filter to match changes in pull requests.
-   * 
- * - * .google.devtools.cloudbuild.v1.PullRequestFilter pull_request = 4; - * - * @return The pullRequest. - */ - @java.lang.Override - public com.google.cloudbuild.v1.PullRequestFilter getPullRequest() { - if (eventCase_ == 4) { - return (com.google.cloudbuild.v1.PullRequestFilter) event_; - } - return com.google.cloudbuild.v1.PullRequestFilter.getDefaultInstance(); - } - /** - * - * - *
-   * filter to match changes in pull requests.
-   * 
- * - * .google.devtools.cloudbuild.v1.PullRequestFilter pull_request = 4; - */ - @java.lang.Override - public com.google.cloudbuild.v1.PullRequestFilterOrBuilder getPullRequestOrBuilder() { - if (eventCase_ == 4) { - return (com.google.cloudbuild.v1.PullRequestFilter) event_; - } - return com.google.cloudbuild.v1.PullRequestFilter.getDefaultInstance(); - } - - public static final int PUSH_FIELD_NUMBER = 5; - /** - * - * - *
-   * filter to match changes in refs like branches, tags.
-   * 
- * - * .google.devtools.cloudbuild.v1.PushFilter push = 5; - * - * @return Whether the push field is set. - */ - @java.lang.Override - public boolean hasPush() { - return eventCase_ == 5; - } - /** - * - * - *
-   * filter to match changes in refs like branches, tags.
-   * 
- * - * .google.devtools.cloudbuild.v1.PushFilter push = 5; - * - * @return The push. - */ - @java.lang.Override - public com.google.cloudbuild.v1.PushFilter getPush() { - if (eventCase_ == 5) { - return (com.google.cloudbuild.v1.PushFilter) event_; - } - return com.google.cloudbuild.v1.PushFilter.getDefaultInstance(); - } - /** - * - * - *
-   * filter to match changes in refs like branches, tags.
-   * 
- * - * .google.devtools.cloudbuild.v1.PushFilter push = 5; - */ - @java.lang.Override - public com.google.cloudbuild.v1.PushFilterOrBuilder getPushOrBuilder() { - if (eventCase_ == 5) { - return (com.google.cloudbuild.v1.PushFilter) event_; - } - return com.google.cloudbuild.v1.PushFilter.getDefaultInstance(); - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (installationId_ != 0L) { - output.writeInt64(1, installationId_); - } - if (eventCase_ == 4) { - output.writeMessage(4, (com.google.cloudbuild.v1.PullRequestFilter) event_); - } - if (eventCase_ == 5) { - output.writeMessage(5, (com.google.cloudbuild.v1.PushFilter) event_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(owner_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 6, owner_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 7, name_); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (installationId_ != 0L) { - size += com.google.protobuf.CodedOutputStream.computeInt64Size(1, installationId_); - } - if (eventCase_ == 4) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 4, (com.google.cloudbuild.v1.PullRequestFilter) event_); - } - if (eventCase_ == 5) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 5, (com.google.cloudbuild.v1.PushFilter) event_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(owner_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(6, owner_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(7, name_); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.GitHubEventsConfig)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.GitHubEventsConfig other = - (com.google.cloudbuild.v1.GitHubEventsConfig) obj; - - if (getInstallationId() != other.getInstallationId()) return false; - if (!getOwner().equals(other.getOwner())) return false; - if (!getName().equals(other.getName())) return false; - if (!getEventCase().equals(other.getEventCase())) return false; - switch (eventCase_) { - case 4: - if (!getPullRequest().equals(other.getPullRequest())) return false; - break; - case 5: - if (!getPush().equals(other.getPush())) return false; - break; - case 0: - default: - } - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + INSTALLATION_ID_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getInstallationId()); - hash = (37 * hash) + OWNER_FIELD_NUMBER; - hash = (53 * hash) + getOwner().hashCode(); - hash = (37 * hash) + NAME_FIELD_NUMBER; - hash = (53 * hash) + getName().hashCode(); - switch (eventCase_) { - case 4: - hash = (37 * hash) + PULL_REQUEST_FIELD_NUMBER; - hash = (53 * hash) + getPullRequest().hashCode(); - break; - case 5: - hash = (37 * hash) + PUSH_FIELD_NUMBER; - hash = (53 * hash) + getPush().hashCode(); - break; - case 0: - default: - } - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.GitHubEventsConfig parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.GitHubEventsConfig parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.GitHubEventsConfig parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.GitHubEventsConfig parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.GitHubEventsConfig parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.GitHubEventsConfig parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.GitHubEventsConfig parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.GitHubEventsConfig parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.GitHubEventsConfig parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.GitHubEventsConfig parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.GitHubEventsConfig parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.GitHubEventsConfig parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.GitHubEventsConfig prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * GitHubEventsConfig describes the configuration of a trigger that creates a
-   * build whenever a GitHub event is received.
-   * This message is experimental.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.GitHubEventsConfig} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.GitHubEventsConfig) - com.google.cloudbuild.v1.GitHubEventsConfigOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_GitHubEventsConfig_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_GitHubEventsConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.GitHubEventsConfig.class, - com.google.cloudbuild.v1.GitHubEventsConfig.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.GitHubEventsConfig.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - installationId_ = 0L; - - owner_ = ""; - - name_ = ""; - - if (pullRequestBuilder_ != null) { - pullRequestBuilder_.clear(); - } - if (pushBuilder_ != null) { - pushBuilder_.clear(); - } - eventCase_ = 0; - event_ = null; - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_GitHubEventsConfig_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.GitHubEventsConfig getDefaultInstanceForType() { - return com.google.cloudbuild.v1.GitHubEventsConfig.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.GitHubEventsConfig build() { - com.google.cloudbuild.v1.GitHubEventsConfig result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.GitHubEventsConfig buildPartial() { - com.google.cloudbuild.v1.GitHubEventsConfig result = - new com.google.cloudbuild.v1.GitHubEventsConfig(this); - result.installationId_ = installationId_; - result.owner_ = owner_; - result.name_ = name_; - if (eventCase_ == 4) { - if (pullRequestBuilder_ == null) { - result.event_ = event_; - } else { - result.event_ = pullRequestBuilder_.build(); - } - } - if (eventCase_ == 5) { - if (pushBuilder_ == null) { - result.event_ = event_; - } else { - result.event_ = pushBuilder_.build(); - } - } - result.eventCase_ = eventCase_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.GitHubEventsConfig) { - return mergeFrom((com.google.cloudbuild.v1.GitHubEventsConfig) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.GitHubEventsConfig other) { - if (other == com.google.cloudbuild.v1.GitHubEventsConfig.getDefaultInstance()) return this; - if (other.getInstallationId() != 0L) { - setInstallationId(other.getInstallationId()); - } - if (!other.getOwner().isEmpty()) { - owner_ = other.owner_; - onChanged(); - } - if (!other.getName().isEmpty()) { - name_ = other.name_; - onChanged(); - } - switch (other.getEventCase()) { - case PULL_REQUEST: - { - mergePullRequest(other.getPullRequest()); - break; - } - case PUSH: - { - mergePush(other.getPush()); - break; - } - case EVENT_NOT_SET: - { - break; - } - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 8: - { - installationId_ = input.readInt64(); - - break; - } // case 8 - case 34: - { - input.readMessage(getPullRequestFieldBuilder().getBuilder(), extensionRegistry); - eventCase_ = 4; - break; - } // case 34 - case 42: - { - input.readMessage(getPushFieldBuilder().getBuilder(), extensionRegistry); - eventCase_ = 5; - break; - } // case 42 - case 50: - { - owner_ = input.readStringRequireUtf8(); - - break; - } // case 50 - case 58: - { - name_ = input.readStringRequireUtf8(); - - break; - } // case 58 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private int eventCase_ = 0; - private java.lang.Object event_; - - public EventCase getEventCase() { - return EventCase.forNumber(eventCase_); - } - - public Builder clearEvent() { - eventCase_ = 0; - event_ = null; - onChanged(); - return this; - } - - private long installationId_; - /** - * - * - *
-     * The installationID that emits the GitHub event.
-     * 
- * - * int64 installation_id = 1 [deprecated = true]; - * - * @deprecated google.devtools.cloudbuild.v1.GitHubEventsConfig.installation_id is deprecated. - * See google/devtools/cloudbuild/v1/cloudbuild.proto;l=1396 - * @return The installationId. - */ - @java.lang.Override - @java.lang.Deprecated - public long getInstallationId() { - return installationId_; - } - /** - * - * - *
-     * The installationID that emits the GitHub event.
-     * 
- * - * int64 installation_id = 1 [deprecated = true]; - * - * @deprecated google.devtools.cloudbuild.v1.GitHubEventsConfig.installation_id is deprecated. - * See google/devtools/cloudbuild/v1/cloudbuild.proto;l=1396 - * @param value The installationId to set. - * @return This builder for chaining. - */ - @java.lang.Deprecated - public Builder setInstallationId(long value) { - - installationId_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The installationID that emits the GitHub event.
-     * 
- * - * int64 installation_id = 1 [deprecated = true]; - * - * @deprecated google.devtools.cloudbuild.v1.GitHubEventsConfig.installation_id is deprecated. - * See google/devtools/cloudbuild/v1/cloudbuild.proto;l=1396 - * @return This builder for chaining. - */ - @java.lang.Deprecated - public Builder clearInstallationId() { - - installationId_ = 0L; - onChanged(); - return this; - } - - private java.lang.Object owner_ = ""; - /** - * - * - *
-     * Owner of the repository. For example: The owner for
-     * https://github.com/googlecloudplatform/cloud-builders is
-     * "googlecloudplatform".
-     * 
- * - * string owner = 6; - * - * @return The owner. - */ - public java.lang.String getOwner() { - java.lang.Object ref = owner_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - owner_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Owner of the repository. For example: The owner for
-     * https://github.com/googlecloudplatform/cloud-builders is
-     * "googlecloudplatform".
-     * 
- * - * string owner = 6; - * - * @return The bytes for owner. - */ - public com.google.protobuf.ByteString getOwnerBytes() { - java.lang.Object ref = owner_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - owner_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Owner of the repository. For example: The owner for
-     * https://github.com/googlecloudplatform/cloud-builders is
-     * "googlecloudplatform".
-     * 
- * - * string owner = 6; - * - * @param value The owner to set. - * @return This builder for chaining. - */ - public Builder setOwner(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - owner_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Owner of the repository. For example: The owner for
-     * https://github.com/googlecloudplatform/cloud-builders is
-     * "googlecloudplatform".
-     * 
- * - * string owner = 6; - * - * @return This builder for chaining. - */ - public Builder clearOwner() { - - owner_ = getDefaultInstance().getOwner(); - onChanged(); - return this; - } - /** - * - * - *
-     * Owner of the repository. For example: The owner for
-     * https://github.com/googlecloudplatform/cloud-builders is
-     * "googlecloudplatform".
-     * 
- * - * string owner = 6; - * - * @param value The bytes for owner to set. - * @return This builder for chaining. - */ - public Builder setOwnerBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - owner_ = value; - onChanged(); - return this; - } - - private java.lang.Object name_ = ""; - /** - * - * - *
-     * Name of the repository. For example: The name for
-     * https://github.com/googlecloudplatform/cloud-builders is "cloud-builders".
-     * 
- * - * string name = 7; - * - * @return The name. - */ - public java.lang.String getName() { - java.lang.Object ref = name_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - name_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Name of the repository. For example: The name for
-     * https://github.com/googlecloudplatform/cloud-builders is "cloud-builders".
-     * 
- * - * string name = 7; - * - * @return The bytes for name. - */ - public com.google.protobuf.ByteString getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Name of the repository. For example: The name for
-     * https://github.com/googlecloudplatform/cloud-builders is "cloud-builders".
-     * 
- * - * string name = 7; - * - * @param value The name to set. - * @return This builder for chaining. - */ - public Builder setName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - name_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Name of the repository. For example: The name for
-     * https://github.com/googlecloudplatform/cloud-builders is "cloud-builders".
-     * 
- * - * string name = 7; - * - * @return This builder for chaining. - */ - public Builder clearName() { - - name_ = getDefaultInstance().getName(); - onChanged(); - return this; - } - /** - * - * - *
-     * Name of the repository. For example: The name for
-     * https://github.com/googlecloudplatform/cloud-builders is "cloud-builders".
-     * 
- * - * string name = 7; - * - * @param value The bytes for name to set. - * @return This builder for chaining. - */ - public Builder setNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - name_ = value; - onChanged(); - return this; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.PullRequestFilter, - com.google.cloudbuild.v1.PullRequestFilter.Builder, - com.google.cloudbuild.v1.PullRequestFilterOrBuilder> - pullRequestBuilder_; - /** - * - * - *
-     * filter to match changes in pull requests.
-     * 
- * - * .google.devtools.cloudbuild.v1.PullRequestFilter pull_request = 4; - * - * @return Whether the pullRequest field is set. - */ - @java.lang.Override - public boolean hasPullRequest() { - return eventCase_ == 4; - } - /** - * - * - *
-     * filter to match changes in pull requests.
-     * 
- * - * .google.devtools.cloudbuild.v1.PullRequestFilter pull_request = 4; - * - * @return The pullRequest. - */ - @java.lang.Override - public com.google.cloudbuild.v1.PullRequestFilter getPullRequest() { - if (pullRequestBuilder_ == null) { - if (eventCase_ == 4) { - return (com.google.cloudbuild.v1.PullRequestFilter) event_; - } - return com.google.cloudbuild.v1.PullRequestFilter.getDefaultInstance(); - } else { - if (eventCase_ == 4) { - return pullRequestBuilder_.getMessage(); - } - return com.google.cloudbuild.v1.PullRequestFilter.getDefaultInstance(); - } - } - /** - * - * - *
-     * filter to match changes in pull requests.
-     * 
- * - * .google.devtools.cloudbuild.v1.PullRequestFilter pull_request = 4; - */ - public Builder setPullRequest(com.google.cloudbuild.v1.PullRequestFilter value) { - if (pullRequestBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - event_ = value; - onChanged(); - } else { - pullRequestBuilder_.setMessage(value); - } - eventCase_ = 4; - return this; - } - /** - * - * - *
-     * filter to match changes in pull requests.
-     * 
- * - * .google.devtools.cloudbuild.v1.PullRequestFilter pull_request = 4; - */ - public Builder setPullRequest( - com.google.cloudbuild.v1.PullRequestFilter.Builder builderForValue) { - if (pullRequestBuilder_ == null) { - event_ = builderForValue.build(); - onChanged(); - } else { - pullRequestBuilder_.setMessage(builderForValue.build()); - } - eventCase_ = 4; - return this; - } - /** - * - * - *
-     * filter to match changes in pull requests.
-     * 
- * - * .google.devtools.cloudbuild.v1.PullRequestFilter pull_request = 4; - */ - public Builder mergePullRequest(com.google.cloudbuild.v1.PullRequestFilter value) { - if (pullRequestBuilder_ == null) { - if (eventCase_ == 4 - && event_ != com.google.cloudbuild.v1.PullRequestFilter.getDefaultInstance()) { - event_ = - com.google.cloudbuild.v1.PullRequestFilter.newBuilder( - (com.google.cloudbuild.v1.PullRequestFilter) event_) - .mergeFrom(value) - .buildPartial(); - } else { - event_ = value; - } - onChanged(); - } else { - if (eventCase_ == 4) { - pullRequestBuilder_.mergeFrom(value); - } else { - pullRequestBuilder_.setMessage(value); - } - } - eventCase_ = 4; - return this; - } - /** - * - * - *
-     * filter to match changes in pull requests.
-     * 
- * - * .google.devtools.cloudbuild.v1.PullRequestFilter pull_request = 4; - */ - public Builder clearPullRequest() { - if (pullRequestBuilder_ == null) { - if (eventCase_ == 4) { - eventCase_ = 0; - event_ = null; - onChanged(); - } - } else { - if (eventCase_ == 4) { - eventCase_ = 0; - event_ = null; - } - pullRequestBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * filter to match changes in pull requests.
-     * 
- * - * .google.devtools.cloudbuild.v1.PullRequestFilter pull_request = 4; - */ - public com.google.cloudbuild.v1.PullRequestFilter.Builder getPullRequestBuilder() { - return getPullRequestFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * filter to match changes in pull requests.
-     * 
- * - * .google.devtools.cloudbuild.v1.PullRequestFilter pull_request = 4; - */ - @java.lang.Override - public com.google.cloudbuild.v1.PullRequestFilterOrBuilder getPullRequestOrBuilder() { - if ((eventCase_ == 4) && (pullRequestBuilder_ != null)) { - return pullRequestBuilder_.getMessageOrBuilder(); - } else { - if (eventCase_ == 4) { - return (com.google.cloudbuild.v1.PullRequestFilter) event_; - } - return com.google.cloudbuild.v1.PullRequestFilter.getDefaultInstance(); - } - } - /** - * - * - *
-     * filter to match changes in pull requests.
-     * 
- * - * .google.devtools.cloudbuild.v1.PullRequestFilter pull_request = 4; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.PullRequestFilter, - com.google.cloudbuild.v1.PullRequestFilter.Builder, - com.google.cloudbuild.v1.PullRequestFilterOrBuilder> - getPullRequestFieldBuilder() { - if (pullRequestBuilder_ == null) { - if (!(eventCase_ == 4)) { - event_ = com.google.cloudbuild.v1.PullRequestFilter.getDefaultInstance(); - } - pullRequestBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.PullRequestFilter, - com.google.cloudbuild.v1.PullRequestFilter.Builder, - com.google.cloudbuild.v1.PullRequestFilterOrBuilder>( - (com.google.cloudbuild.v1.PullRequestFilter) event_, - getParentForChildren(), - isClean()); - event_ = null; - } - eventCase_ = 4; - onChanged(); - ; - return pullRequestBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.PushFilter, - com.google.cloudbuild.v1.PushFilter.Builder, - com.google.cloudbuild.v1.PushFilterOrBuilder> - pushBuilder_; - /** - * - * - *
-     * filter to match changes in refs like branches, tags.
-     * 
- * - * .google.devtools.cloudbuild.v1.PushFilter push = 5; - * - * @return Whether the push field is set. - */ - @java.lang.Override - public boolean hasPush() { - return eventCase_ == 5; - } - /** - * - * - *
-     * filter to match changes in refs like branches, tags.
-     * 
- * - * .google.devtools.cloudbuild.v1.PushFilter push = 5; - * - * @return The push. - */ - @java.lang.Override - public com.google.cloudbuild.v1.PushFilter getPush() { - if (pushBuilder_ == null) { - if (eventCase_ == 5) { - return (com.google.cloudbuild.v1.PushFilter) event_; - } - return com.google.cloudbuild.v1.PushFilter.getDefaultInstance(); - } else { - if (eventCase_ == 5) { - return pushBuilder_.getMessage(); - } - return com.google.cloudbuild.v1.PushFilter.getDefaultInstance(); - } - } - /** - * - * - *
-     * filter to match changes in refs like branches, tags.
-     * 
- * - * .google.devtools.cloudbuild.v1.PushFilter push = 5; - */ - public Builder setPush(com.google.cloudbuild.v1.PushFilter value) { - if (pushBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - event_ = value; - onChanged(); - } else { - pushBuilder_.setMessage(value); - } - eventCase_ = 5; - return this; - } - /** - * - * - *
-     * filter to match changes in refs like branches, tags.
-     * 
- * - * .google.devtools.cloudbuild.v1.PushFilter push = 5; - */ - public Builder setPush(com.google.cloudbuild.v1.PushFilter.Builder builderForValue) { - if (pushBuilder_ == null) { - event_ = builderForValue.build(); - onChanged(); - } else { - pushBuilder_.setMessage(builderForValue.build()); - } - eventCase_ = 5; - return this; - } - /** - * - * - *
-     * filter to match changes in refs like branches, tags.
-     * 
- * - * .google.devtools.cloudbuild.v1.PushFilter push = 5; - */ - public Builder mergePush(com.google.cloudbuild.v1.PushFilter value) { - if (pushBuilder_ == null) { - if (eventCase_ == 5 && event_ != com.google.cloudbuild.v1.PushFilter.getDefaultInstance()) { - event_ = - com.google.cloudbuild.v1.PushFilter.newBuilder( - (com.google.cloudbuild.v1.PushFilter) event_) - .mergeFrom(value) - .buildPartial(); - } else { - event_ = value; - } - onChanged(); - } else { - if (eventCase_ == 5) { - pushBuilder_.mergeFrom(value); - } else { - pushBuilder_.setMessage(value); - } - } - eventCase_ = 5; - return this; - } - /** - * - * - *
-     * filter to match changes in refs like branches, tags.
-     * 
- * - * .google.devtools.cloudbuild.v1.PushFilter push = 5; - */ - public Builder clearPush() { - if (pushBuilder_ == null) { - if (eventCase_ == 5) { - eventCase_ = 0; - event_ = null; - onChanged(); - } - } else { - if (eventCase_ == 5) { - eventCase_ = 0; - event_ = null; - } - pushBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * filter to match changes in refs like branches, tags.
-     * 
- * - * .google.devtools.cloudbuild.v1.PushFilter push = 5; - */ - public com.google.cloudbuild.v1.PushFilter.Builder getPushBuilder() { - return getPushFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * filter to match changes in refs like branches, tags.
-     * 
- * - * .google.devtools.cloudbuild.v1.PushFilter push = 5; - */ - @java.lang.Override - public com.google.cloudbuild.v1.PushFilterOrBuilder getPushOrBuilder() { - if ((eventCase_ == 5) && (pushBuilder_ != null)) { - return pushBuilder_.getMessageOrBuilder(); - } else { - if (eventCase_ == 5) { - return (com.google.cloudbuild.v1.PushFilter) event_; - } - return com.google.cloudbuild.v1.PushFilter.getDefaultInstance(); - } - } - /** - * - * - *
-     * filter to match changes in refs like branches, tags.
-     * 
- * - * .google.devtools.cloudbuild.v1.PushFilter push = 5; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.PushFilter, - com.google.cloudbuild.v1.PushFilter.Builder, - com.google.cloudbuild.v1.PushFilterOrBuilder> - getPushFieldBuilder() { - if (pushBuilder_ == null) { - if (!(eventCase_ == 5)) { - event_ = com.google.cloudbuild.v1.PushFilter.getDefaultInstance(); - } - pushBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.PushFilter, - com.google.cloudbuild.v1.PushFilter.Builder, - com.google.cloudbuild.v1.PushFilterOrBuilder>( - (com.google.cloudbuild.v1.PushFilter) event_, getParentForChildren(), isClean()); - event_ = null; - } - eventCase_ = 5; - onChanged(); - ; - return pushBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.GitHubEventsConfig) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.GitHubEventsConfig) - private static final com.google.cloudbuild.v1.GitHubEventsConfig DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.GitHubEventsConfig(); - } - - public static com.google.cloudbuild.v1.GitHubEventsConfig getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public GitHubEventsConfig parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.GitHubEventsConfig getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GitHubEventsConfigOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GitHubEventsConfigOrBuilder.java deleted file mode 100644 index 0b99026b..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GitHubEventsConfigOrBuilder.java +++ /dev/null @@ -1,169 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface GitHubEventsConfigOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.GitHubEventsConfig) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The installationID that emits the GitHub event.
-   * 
- * - * int64 installation_id = 1 [deprecated = true]; - * - * @deprecated google.devtools.cloudbuild.v1.GitHubEventsConfig.installation_id is deprecated. See - * google/devtools/cloudbuild/v1/cloudbuild.proto;l=1396 - * @return The installationId. - */ - @java.lang.Deprecated - long getInstallationId(); - - /** - * - * - *
-   * Owner of the repository. For example: The owner for
-   * https://github.com/googlecloudplatform/cloud-builders is
-   * "googlecloudplatform".
-   * 
- * - * string owner = 6; - * - * @return The owner. - */ - java.lang.String getOwner(); - /** - * - * - *
-   * Owner of the repository. For example: The owner for
-   * https://github.com/googlecloudplatform/cloud-builders is
-   * "googlecloudplatform".
-   * 
- * - * string owner = 6; - * - * @return The bytes for owner. - */ - com.google.protobuf.ByteString getOwnerBytes(); - - /** - * - * - *
-   * Name of the repository. For example: The name for
-   * https://github.com/googlecloudplatform/cloud-builders is "cloud-builders".
-   * 
- * - * string name = 7; - * - * @return The name. - */ - java.lang.String getName(); - /** - * - * - *
-   * Name of the repository. For example: The name for
-   * https://github.com/googlecloudplatform/cloud-builders is "cloud-builders".
-   * 
- * - * string name = 7; - * - * @return The bytes for name. - */ - com.google.protobuf.ByteString getNameBytes(); - - /** - * - * - *
-   * filter to match changes in pull requests.
-   * 
- * - * .google.devtools.cloudbuild.v1.PullRequestFilter pull_request = 4; - * - * @return Whether the pullRequest field is set. - */ - boolean hasPullRequest(); - /** - * - * - *
-   * filter to match changes in pull requests.
-   * 
- * - * .google.devtools.cloudbuild.v1.PullRequestFilter pull_request = 4; - * - * @return The pullRequest. - */ - com.google.cloudbuild.v1.PullRequestFilter getPullRequest(); - /** - * - * - *
-   * filter to match changes in pull requests.
-   * 
- * - * .google.devtools.cloudbuild.v1.PullRequestFilter pull_request = 4; - */ - com.google.cloudbuild.v1.PullRequestFilterOrBuilder getPullRequestOrBuilder(); - - /** - * - * - *
-   * filter to match changes in refs like branches, tags.
-   * 
- * - * .google.devtools.cloudbuild.v1.PushFilter push = 5; - * - * @return Whether the push field is set. - */ - boolean hasPush(); - /** - * - * - *
-   * filter to match changes in refs like branches, tags.
-   * 
- * - * .google.devtools.cloudbuild.v1.PushFilter push = 5; - * - * @return The push. - */ - com.google.cloudbuild.v1.PushFilter getPush(); - /** - * - * - *
-   * filter to match changes in refs like branches, tags.
-   * 
- * - * .google.devtools.cloudbuild.v1.PushFilter push = 5; - */ - com.google.cloudbuild.v1.PushFilterOrBuilder getPushOrBuilder(); - - public com.google.cloudbuild.v1.GitHubEventsConfig.EventCase getEventCase(); -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Hash.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Hash.java deleted file mode 100644 index 78889a60..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Hash.java +++ /dev/null @@ -1,832 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * Container message for hash values.
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.Hash} - */ -public final class Hash extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.Hash) - HashOrBuilder { - private static final long serialVersionUID = 0L; - // Use Hash.newBuilder() to construct. - private Hash(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private Hash() { - type_ = 0; - value_ = com.google.protobuf.ByteString.EMPTY; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new Hash(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Hash_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Hash_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.Hash.class, com.google.cloudbuild.v1.Hash.Builder.class); - } - - /** - * - * - *
-   * Specifies the hash algorithm, if any.
-   * 
- * - * Protobuf enum {@code google.devtools.cloudbuild.v1.Hash.HashType} - */ - public enum HashType implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
-     * No hash requested.
-     * 
- * - * NONE = 0; - */ - NONE(0), - /** - * - * - *
-     * Use a sha256 hash.
-     * 
- * - * SHA256 = 1; - */ - SHA256(1), - /** - * - * - *
-     * Use a md5 hash.
-     * 
- * - * MD5 = 2; - */ - MD5(2), - UNRECOGNIZED(-1), - ; - - /** - * - * - *
-     * No hash requested.
-     * 
- * - * NONE = 0; - */ - public static final int NONE_VALUE = 0; - /** - * - * - *
-     * Use a sha256 hash.
-     * 
- * - * SHA256 = 1; - */ - public static final int SHA256_VALUE = 1; - /** - * - * - *
-     * Use a md5 hash.
-     * 
- * - * MD5 = 2; - */ - public static final int MD5_VALUE = 2; - - public final int getNumber() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalArgumentException( - "Can't get the number of an unknown enum value."); - } - return value; - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static HashType valueOf(int value) { - return forNumber(value); - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - */ - public static HashType forNumber(int value) { - switch (value) { - case 0: - return NONE; - case 1: - return SHA256; - case 2: - return MD5; - default: - return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { - return internalValueMap; - } - - private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public HashType findValueByNumber(int number) { - return HashType.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalStateException( - "Can't get the descriptor of an unrecognized enum value."); - } - return getDescriptor().getValues().get(ordinal()); - } - - public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { - return getDescriptor(); - } - - public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return com.google.cloudbuild.v1.Hash.getDescriptor().getEnumTypes().get(0); - } - - private static final HashType[] VALUES = values(); - - public static HashType valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); - } - if (desc.getIndex() == -1) { - return UNRECOGNIZED; - } - return VALUES[desc.getIndex()]; - } - - private final int value; - - private HashType(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:google.devtools.cloudbuild.v1.Hash.HashType) - } - - public static final int TYPE_FIELD_NUMBER = 1; - private int type_; - /** - * - * - *
-   * The type of hash that was performed.
-   * 
- * - * .google.devtools.cloudbuild.v1.Hash.HashType type = 1; - * - * @return The enum numeric value on the wire for type. - */ - @java.lang.Override - public int getTypeValue() { - return type_; - } - /** - * - * - *
-   * The type of hash that was performed.
-   * 
- * - * .google.devtools.cloudbuild.v1.Hash.HashType type = 1; - * - * @return The type. - */ - @java.lang.Override - public com.google.cloudbuild.v1.Hash.HashType getType() { - @SuppressWarnings("deprecation") - com.google.cloudbuild.v1.Hash.HashType result = - com.google.cloudbuild.v1.Hash.HashType.valueOf(type_); - return result == null ? com.google.cloudbuild.v1.Hash.HashType.UNRECOGNIZED : result; - } - - public static final int VALUE_FIELD_NUMBER = 2; - private com.google.protobuf.ByteString value_; - /** - * - * - *
-   * The hash value.
-   * 
- * - * bytes value = 2; - * - * @return The value. - */ - @java.lang.Override - public com.google.protobuf.ByteString getValue() { - return value_; - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (type_ != com.google.cloudbuild.v1.Hash.HashType.NONE.getNumber()) { - output.writeEnum(1, type_); - } - if (!value_.isEmpty()) { - output.writeBytes(2, value_); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (type_ != com.google.cloudbuild.v1.Hash.HashType.NONE.getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, type_); - } - if (!value_.isEmpty()) { - size += com.google.protobuf.CodedOutputStream.computeBytesSize(2, value_); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.Hash)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.Hash other = (com.google.cloudbuild.v1.Hash) obj; - - if (type_ != other.type_) return false; - if (!getValue().equals(other.getValue())) return false; - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + TYPE_FIELD_NUMBER; - hash = (53 * hash) + type_; - hash = (37 * hash) + VALUE_FIELD_NUMBER; - hash = (53 * hash) + getValue().hashCode(); - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.Hash parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.Hash parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.Hash parseFrom(com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.Hash parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.Hash parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.Hash parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.Hash parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.Hash parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.Hash parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.Hash parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.Hash parseFrom(com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.Hash parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.Hash prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * Container message for hash values.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.Hash} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.Hash) - com.google.cloudbuild.v1.HashOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Hash_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Hash_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.Hash.class, com.google.cloudbuild.v1.Hash.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.Hash.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - type_ = 0; - - value_ = com.google.protobuf.ByteString.EMPTY; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Hash_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.Hash getDefaultInstanceForType() { - return com.google.cloudbuild.v1.Hash.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.Hash build() { - com.google.cloudbuild.v1.Hash result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.Hash buildPartial() { - com.google.cloudbuild.v1.Hash result = new com.google.cloudbuild.v1.Hash(this); - result.type_ = type_; - result.value_ = value_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.Hash) { - return mergeFrom((com.google.cloudbuild.v1.Hash) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.Hash other) { - if (other == com.google.cloudbuild.v1.Hash.getDefaultInstance()) return this; - if (other.type_ != 0) { - setTypeValue(other.getTypeValue()); - } - if (other.getValue() != com.google.protobuf.ByteString.EMPTY) { - setValue(other.getValue()); - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 8: - { - type_ = input.readEnum(); - - break; - } // case 8 - case 18: - { - value_ = input.readBytes(); - - break; - } // case 18 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private int type_ = 0; - /** - * - * - *
-     * The type of hash that was performed.
-     * 
- * - * .google.devtools.cloudbuild.v1.Hash.HashType type = 1; - * - * @return The enum numeric value on the wire for type. - */ - @java.lang.Override - public int getTypeValue() { - return type_; - } - /** - * - * - *
-     * The type of hash that was performed.
-     * 
- * - * .google.devtools.cloudbuild.v1.Hash.HashType type = 1; - * - * @param value The enum numeric value on the wire for type to set. - * @return This builder for chaining. - */ - public Builder setTypeValue(int value) { - - type_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The type of hash that was performed.
-     * 
- * - * .google.devtools.cloudbuild.v1.Hash.HashType type = 1; - * - * @return The type. - */ - @java.lang.Override - public com.google.cloudbuild.v1.Hash.HashType getType() { - @SuppressWarnings("deprecation") - com.google.cloudbuild.v1.Hash.HashType result = - com.google.cloudbuild.v1.Hash.HashType.valueOf(type_); - return result == null ? com.google.cloudbuild.v1.Hash.HashType.UNRECOGNIZED : result; - } - /** - * - * - *
-     * The type of hash that was performed.
-     * 
- * - * .google.devtools.cloudbuild.v1.Hash.HashType type = 1; - * - * @param value The type to set. - * @return This builder for chaining. - */ - public Builder setType(com.google.cloudbuild.v1.Hash.HashType value) { - if (value == null) { - throw new NullPointerException(); - } - - type_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-     * The type of hash that was performed.
-     * 
- * - * .google.devtools.cloudbuild.v1.Hash.HashType type = 1; - * - * @return This builder for chaining. - */ - public Builder clearType() { - - type_ = 0; - onChanged(); - return this; - } - - private com.google.protobuf.ByteString value_ = com.google.protobuf.ByteString.EMPTY; - /** - * - * - *
-     * The hash value.
-     * 
- * - * bytes value = 2; - * - * @return The value. - */ - @java.lang.Override - public com.google.protobuf.ByteString getValue() { - return value_; - } - /** - * - * - *
-     * The hash value.
-     * 
- * - * bytes value = 2; - * - * @param value The value to set. - * @return This builder for chaining. - */ - public Builder setValue(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - - value_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The hash value.
-     * 
- * - * bytes value = 2; - * - * @return This builder for chaining. - */ - public Builder clearValue() { - - value_ = getDefaultInstance().getValue(); - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.Hash) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.Hash) - private static final com.google.cloudbuild.v1.Hash DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.Hash(); - } - - public static com.google.cloudbuild.v1.Hash getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public Hash parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.Hash getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/HashOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/HashOrBuilder.java deleted file mode 100644 index 2d6cf46c..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/HashOrBuilder.java +++ /dev/null @@ -1,63 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface HashOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.Hash) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The type of hash that was performed.
-   * 
- * - * .google.devtools.cloudbuild.v1.Hash.HashType type = 1; - * - * @return The enum numeric value on the wire for type. - */ - int getTypeValue(); - /** - * - * - *
-   * The type of hash that was performed.
-   * 
- * - * .google.devtools.cloudbuild.v1.Hash.HashType type = 1; - * - * @return The type. - */ - com.google.cloudbuild.v1.Hash.HashType getType(); - - /** - * - * - *
-   * The hash value.
-   * 
- * - * bytes value = 2; - * - * @return The value. - */ - com.google.protobuf.ByteString getValue(); -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/InlineSecret.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/InlineSecret.java deleted file mode 100644 index c76b39ee..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/InlineSecret.java +++ /dev/null @@ -1,998 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * Pairs a set of secret environment variables mapped to encrypted
- * values with the Cloud KMS key to use to decrypt the value.
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.InlineSecret} - */ -public final class InlineSecret extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.InlineSecret) - InlineSecretOrBuilder { - private static final long serialVersionUID = 0L; - // Use InlineSecret.newBuilder() to construct. - private InlineSecret(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private InlineSecret() { - kmsKeyName_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new InlineSecret(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_InlineSecret_descriptor; - } - - @SuppressWarnings({"rawtypes"}) - @java.lang.Override - protected com.google.protobuf.MapField internalGetMapField(int number) { - switch (number) { - case 2: - return internalGetEnvMap(); - default: - throw new RuntimeException("Invalid map field number: " + number); - } - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_InlineSecret_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.InlineSecret.class, - com.google.cloudbuild.v1.InlineSecret.Builder.class); - } - - public static final int KMS_KEY_NAME_FIELD_NUMBER = 1; - private volatile java.lang.Object kmsKeyName_; - /** - * - * - *
-   * Resource name of Cloud KMS crypto key to decrypt the encrypted value.
-   * In format: projects/*/locations/*/keyRings/*/cryptoKeys/*
-   * 
- * - * string kms_key_name = 1 [(.google.api.resource_reference) = { ... } - * - * @return The kmsKeyName. - */ - @java.lang.Override - public java.lang.String getKmsKeyName() { - java.lang.Object ref = kmsKeyName_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - kmsKeyName_ = s; - return s; - } - } - /** - * - * - *
-   * Resource name of Cloud KMS crypto key to decrypt the encrypted value.
-   * In format: projects/*/locations/*/keyRings/*/cryptoKeys/*
-   * 
- * - * string kms_key_name = 1 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for kmsKeyName. - */ - @java.lang.Override - public com.google.protobuf.ByteString getKmsKeyNameBytes() { - java.lang.Object ref = kmsKeyName_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - kmsKeyName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int ENV_MAP_FIELD_NUMBER = 2; - - private static final class EnvMapDefaultEntryHolder { - static final com.google.protobuf.MapEntry - defaultEntry = - com.google.protobuf.MapEntry - .newDefaultInstance( - com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_InlineSecret_EnvMapEntry_descriptor, - com.google.protobuf.WireFormat.FieldType.STRING, - "", - com.google.protobuf.WireFormat.FieldType.BYTES, - com.google.protobuf.ByteString.EMPTY); - } - - private com.google.protobuf.MapField envMap_; - - private com.google.protobuf.MapField - internalGetEnvMap() { - if (envMap_ == null) { - return com.google.protobuf.MapField.emptyMapField(EnvMapDefaultEntryHolder.defaultEntry); - } - return envMap_; - } - - public int getEnvMapCount() { - return internalGetEnvMap().getMap().size(); - } - /** - * - * - *
-   * Map of environment variable name to its encrypted value.
-   * Secret environment variables must be unique across all of a build's
-   * secrets, and must be used by at least one build step. Values can be at most
-   * 64 KB in size. There can be at most 100 secret values across all of a
-   * build's secrets.
-   * 
- * - * map<string, bytes> env_map = 2; - */ - @java.lang.Override - public boolean containsEnvMap(java.lang.String key) { - if (key == null) { - throw new NullPointerException("map key"); - } - return internalGetEnvMap().getMap().containsKey(key); - } - /** Use {@link #getEnvMapMap()} instead. */ - @java.lang.Override - @java.lang.Deprecated - public java.util.Map getEnvMap() { - return getEnvMapMap(); - } - /** - * - * - *
-   * Map of environment variable name to its encrypted value.
-   * Secret environment variables must be unique across all of a build's
-   * secrets, and must be used by at least one build step. Values can be at most
-   * 64 KB in size. There can be at most 100 secret values across all of a
-   * build's secrets.
-   * 
- * - * map<string, bytes> env_map = 2; - */ - @java.lang.Override - public java.util.Map getEnvMapMap() { - return internalGetEnvMap().getMap(); - } - /** - * - * - *
-   * Map of environment variable name to its encrypted value.
-   * Secret environment variables must be unique across all of a build's
-   * secrets, and must be used by at least one build step. Values can be at most
-   * 64 KB in size. There can be at most 100 secret values across all of a
-   * build's secrets.
-   * 
- * - * map<string, bytes> env_map = 2; - */ - @java.lang.Override - public com.google.protobuf.ByteString getEnvMapOrDefault( - java.lang.String key, com.google.protobuf.ByteString defaultValue) { - if (key == null) { - throw new NullPointerException("map key"); - } - java.util.Map map = - internalGetEnvMap().getMap(); - return map.containsKey(key) ? map.get(key) : defaultValue; - } - /** - * - * - *
-   * Map of environment variable name to its encrypted value.
-   * Secret environment variables must be unique across all of a build's
-   * secrets, and must be used by at least one build step. Values can be at most
-   * 64 KB in size. There can be at most 100 secret values across all of a
-   * build's secrets.
-   * 
- * - * map<string, bytes> env_map = 2; - */ - @java.lang.Override - public com.google.protobuf.ByteString getEnvMapOrThrow(java.lang.String key) { - if (key == null) { - throw new NullPointerException("map key"); - } - java.util.Map map = - internalGetEnvMap().getMap(); - if (!map.containsKey(key)) { - throw new java.lang.IllegalArgumentException(); - } - return map.get(key); - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(kmsKeyName_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, kmsKeyName_); - } - com.google.protobuf.GeneratedMessageV3.serializeStringMapTo( - output, internalGetEnvMap(), EnvMapDefaultEntryHolder.defaultEntry, 2); - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(kmsKeyName_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, kmsKeyName_); - } - for (java.util.Map.Entry entry : - internalGetEnvMap().getMap().entrySet()) { - com.google.protobuf.MapEntry envMap__ = - EnvMapDefaultEntryHolder.defaultEntry - .newBuilderForType() - .setKey(entry.getKey()) - .setValue(entry.getValue()) - .build(); - size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, envMap__); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.InlineSecret)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.InlineSecret other = (com.google.cloudbuild.v1.InlineSecret) obj; - - if (!getKmsKeyName().equals(other.getKmsKeyName())) return false; - if (!internalGetEnvMap().equals(other.internalGetEnvMap())) return false; - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + KMS_KEY_NAME_FIELD_NUMBER; - hash = (53 * hash) + getKmsKeyName().hashCode(); - if (!internalGetEnvMap().getMap().isEmpty()) { - hash = (37 * hash) + ENV_MAP_FIELD_NUMBER; - hash = (53 * hash) + internalGetEnvMap().hashCode(); - } - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.InlineSecret parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.InlineSecret parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.InlineSecret parseFrom(com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.InlineSecret parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.InlineSecret parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.InlineSecret parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.InlineSecret parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.InlineSecret parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.InlineSecret parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.InlineSecret parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.InlineSecret parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.InlineSecret parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.InlineSecret prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * Pairs a set of secret environment variables mapped to encrypted
-   * values with the Cloud KMS key to use to decrypt the value.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.InlineSecret} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.InlineSecret) - com.google.cloudbuild.v1.InlineSecretOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_InlineSecret_descriptor; - } - - @SuppressWarnings({"rawtypes"}) - protected com.google.protobuf.MapField internalGetMapField(int number) { - switch (number) { - case 2: - return internalGetEnvMap(); - default: - throw new RuntimeException("Invalid map field number: " + number); - } - } - - @SuppressWarnings({"rawtypes"}) - protected com.google.protobuf.MapField internalGetMutableMapField(int number) { - switch (number) { - case 2: - return internalGetMutableEnvMap(); - default: - throw new RuntimeException("Invalid map field number: " + number); - } - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_InlineSecret_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.InlineSecret.class, - com.google.cloudbuild.v1.InlineSecret.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.InlineSecret.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - kmsKeyName_ = ""; - - internalGetMutableEnvMap().clear(); - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_InlineSecret_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.InlineSecret getDefaultInstanceForType() { - return com.google.cloudbuild.v1.InlineSecret.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.InlineSecret build() { - com.google.cloudbuild.v1.InlineSecret result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.InlineSecret buildPartial() { - com.google.cloudbuild.v1.InlineSecret result = - new com.google.cloudbuild.v1.InlineSecret(this); - int from_bitField0_ = bitField0_; - result.kmsKeyName_ = kmsKeyName_; - result.envMap_ = internalGetEnvMap(); - result.envMap_.makeImmutable(); - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.InlineSecret) { - return mergeFrom((com.google.cloudbuild.v1.InlineSecret) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.InlineSecret other) { - if (other == com.google.cloudbuild.v1.InlineSecret.getDefaultInstance()) return this; - if (!other.getKmsKeyName().isEmpty()) { - kmsKeyName_ = other.kmsKeyName_; - onChanged(); - } - internalGetMutableEnvMap().mergeFrom(other.internalGetEnvMap()); - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - kmsKeyName_ = input.readStringRequireUtf8(); - - break; - } // case 10 - case 18: - { - com.google.protobuf.MapEntry - envMap__ = - input.readMessage( - EnvMapDefaultEntryHolder.defaultEntry.getParserForType(), - extensionRegistry); - internalGetMutableEnvMap() - .getMutableMap() - .put(envMap__.getKey(), envMap__.getValue()); - break; - } // case 18 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private int bitField0_; - - private java.lang.Object kmsKeyName_ = ""; - /** - * - * - *
-     * Resource name of Cloud KMS crypto key to decrypt the encrypted value.
-     * In format: projects/*/locations/*/keyRings/*/cryptoKeys/*
-     * 
- * - * string kms_key_name = 1 [(.google.api.resource_reference) = { ... } - * - * @return The kmsKeyName. - */ - public java.lang.String getKmsKeyName() { - java.lang.Object ref = kmsKeyName_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - kmsKeyName_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Resource name of Cloud KMS crypto key to decrypt the encrypted value.
-     * In format: projects/*/locations/*/keyRings/*/cryptoKeys/*
-     * 
- * - * string kms_key_name = 1 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for kmsKeyName. - */ - public com.google.protobuf.ByteString getKmsKeyNameBytes() { - java.lang.Object ref = kmsKeyName_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - kmsKeyName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Resource name of Cloud KMS crypto key to decrypt the encrypted value.
-     * In format: projects/*/locations/*/keyRings/*/cryptoKeys/*
-     * 
- * - * string kms_key_name = 1 [(.google.api.resource_reference) = { ... } - * - * @param value The kmsKeyName to set. - * @return This builder for chaining. - */ - public Builder setKmsKeyName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - kmsKeyName_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Resource name of Cloud KMS crypto key to decrypt the encrypted value.
-     * In format: projects/*/locations/*/keyRings/*/cryptoKeys/*
-     * 
- * - * string kms_key_name = 1 [(.google.api.resource_reference) = { ... } - * - * @return This builder for chaining. - */ - public Builder clearKmsKeyName() { - - kmsKeyName_ = getDefaultInstance().getKmsKeyName(); - onChanged(); - return this; - } - /** - * - * - *
-     * Resource name of Cloud KMS crypto key to decrypt the encrypted value.
-     * In format: projects/*/locations/*/keyRings/*/cryptoKeys/*
-     * 
- * - * string kms_key_name = 1 [(.google.api.resource_reference) = { ... } - * - * @param value The bytes for kmsKeyName to set. - * @return This builder for chaining. - */ - public Builder setKmsKeyNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - kmsKeyName_ = value; - onChanged(); - return this; - } - - private com.google.protobuf.MapField envMap_; - - private com.google.protobuf.MapField - internalGetEnvMap() { - if (envMap_ == null) { - return com.google.protobuf.MapField.emptyMapField(EnvMapDefaultEntryHolder.defaultEntry); - } - return envMap_; - } - - private com.google.protobuf.MapField - internalGetMutableEnvMap() { - onChanged(); - ; - if (envMap_ == null) { - envMap_ = com.google.protobuf.MapField.newMapField(EnvMapDefaultEntryHolder.defaultEntry); - } - if (!envMap_.isMutable()) { - envMap_ = envMap_.copy(); - } - return envMap_; - } - - public int getEnvMapCount() { - return internalGetEnvMap().getMap().size(); - } - /** - * - * - *
-     * Map of environment variable name to its encrypted value.
-     * Secret environment variables must be unique across all of a build's
-     * secrets, and must be used by at least one build step. Values can be at most
-     * 64 KB in size. There can be at most 100 secret values across all of a
-     * build's secrets.
-     * 
- * - * map<string, bytes> env_map = 2; - */ - @java.lang.Override - public boolean containsEnvMap(java.lang.String key) { - if (key == null) { - throw new NullPointerException("map key"); - } - return internalGetEnvMap().getMap().containsKey(key); - } - /** Use {@link #getEnvMapMap()} instead. */ - @java.lang.Override - @java.lang.Deprecated - public java.util.Map getEnvMap() { - return getEnvMapMap(); - } - /** - * - * - *
-     * Map of environment variable name to its encrypted value.
-     * Secret environment variables must be unique across all of a build's
-     * secrets, and must be used by at least one build step. Values can be at most
-     * 64 KB in size. There can be at most 100 secret values across all of a
-     * build's secrets.
-     * 
- * - * map<string, bytes> env_map = 2; - */ - @java.lang.Override - public java.util.Map getEnvMapMap() { - return internalGetEnvMap().getMap(); - } - /** - * - * - *
-     * Map of environment variable name to its encrypted value.
-     * Secret environment variables must be unique across all of a build's
-     * secrets, and must be used by at least one build step. Values can be at most
-     * 64 KB in size. There can be at most 100 secret values across all of a
-     * build's secrets.
-     * 
- * - * map<string, bytes> env_map = 2; - */ - @java.lang.Override - public com.google.protobuf.ByteString getEnvMapOrDefault( - java.lang.String key, com.google.protobuf.ByteString defaultValue) { - if (key == null) { - throw new NullPointerException("map key"); - } - java.util.Map map = - internalGetEnvMap().getMap(); - return map.containsKey(key) ? map.get(key) : defaultValue; - } - /** - * - * - *
-     * Map of environment variable name to its encrypted value.
-     * Secret environment variables must be unique across all of a build's
-     * secrets, and must be used by at least one build step. Values can be at most
-     * 64 KB in size. There can be at most 100 secret values across all of a
-     * build's secrets.
-     * 
- * - * map<string, bytes> env_map = 2; - */ - @java.lang.Override - public com.google.protobuf.ByteString getEnvMapOrThrow(java.lang.String key) { - if (key == null) { - throw new NullPointerException("map key"); - } - java.util.Map map = - internalGetEnvMap().getMap(); - if (!map.containsKey(key)) { - throw new java.lang.IllegalArgumentException(); - } - return map.get(key); - } - - public Builder clearEnvMap() { - internalGetMutableEnvMap().getMutableMap().clear(); - return this; - } - /** - * - * - *
-     * Map of environment variable name to its encrypted value.
-     * Secret environment variables must be unique across all of a build's
-     * secrets, and must be used by at least one build step. Values can be at most
-     * 64 KB in size. There can be at most 100 secret values across all of a
-     * build's secrets.
-     * 
- * - * map<string, bytes> env_map = 2; - */ - public Builder removeEnvMap(java.lang.String key) { - if (key == null) { - throw new NullPointerException("map key"); - } - internalGetMutableEnvMap().getMutableMap().remove(key); - return this; - } - /** Use alternate mutation accessors instead. */ - @java.lang.Deprecated - public java.util.Map getMutableEnvMap() { - return internalGetMutableEnvMap().getMutableMap(); - } - /** - * - * - *
-     * Map of environment variable name to its encrypted value.
-     * Secret environment variables must be unique across all of a build's
-     * secrets, and must be used by at least one build step. Values can be at most
-     * 64 KB in size. There can be at most 100 secret values across all of a
-     * build's secrets.
-     * 
- * - * map<string, bytes> env_map = 2; - */ - public Builder putEnvMap(java.lang.String key, com.google.protobuf.ByteString value) { - if (key == null) { - throw new NullPointerException("map key"); - } - if (value == null) { - throw new NullPointerException("map value"); - } - - internalGetMutableEnvMap().getMutableMap().put(key, value); - return this; - } - /** - * - * - *
-     * Map of environment variable name to its encrypted value.
-     * Secret environment variables must be unique across all of a build's
-     * secrets, and must be used by at least one build step. Values can be at most
-     * 64 KB in size. There can be at most 100 secret values across all of a
-     * build's secrets.
-     * 
- * - * map<string, bytes> env_map = 2; - */ - public Builder putAllEnvMap( - java.util.Map values) { - internalGetMutableEnvMap().getMutableMap().putAll(values); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.InlineSecret) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.InlineSecret) - private static final com.google.cloudbuild.v1.InlineSecret DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.InlineSecret(); - } - - public static com.google.cloudbuild.v1.InlineSecret getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public InlineSecret parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.InlineSecret getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/InlineSecretOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/InlineSecretOrBuilder.java deleted file mode 100644 index cf0afe5b..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/InlineSecretOrBuilder.java +++ /dev/null @@ -1,131 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface InlineSecretOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.InlineSecret) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * Resource name of Cloud KMS crypto key to decrypt the encrypted value.
-   * In format: projects/*/locations/*/keyRings/*/cryptoKeys/*
-   * 
- * - * string kms_key_name = 1 [(.google.api.resource_reference) = { ... } - * - * @return The kmsKeyName. - */ - java.lang.String getKmsKeyName(); - /** - * - * - *
-   * Resource name of Cloud KMS crypto key to decrypt the encrypted value.
-   * In format: projects/*/locations/*/keyRings/*/cryptoKeys/*
-   * 
- * - * string kms_key_name = 1 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for kmsKeyName. - */ - com.google.protobuf.ByteString getKmsKeyNameBytes(); - - /** - * - * - *
-   * Map of environment variable name to its encrypted value.
-   * Secret environment variables must be unique across all of a build's
-   * secrets, and must be used by at least one build step. Values can be at most
-   * 64 KB in size. There can be at most 100 secret values across all of a
-   * build's secrets.
-   * 
- * - * map<string, bytes> env_map = 2; - */ - int getEnvMapCount(); - /** - * - * - *
-   * Map of environment variable name to its encrypted value.
-   * Secret environment variables must be unique across all of a build's
-   * secrets, and must be used by at least one build step. Values can be at most
-   * 64 KB in size. There can be at most 100 secret values across all of a
-   * build's secrets.
-   * 
- * - * map<string, bytes> env_map = 2; - */ - boolean containsEnvMap(java.lang.String key); - /** Use {@link #getEnvMapMap()} instead. */ - @java.lang.Deprecated - java.util.Map getEnvMap(); - /** - * - * - *
-   * Map of environment variable name to its encrypted value.
-   * Secret environment variables must be unique across all of a build's
-   * secrets, and must be used by at least one build step. Values can be at most
-   * 64 KB in size. There can be at most 100 secret values across all of a
-   * build's secrets.
-   * 
- * - * map<string, bytes> env_map = 2; - */ - java.util.Map getEnvMapMap(); - /** - * - * - *
-   * Map of environment variable name to its encrypted value.
-   * Secret environment variables must be unique across all of a build's
-   * secrets, and must be used by at least one build step. Values can be at most
-   * 64 KB in size. There can be at most 100 secret values across all of a
-   * build's secrets.
-   * 
- * - * map<string, bytes> env_map = 2; - */ - - /* nullable */ - com.google.protobuf.ByteString getEnvMapOrDefault( - java.lang.String key, - /* nullable */ - com.google.protobuf.ByteString defaultValue); - /** - * - * - *
-   * Map of environment variable name to its encrypted value.
-   * Secret environment variables must be unique across all of a build's
-   * secrets, and must be used by at least one build step. Values can be at most
-   * 64 KB in size. There can be at most 100 secret values across all of a
-   * build's secrets.
-   * 
- * - * map<string, bytes> env_map = 2; - */ - com.google.protobuf.ByteString getEnvMapOrThrow(java.lang.String key); -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildTriggersRequest.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildTriggersRequest.java deleted file mode 100644 index dc2fafad..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildTriggersRequest.java +++ /dev/null @@ -1,1069 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * Request to list existing `BuildTriggers`.
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.ListBuildTriggersRequest} - */ -public final class ListBuildTriggersRequest extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.ListBuildTriggersRequest) - ListBuildTriggersRequestOrBuilder { - private static final long serialVersionUID = 0L; - // Use ListBuildTriggersRequest.newBuilder() to construct. - private ListBuildTriggersRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private ListBuildTriggersRequest() { - parent_ = ""; - projectId_ = ""; - pageToken_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new ListBuildTriggersRequest(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ListBuildTriggersRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ListBuildTriggersRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.ListBuildTriggersRequest.class, - com.google.cloudbuild.v1.ListBuildTriggersRequest.Builder.class); - } - - public static final int PARENT_FIELD_NUMBER = 4; - private volatile java.lang.Object parent_; - /** - * - * - *
-   * The parent of the collection of `Triggers`.
-   * Format: `projects/{project}/locations/{location}`
-   * 
- * - * string parent = 4 [(.google.api.resource_reference) = { ... } - * - * @return The parent. - */ - @java.lang.Override - public java.lang.String getParent() { - java.lang.Object ref = parent_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - parent_ = s; - return s; - } - } - /** - * - * - *
-   * The parent of the collection of `Triggers`.
-   * Format: `projects/{project}/locations/{location}`
-   * 
- * - * string parent = 4 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for parent. - */ - @java.lang.Override - public com.google.protobuf.ByteString getParentBytes() { - java.lang.Object ref = parent_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - parent_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int PROJECT_ID_FIELD_NUMBER = 1; - private volatile java.lang.Object projectId_; - /** - * - * - *
-   * Required. ID of the project for which to list BuildTriggers.
-   * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The projectId. - */ - @java.lang.Override - public java.lang.String getProjectId() { - java.lang.Object ref = projectId_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - projectId_ = s; - return s; - } - } - /** - * - * - *
-   * Required. ID of the project for which to list BuildTriggers.
-   * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for projectId. - */ - @java.lang.Override - public com.google.protobuf.ByteString getProjectIdBytes() { - java.lang.Object ref = projectId_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - projectId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int PAGE_SIZE_FIELD_NUMBER = 2; - private int pageSize_; - /** - * - * - *
-   * Number of results to return in the list.
-   * 
- * - * int32 page_size = 2; - * - * @return The pageSize. - */ - @java.lang.Override - public int getPageSize() { - return pageSize_; - } - - public static final int PAGE_TOKEN_FIELD_NUMBER = 3; - private volatile java.lang.Object pageToken_; - /** - * - * - *
-   * Token to provide to skip to a particular spot in the list.
-   * 
- * - * string page_token = 3; - * - * @return The pageToken. - */ - @java.lang.Override - public java.lang.String getPageToken() { - java.lang.Object ref = pageToken_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - pageToken_ = s; - return s; - } - } - /** - * - * - *
-   * Token to provide to skip to a particular spot in the list.
-   * 
- * - * string page_token = 3; - * - * @return The bytes for pageToken. - */ - @java.lang.Override - public com.google.protobuf.ByteString getPageTokenBytes() { - java.lang.Object ref = pageToken_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - pageToken_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(projectId_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, projectId_); - } - if (pageSize_ != 0) { - output.writeInt32(2, pageSize_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(pageToken_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 3, pageToken_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 4, parent_); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(projectId_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, projectId_); - } - if (pageSize_ != 0) { - size += com.google.protobuf.CodedOutputStream.computeInt32Size(2, pageSize_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(pageToken_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, pageToken_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, parent_); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.ListBuildTriggersRequest)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.ListBuildTriggersRequest other = - (com.google.cloudbuild.v1.ListBuildTriggersRequest) obj; - - if (!getParent().equals(other.getParent())) return false; - if (!getProjectId().equals(other.getProjectId())) return false; - if (getPageSize() != other.getPageSize()) return false; - if (!getPageToken().equals(other.getPageToken())) return false; - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + PARENT_FIELD_NUMBER; - hash = (53 * hash) + getParent().hashCode(); - hash = (37 * hash) + PROJECT_ID_FIELD_NUMBER; - hash = (53 * hash) + getProjectId().hashCode(); - hash = (37 * hash) + PAGE_SIZE_FIELD_NUMBER; - hash = (53 * hash) + getPageSize(); - hash = (37 * hash) + PAGE_TOKEN_FIELD_NUMBER; - hash = (53 * hash) + getPageToken().hashCode(); - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.ListBuildTriggersRequest parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.ListBuildTriggersRequest parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ListBuildTriggersRequest parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.ListBuildTriggersRequest parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ListBuildTriggersRequest parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.ListBuildTriggersRequest parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ListBuildTriggersRequest parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.ListBuildTriggersRequest parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ListBuildTriggersRequest parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.ListBuildTriggersRequest parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ListBuildTriggersRequest parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.ListBuildTriggersRequest parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.ListBuildTriggersRequest prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * Request to list existing `BuildTriggers`.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.ListBuildTriggersRequest} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.ListBuildTriggersRequest) - com.google.cloudbuild.v1.ListBuildTriggersRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ListBuildTriggersRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ListBuildTriggersRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.ListBuildTriggersRequest.class, - com.google.cloudbuild.v1.ListBuildTriggersRequest.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.ListBuildTriggersRequest.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - parent_ = ""; - - projectId_ = ""; - - pageSize_ = 0; - - pageToken_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ListBuildTriggersRequest_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.ListBuildTriggersRequest getDefaultInstanceForType() { - return com.google.cloudbuild.v1.ListBuildTriggersRequest.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.ListBuildTriggersRequest build() { - com.google.cloudbuild.v1.ListBuildTriggersRequest result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.ListBuildTriggersRequest buildPartial() { - com.google.cloudbuild.v1.ListBuildTriggersRequest result = - new com.google.cloudbuild.v1.ListBuildTriggersRequest(this); - result.parent_ = parent_; - result.projectId_ = projectId_; - result.pageSize_ = pageSize_; - result.pageToken_ = pageToken_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.ListBuildTriggersRequest) { - return mergeFrom((com.google.cloudbuild.v1.ListBuildTriggersRequest) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.ListBuildTriggersRequest other) { - if (other == com.google.cloudbuild.v1.ListBuildTriggersRequest.getDefaultInstance()) - return this; - if (!other.getParent().isEmpty()) { - parent_ = other.parent_; - onChanged(); - } - if (!other.getProjectId().isEmpty()) { - projectId_ = other.projectId_; - onChanged(); - } - if (other.getPageSize() != 0) { - setPageSize(other.getPageSize()); - } - if (!other.getPageToken().isEmpty()) { - pageToken_ = other.pageToken_; - onChanged(); - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - projectId_ = input.readStringRequireUtf8(); - - break; - } // case 10 - case 16: - { - pageSize_ = input.readInt32(); - - break; - } // case 16 - case 26: - { - pageToken_ = input.readStringRequireUtf8(); - - break; - } // case 26 - case 34: - { - parent_ = input.readStringRequireUtf8(); - - break; - } // case 34 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private java.lang.Object parent_ = ""; - /** - * - * - *
-     * The parent of the collection of `Triggers`.
-     * Format: `projects/{project}/locations/{location}`
-     * 
- * - * string parent = 4 [(.google.api.resource_reference) = { ... } - * - * @return The parent. - */ - public java.lang.String getParent() { - java.lang.Object ref = parent_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - parent_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * The parent of the collection of `Triggers`.
-     * Format: `projects/{project}/locations/{location}`
-     * 
- * - * string parent = 4 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for parent. - */ - public com.google.protobuf.ByteString getParentBytes() { - java.lang.Object ref = parent_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - parent_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * The parent of the collection of `Triggers`.
-     * Format: `projects/{project}/locations/{location}`
-     * 
- * - * string parent = 4 [(.google.api.resource_reference) = { ... } - * - * @param value The parent to set. - * @return This builder for chaining. - */ - public Builder setParent(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - parent_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The parent of the collection of `Triggers`.
-     * Format: `projects/{project}/locations/{location}`
-     * 
- * - * string parent = 4 [(.google.api.resource_reference) = { ... } - * - * @return This builder for chaining. - */ - public Builder clearParent() { - - parent_ = getDefaultInstance().getParent(); - onChanged(); - return this; - } - /** - * - * - *
-     * The parent of the collection of `Triggers`.
-     * Format: `projects/{project}/locations/{location}`
-     * 
- * - * string parent = 4 [(.google.api.resource_reference) = { ... } - * - * @param value The bytes for parent to set. - * @return This builder for chaining. - */ - public Builder setParentBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - parent_ = value; - onChanged(); - return this; - } - - private java.lang.Object projectId_ = ""; - /** - * - * - *
-     * Required. ID of the project for which to list BuildTriggers.
-     * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The projectId. - */ - public java.lang.String getProjectId() { - java.lang.Object ref = projectId_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - projectId_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Required. ID of the project for which to list BuildTriggers.
-     * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for projectId. - */ - public com.google.protobuf.ByteString getProjectIdBytes() { - java.lang.Object ref = projectId_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - projectId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Required. ID of the project for which to list BuildTriggers.
-     * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @param value The projectId to set. - * @return This builder for chaining. - */ - public Builder setProjectId(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - projectId_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Required. ID of the project for which to list BuildTriggers.
-     * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return This builder for chaining. - */ - public Builder clearProjectId() { - - projectId_ = getDefaultInstance().getProjectId(); - onChanged(); - return this; - } - /** - * - * - *
-     * Required. ID of the project for which to list BuildTriggers.
-     * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @param value The bytes for projectId to set. - * @return This builder for chaining. - */ - public Builder setProjectIdBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - projectId_ = value; - onChanged(); - return this; - } - - private int pageSize_; - /** - * - * - *
-     * Number of results to return in the list.
-     * 
- * - * int32 page_size = 2; - * - * @return The pageSize. - */ - @java.lang.Override - public int getPageSize() { - return pageSize_; - } - /** - * - * - *
-     * Number of results to return in the list.
-     * 
- * - * int32 page_size = 2; - * - * @param value The pageSize to set. - * @return This builder for chaining. - */ - public Builder setPageSize(int value) { - - pageSize_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Number of results to return in the list.
-     * 
- * - * int32 page_size = 2; - * - * @return This builder for chaining. - */ - public Builder clearPageSize() { - - pageSize_ = 0; - onChanged(); - return this; - } - - private java.lang.Object pageToken_ = ""; - /** - * - * - *
-     * Token to provide to skip to a particular spot in the list.
-     * 
- * - * string page_token = 3; - * - * @return The pageToken. - */ - public java.lang.String getPageToken() { - java.lang.Object ref = pageToken_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - pageToken_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Token to provide to skip to a particular spot in the list.
-     * 
- * - * string page_token = 3; - * - * @return The bytes for pageToken. - */ - public com.google.protobuf.ByteString getPageTokenBytes() { - java.lang.Object ref = pageToken_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - pageToken_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Token to provide to skip to a particular spot in the list.
-     * 
- * - * string page_token = 3; - * - * @param value The pageToken to set. - * @return This builder for chaining. - */ - public Builder setPageToken(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - pageToken_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Token to provide to skip to a particular spot in the list.
-     * 
- * - * string page_token = 3; - * - * @return This builder for chaining. - */ - public Builder clearPageToken() { - - pageToken_ = getDefaultInstance().getPageToken(); - onChanged(); - return this; - } - /** - * - * - *
-     * Token to provide to skip to a particular spot in the list.
-     * 
- * - * string page_token = 3; - * - * @param value The bytes for pageToken to set. - * @return This builder for chaining. - */ - public Builder setPageTokenBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - pageToken_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.ListBuildTriggersRequest) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.ListBuildTriggersRequest) - private static final com.google.cloudbuild.v1.ListBuildTriggersRequest DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.ListBuildTriggersRequest(); - } - - public static com.google.cloudbuild.v1.ListBuildTriggersRequest getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public ListBuildTriggersRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.ListBuildTriggersRequest getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildTriggersRequestOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildTriggersRequestOrBuilder.java deleted file mode 100644 index 5d85bc1f..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildTriggersRequestOrBuilder.java +++ /dev/null @@ -1,115 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface ListBuildTriggersRequestOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.ListBuildTriggersRequest) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The parent of the collection of `Triggers`.
-   * Format: `projects/{project}/locations/{location}`
-   * 
- * - * string parent = 4 [(.google.api.resource_reference) = { ... } - * - * @return The parent. - */ - java.lang.String getParent(); - /** - * - * - *
-   * The parent of the collection of `Triggers`.
-   * Format: `projects/{project}/locations/{location}`
-   * 
- * - * string parent = 4 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for parent. - */ - com.google.protobuf.ByteString getParentBytes(); - - /** - * - * - *
-   * Required. ID of the project for which to list BuildTriggers.
-   * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The projectId. - */ - java.lang.String getProjectId(); - /** - * - * - *
-   * Required. ID of the project for which to list BuildTriggers.
-   * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for projectId. - */ - com.google.protobuf.ByteString getProjectIdBytes(); - - /** - * - * - *
-   * Number of results to return in the list.
-   * 
- * - * int32 page_size = 2; - * - * @return The pageSize. - */ - int getPageSize(); - - /** - * - * - *
-   * Token to provide to skip to a particular spot in the list.
-   * 
- * - * string page_token = 3; - * - * @return The pageToken. - */ - java.lang.String getPageToken(); - /** - * - * - *
-   * Token to provide to skip to a particular spot in the list.
-   * 
- * - * string page_token = 3; - * - * @return The bytes for pageToken. - */ - com.google.protobuf.ByteString getPageTokenBytes(); -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildTriggersResponse.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildTriggersResponse.java deleted file mode 100644 index b554bd7d..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildTriggersResponse.java +++ /dev/null @@ -1,1103 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * Response containing existing `BuildTriggers`.
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.ListBuildTriggersResponse} - */ -public final class ListBuildTriggersResponse extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.ListBuildTriggersResponse) - ListBuildTriggersResponseOrBuilder { - private static final long serialVersionUID = 0L; - // Use ListBuildTriggersResponse.newBuilder() to construct. - private ListBuildTriggersResponse(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private ListBuildTriggersResponse() { - triggers_ = java.util.Collections.emptyList(); - nextPageToken_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new ListBuildTriggersResponse(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ListBuildTriggersResponse_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ListBuildTriggersResponse_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.ListBuildTriggersResponse.class, - com.google.cloudbuild.v1.ListBuildTriggersResponse.Builder.class); - } - - public static final int TRIGGERS_FIELD_NUMBER = 1; - private java.util.List triggers_; - /** - * - * - *
-   * `BuildTriggers` for the project, sorted by `create_time` descending.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildTrigger triggers = 1; - */ - @java.lang.Override - public java.util.List getTriggersList() { - return triggers_; - } - /** - * - * - *
-   * `BuildTriggers` for the project, sorted by `create_time` descending.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildTrigger triggers = 1; - */ - @java.lang.Override - public java.util.List - getTriggersOrBuilderList() { - return triggers_; - } - /** - * - * - *
-   * `BuildTriggers` for the project, sorted by `create_time` descending.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildTrigger triggers = 1; - */ - @java.lang.Override - public int getTriggersCount() { - return triggers_.size(); - } - /** - * - * - *
-   * `BuildTriggers` for the project, sorted by `create_time` descending.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildTrigger triggers = 1; - */ - @java.lang.Override - public com.google.cloudbuild.v1.BuildTrigger getTriggers(int index) { - return triggers_.get(index); - } - /** - * - * - *
-   * `BuildTriggers` for the project, sorted by `create_time` descending.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildTrigger triggers = 1; - */ - @java.lang.Override - public com.google.cloudbuild.v1.BuildTriggerOrBuilder getTriggersOrBuilder(int index) { - return triggers_.get(index); - } - - public static final int NEXT_PAGE_TOKEN_FIELD_NUMBER = 2; - private volatile java.lang.Object nextPageToken_; - /** - * - * - *
-   * Token to receive the next page of results.
-   * 
- * - * string next_page_token = 2; - * - * @return The nextPageToken. - */ - @java.lang.Override - public java.lang.String getNextPageToken() { - java.lang.Object ref = nextPageToken_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - nextPageToken_ = s; - return s; - } - } - /** - * - * - *
-   * Token to receive the next page of results.
-   * 
- * - * string next_page_token = 2; - * - * @return The bytes for nextPageToken. - */ - @java.lang.Override - public com.google.protobuf.ByteString getNextPageTokenBytes() { - java.lang.Object ref = nextPageToken_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - nextPageToken_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - for (int i = 0; i < triggers_.size(); i++) { - output.writeMessage(1, triggers_.get(i)); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(nextPageToken_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, nextPageToken_); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - for (int i = 0; i < triggers_.size(); i++) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, triggers_.get(i)); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(nextPageToken_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, nextPageToken_); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.ListBuildTriggersResponse)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.ListBuildTriggersResponse other = - (com.google.cloudbuild.v1.ListBuildTriggersResponse) obj; - - if (!getTriggersList().equals(other.getTriggersList())) return false; - if (!getNextPageToken().equals(other.getNextPageToken())) return false; - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (getTriggersCount() > 0) { - hash = (37 * hash) + TRIGGERS_FIELD_NUMBER; - hash = (53 * hash) + getTriggersList().hashCode(); - } - hash = (37 * hash) + NEXT_PAGE_TOKEN_FIELD_NUMBER; - hash = (53 * hash) + getNextPageToken().hashCode(); - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.ListBuildTriggersResponse parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.ListBuildTriggersResponse parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ListBuildTriggersResponse parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.ListBuildTriggersResponse parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ListBuildTriggersResponse parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.ListBuildTriggersResponse parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ListBuildTriggersResponse parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.ListBuildTriggersResponse parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ListBuildTriggersResponse parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.ListBuildTriggersResponse parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ListBuildTriggersResponse parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.ListBuildTriggersResponse parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.ListBuildTriggersResponse prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * Response containing existing `BuildTriggers`.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.ListBuildTriggersResponse} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.ListBuildTriggersResponse) - com.google.cloudbuild.v1.ListBuildTriggersResponseOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ListBuildTriggersResponse_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ListBuildTriggersResponse_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.ListBuildTriggersResponse.class, - com.google.cloudbuild.v1.ListBuildTriggersResponse.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.ListBuildTriggersResponse.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - if (triggersBuilder_ == null) { - triggers_ = java.util.Collections.emptyList(); - } else { - triggers_ = null; - triggersBuilder_.clear(); - } - bitField0_ = (bitField0_ & ~0x00000001); - nextPageToken_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ListBuildTriggersResponse_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.ListBuildTriggersResponse getDefaultInstanceForType() { - return com.google.cloudbuild.v1.ListBuildTriggersResponse.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.ListBuildTriggersResponse build() { - com.google.cloudbuild.v1.ListBuildTriggersResponse result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.ListBuildTriggersResponse buildPartial() { - com.google.cloudbuild.v1.ListBuildTriggersResponse result = - new com.google.cloudbuild.v1.ListBuildTriggersResponse(this); - int from_bitField0_ = bitField0_; - if (triggersBuilder_ == null) { - if (((bitField0_ & 0x00000001) != 0)) { - triggers_ = java.util.Collections.unmodifiableList(triggers_); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.triggers_ = triggers_; - } else { - result.triggers_ = triggersBuilder_.build(); - } - result.nextPageToken_ = nextPageToken_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.ListBuildTriggersResponse) { - return mergeFrom((com.google.cloudbuild.v1.ListBuildTriggersResponse) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.ListBuildTriggersResponse other) { - if (other == com.google.cloudbuild.v1.ListBuildTriggersResponse.getDefaultInstance()) - return this; - if (triggersBuilder_ == null) { - if (!other.triggers_.isEmpty()) { - if (triggers_.isEmpty()) { - triggers_ = other.triggers_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureTriggersIsMutable(); - triggers_.addAll(other.triggers_); - } - onChanged(); - } - } else { - if (!other.triggers_.isEmpty()) { - if (triggersBuilder_.isEmpty()) { - triggersBuilder_.dispose(); - triggersBuilder_ = null; - triggers_ = other.triggers_; - bitField0_ = (bitField0_ & ~0x00000001); - triggersBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders - ? getTriggersFieldBuilder() - : null; - } else { - triggersBuilder_.addAllMessages(other.triggers_); - } - } - } - if (!other.getNextPageToken().isEmpty()) { - nextPageToken_ = other.nextPageToken_; - onChanged(); - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - com.google.cloudbuild.v1.BuildTrigger m = - input.readMessage( - com.google.cloudbuild.v1.BuildTrigger.parser(), extensionRegistry); - if (triggersBuilder_ == null) { - ensureTriggersIsMutable(); - triggers_.add(m); - } else { - triggersBuilder_.addMessage(m); - } - break; - } // case 10 - case 18: - { - nextPageToken_ = input.readStringRequireUtf8(); - - break; - } // case 18 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private int bitField0_; - - private java.util.List triggers_ = - java.util.Collections.emptyList(); - - private void ensureTriggersIsMutable() { - if (!((bitField0_ & 0x00000001) != 0)) { - triggers_ = new java.util.ArrayList(triggers_); - bitField0_ |= 0x00000001; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloudbuild.v1.BuildTrigger, - com.google.cloudbuild.v1.BuildTrigger.Builder, - com.google.cloudbuild.v1.BuildTriggerOrBuilder> - triggersBuilder_; - - /** - * - * - *
-     * `BuildTriggers` for the project, sorted by `create_time` descending.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildTrigger triggers = 1; - */ - public java.util.List getTriggersList() { - if (triggersBuilder_ == null) { - return java.util.Collections.unmodifiableList(triggers_); - } else { - return triggersBuilder_.getMessageList(); - } - } - /** - * - * - *
-     * `BuildTriggers` for the project, sorted by `create_time` descending.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildTrigger triggers = 1; - */ - public int getTriggersCount() { - if (triggersBuilder_ == null) { - return triggers_.size(); - } else { - return triggersBuilder_.getCount(); - } - } - /** - * - * - *
-     * `BuildTriggers` for the project, sorted by `create_time` descending.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildTrigger triggers = 1; - */ - public com.google.cloudbuild.v1.BuildTrigger getTriggers(int index) { - if (triggersBuilder_ == null) { - return triggers_.get(index); - } else { - return triggersBuilder_.getMessage(index); - } - } - /** - * - * - *
-     * `BuildTriggers` for the project, sorted by `create_time` descending.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildTrigger triggers = 1; - */ - public Builder setTriggers(int index, com.google.cloudbuild.v1.BuildTrigger value) { - if (triggersBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureTriggersIsMutable(); - triggers_.set(index, value); - onChanged(); - } else { - triggersBuilder_.setMessage(index, value); - } - return this; - } - /** - * - * - *
-     * `BuildTriggers` for the project, sorted by `create_time` descending.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildTrigger triggers = 1; - */ - public Builder setTriggers( - int index, com.google.cloudbuild.v1.BuildTrigger.Builder builderForValue) { - if (triggersBuilder_ == null) { - ensureTriggersIsMutable(); - triggers_.set(index, builderForValue.build()); - onChanged(); - } else { - triggersBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * `BuildTriggers` for the project, sorted by `create_time` descending.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildTrigger triggers = 1; - */ - public Builder addTriggers(com.google.cloudbuild.v1.BuildTrigger value) { - if (triggersBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureTriggersIsMutable(); - triggers_.add(value); - onChanged(); - } else { - triggersBuilder_.addMessage(value); - } - return this; - } - /** - * - * - *
-     * `BuildTriggers` for the project, sorted by `create_time` descending.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildTrigger triggers = 1; - */ - public Builder addTriggers(int index, com.google.cloudbuild.v1.BuildTrigger value) { - if (triggersBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureTriggersIsMutable(); - triggers_.add(index, value); - onChanged(); - } else { - triggersBuilder_.addMessage(index, value); - } - return this; - } - /** - * - * - *
-     * `BuildTriggers` for the project, sorted by `create_time` descending.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildTrigger triggers = 1; - */ - public Builder addTriggers(com.google.cloudbuild.v1.BuildTrigger.Builder builderForValue) { - if (triggersBuilder_ == null) { - ensureTriggersIsMutable(); - triggers_.add(builderForValue.build()); - onChanged(); - } else { - triggersBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * `BuildTriggers` for the project, sorted by `create_time` descending.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildTrigger triggers = 1; - */ - public Builder addTriggers( - int index, com.google.cloudbuild.v1.BuildTrigger.Builder builderForValue) { - if (triggersBuilder_ == null) { - ensureTriggersIsMutable(); - triggers_.add(index, builderForValue.build()); - onChanged(); - } else { - triggersBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * `BuildTriggers` for the project, sorted by `create_time` descending.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildTrigger triggers = 1; - */ - public Builder addAllTriggers( - java.lang.Iterable values) { - if (triggersBuilder_ == null) { - ensureTriggersIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, triggers_); - onChanged(); - } else { - triggersBuilder_.addAllMessages(values); - } - return this; - } - /** - * - * - *
-     * `BuildTriggers` for the project, sorted by `create_time` descending.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildTrigger triggers = 1; - */ - public Builder clearTriggers() { - if (triggersBuilder_ == null) { - triggers_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - } else { - triggersBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * `BuildTriggers` for the project, sorted by `create_time` descending.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildTrigger triggers = 1; - */ - public Builder removeTriggers(int index) { - if (triggersBuilder_ == null) { - ensureTriggersIsMutable(); - triggers_.remove(index); - onChanged(); - } else { - triggersBuilder_.remove(index); - } - return this; - } - /** - * - * - *
-     * `BuildTriggers` for the project, sorted by `create_time` descending.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildTrigger triggers = 1; - */ - public com.google.cloudbuild.v1.BuildTrigger.Builder getTriggersBuilder(int index) { - return getTriggersFieldBuilder().getBuilder(index); - } - /** - * - * - *
-     * `BuildTriggers` for the project, sorted by `create_time` descending.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildTrigger triggers = 1; - */ - public com.google.cloudbuild.v1.BuildTriggerOrBuilder getTriggersOrBuilder(int index) { - if (triggersBuilder_ == null) { - return triggers_.get(index); - } else { - return triggersBuilder_.getMessageOrBuilder(index); - } - } - /** - * - * - *
-     * `BuildTriggers` for the project, sorted by `create_time` descending.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildTrigger triggers = 1; - */ - public java.util.List - getTriggersOrBuilderList() { - if (triggersBuilder_ != null) { - return triggersBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(triggers_); - } - } - /** - * - * - *
-     * `BuildTriggers` for the project, sorted by `create_time` descending.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildTrigger triggers = 1; - */ - public com.google.cloudbuild.v1.BuildTrigger.Builder addTriggersBuilder() { - return getTriggersFieldBuilder() - .addBuilder(com.google.cloudbuild.v1.BuildTrigger.getDefaultInstance()); - } - /** - * - * - *
-     * `BuildTriggers` for the project, sorted by `create_time` descending.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildTrigger triggers = 1; - */ - public com.google.cloudbuild.v1.BuildTrigger.Builder addTriggersBuilder(int index) { - return getTriggersFieldBuilder() - .addBuilder(index, com.google.cloudbuild.v1.BuildTrigger.getDefaultInstance()); - } - /** - * - * - *
-     * `BuildTriggers` for the project, sorted by `create_time` descending.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildTrigger triggers = 1; - */ - public java.util.List getTriggersBuilderList() { - return getTriggersFieldBuilder().getBuilderList(); - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloudbuild.v1.BuildTrigger, - com.google.cloudbuild.v1.BuildTrigger.Builder, - com.google.cloudbuild.v1.BuildTriggerOrBuilder> - getTriggersFieldBuilder() { - if (triggersBuilder_ == null) { - triggersBuilder_ = - new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloudbuild.v1.BuildTrigger, - com.google.cloudbuild.v1.BuildTrigger.Builder, - com.google.cloudbuild.v1.BuildTriggerOrBuilder>( - triggers_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); - triggers_ = null; - } - return triggersBuilder_; - } - - private java.lang.Object nextPageToken_ = ""; - /** - * - * - *
-     * Token to receive the next page of results.
-     * 
- * - * string next_page_token = 2; - * - * @return The nextPageToken. - */ - public java.lang.String getNextPageToken() { - java.lang.Object ref = nextPageToken_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - nextPageToken_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Token to receive the next page of results.
-     * 
- * - * string next_page_token = 2; - * - * @return The bytes for nextPageToken. - */ - public com.google.protobuf.ByteString getNextPageTokenBytes() { - java.lang.Object ref = nextPageToken_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - nextPageToken_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Token to receive the next page of results.
-     * 
- * - * string next_page_token = 2; - * - * @param value The nextPageToken to set. - * @return This builder for chaining. - */ - public Builder setNextPageToken(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - nextPageToken_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Token to receive the next page of results.
-     * 
- * - * string next_page_token = 2; - * - * @return This builder for chaining. - */ - public Builder clearNextPageToken() { - - nextPageToken_ = getDefaultInstance().getNextPageToken(); - onChanged(); - return this; - } - /** - * - * - *
-     * Token to receive the next page of results.
-     * 
- * - * string next_page_token = 2; - * - * @param value The bytes for nextPageToken to set. - * @return This builder for chaining. - */ - public Builder setNextPageTokenBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - nextPageToken_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.ListBuildTriggersResponse) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.ListBuildTriggersResponse) - private static final com.google.cloudbuild.v1.ListBuildTriggersResponse DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.ListBuildTriggersResponse(); - } - - public static com.google.cloudbuild.v1.ListBuildTriggersResponse getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public ListBuildTriggersResponse parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.ListBuildTriggersResponse getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildTriggersResponseOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildTriggersResponseOrBuilder.java deleted file mode 100644 index 7b7bb586..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildTriggersResponseOrBuilder.java +++ /dev/null @@ -1,102 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface ListBuildTriggersResponseOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.ListBuildTriggersResponse) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * `BuildTriggers` for the project, sorted by `create_time` descending.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildTrigger triggers = 1; - */ - java.util.List getTriggersList(); - /** - * - * - *
-   * `BuildTriggers` for the project, sorted by `create_time` descending.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildTrigger triggers = 1; - */ - com.google.cloudbuild.v1.BuildTrigger getTriggers(int index); - /** - * - * - *
-   * `BuildTriggers` for the project, sorted by `create_time` descending.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildTrigger triggers = 1; - */ - int getTriggersCount(); - /** - * - * - *
-   * `BuildTriggers` for the project, sorted by `create_time` descending.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildTrigger triggers = 1; - */ - java.util.List - getTriggersOrBuilderList(); - /** - * - * - *
-   * `BuildTriggers` for the project, sorted by `create_time` descending.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.BuildTrigger triggers = 1; - */ - com.google.cloudbuild.v1.BuildTriggerOrBuilder getTriggersOrBuilder(int index); - - /** - * - * - *
-   * Token to receive the next page of results.
-   * 
- * - * string next_page_token = 2; - * - * @return The nextPageToken. - */ - java.lang.String getNextPageToken(); - /** - * - * - *
-   * Token to receive the next page of results.
-   * 
- * - * string next_page_token = 2; - * - * @return The bytes for nextPageToken. - */ - com.google.protobuf.ByteString getNextPageTokenBytes(); -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildsRequest.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildsRequest.java deleted file mode 100644 index c429dda2..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildsRequest.java +++ /dev/null @@ -1,1281 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * Request to list builds.
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.ListBuildsRequest} - */ -public final class ListBuildsRequest extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.ListBuildsRequest) - ListBuildsRequestOrBuilder { - private static final long serialVersionUID = 0L; - // Use ListBuildsRequest.newBuilder() to construct. - private ListBuildsRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private ListBuildsRequest() { - parent_ = ""; - projectId_ = ""; - pageToken_ = ""; - filter_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new ListBuildsRequest(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ListBuildsRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ListBuildsRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.ListBuildsRequest.class, - com.google.cloudbuild.v1.ListBuildsRequest.Builder.class); - } - - public static final int PARENT_FIELD_NUMBER = 9; - private volatile java.lang.Object parent_; - /** - * - * - *
-   * The parent of the collection of `Builds`.
-   * Format: `projects/{project}/locations/location`
-   * 
- * - * string parent = 9 [(.google.api.resource_reference) = { ... } - * - * @return The parent. - */ - @java.lang.Override - public java.lang.String getParent() { - java.lang.Object ref = parent_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - parent_ = s; - return s; - } - } - /** - * - * - *
-   * The parent of the collection of `Builds`.
-   * Format: `projects/{project}/locations/location`
-   * 
- * - * string parent = 9 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for parent. - */ - @java.lang.Override - public com.google.protobuf.ByteString getParentBytes() { - java.lang.Object ref = parent_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - parent_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int PROJECT_ID_FIELD_NUMBER = 1; - private volatile java.lang.Object projectId_; - /** - * - * - *
-   * Required. ID of the project.
-   * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The projectId. - */ - @java.lang.Override - public java.lang.String getProjectId() { - java.lang.Object ref = projectId_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - projectId_ = s; - return s; - } - } - /** - * - * - *
-   * Required. ID of the project.
-   * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for projectId. - */ - @java.lang.Override - public com.google.protobuf.ByteString getProjectIdBytes() { - java.lang.Object ref = projectId_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - projectId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int PAGE_SIZE_FIELD_NUMBER = 2; - private int pageSize_; - /** - * - * - *
-   * Number of results to return in the list.
-   * 
- * - * int32 page_size = 2; - * - * @return The pageSize. - */ - @java.lang.Override - public int getPageSize() { - return pageSize_; - } - - public static final int PAGE_TOKEN_FIELD_NUMBER = 3; - private volatile java.lang.Object pageToken_; - /** - * - * - *
-   * The page token for the next page of Builds.
-   * If unspecified, the first page of results is returned.
-   * If the token is rejected for any reason, INVALID_ARGUMENT will be thrown.
-   * In this case, the token should be discarded, and pagination should be
-   * restarted from the first page of results.
-   * See https://google.aip.dev/158 for more.
-   * 
- * - * string page_token = 3; - * - * @return The pageToken. - */ - @java.lang.Override - public java.lang.String getPageToken() { - java.lang.Object ref = pageToken_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - pageToken_ = s; - return s; - } - } - /** - * - * - *
-   * The page token for the next page of Builds.
-   * If unspecified, the first page of results is returned.
-   * If the token is rejected for any reason, INVALID_ARGUMENT will be thrown.
-   * In this case, the token should be discarded, and pagination should be
-   * restarted from the first page of results.
-   * See https://google.aip.dev/158 for more.
-   * 
- * - * string page_token = 3; - * - * @return The bytes for pageToken. - */ - @java.lang.Override - public com.google.protobuf.ByteString getPageTokenBytes() { - java.lang.Object ref = pageToken_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - pageToken_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int FILTER_FIELD_NUMBER = 8; - private volatile java.lang.Object filter_; - /** - * - * - *
-   * The raw filter text to constrain the results.
-   * 
- * - * string filter = 8; - * - * @return The filter. - */ - @java.lang.Override - public java.lang.String getFilter() { - java.lang.Object ref = filter_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - filter_ = s; - return s; - } - } - /** - * - * - *
-   * The raw filter text to constrain the results.
-   * 
- * - * string filter = 8; - * - * @return The bytes for filter. - */ - @java.lang.Override - public com.google.protobuf.ByteString getFilterBytes() { - java.lang.Object ref = filter_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - filter_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(projectId_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, projectId_); - } - if (pageSize_ != 0) { - output.writeInt32(2, pageSize_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(pageToken_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 3, pageToken_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(filter_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 8, filter_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 9, parent_); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(projectId_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, projectId_); - } - if (pageSize_ != 0) { - size += com.google.protobuf.CodedOutputStream.computeInt32Size(2, pageSize_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(pageToken_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, pageToken_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(filter_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(8, filter_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(9, parent_); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.ListBuildsRequest)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.ListBuildsRequest other = - (com.google.cloudbuild.v1.ListBuildsRequest) obj; - - if (!getParent().equals(other.getParent())) return false; - if (!getProjectId().equals(other.getProjectId())) return false; - if (getPageSize() != other.getPageSize()) return false; - if (!getPageToken().equals(other.getPageToken())) return false; - if (!getFilter().equals(other.getFilter())) return false; - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + PARENT_FIELD_NUMBER; - hash = (53 * hash) + getParent().hashCode(); - hash = (37 * hash) + PROJECT_ID_FIELD_NUMBER; - hash = (53 * hash) + getProjectId().hashCode(); - hash = (37 * hash) + PAGE_SIZE_FIELD_NUMBER; - hash = (53 * hash) + getPageSize(); - hash = (37 * hash) + PAGE_TOKEN_FIELD_NUMBER; - hash = (53 * hash) + getPageToken().hashCode(); - hash = (37 * hash) + FILTER_FIELD_NUMBER; - hash = (53 * hash) + getFilter().hashCode(); - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.ListBuildsRequest parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.ListBuildsRequest parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ListBuildsRequest parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.ListBuildsRequest parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ListBuildsRequest parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.ListBuildsRequest parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ListBuildsRequest parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.ListBuildsRequest parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ListBuildsRequest parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.ListBuildsRequest parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ListBuildsRequest parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.ListBuildsRequest parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.ListBuildsRequest prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * Request to list builds.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.ListBuildsRequest} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.ListBuildsRequest) - com.google.cloudbuild.v1.ListBuildsRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ListBuildsRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ListBuildsRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.ListBuildsRequest.class, - com.google.cloudbuild.v1.ListBuildsRequest.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.ListBuildsRequest.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - parent_ = ""; - - projectId_ = ""; - - pageSize_ = 0; - - pageToken_ = ""; - - filter_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ListBuildsRequest_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.ListBuildsRequest getDefaultInstanceForType() { - return com.google.cloudbuild.v1.ListBuildsRequest.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.ListBuildsRequest build() { - com.google.cloudbuild.v1.ListBuildsRequest result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.ListBuildsRequest buildPartial() { - com.google.cloudbuild.v1.ListBuildsRequest result = - new com.google.cloudbuild.v1.ListBuildsRequest(this); - result.parent_ = parent_; - result.projectId_ = projectId_; - result.pageSize_ = pageSize_; - result.pageToken_ = pageToken_; - result.filter_ = filter_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.ListBuildsRequest) { - return mergeFrom((com.google.cloudbuild.v1.ListBuildsRequest) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.ListBuildsRequest other) { - if (other == com.google.cloudbuild.v1.ListBuildsRequest.getDefaultInstance()) return this; - if (!other.getParent().isEmpty()) { - parent_ = other.parent_; - onChanged(); - } - if (!other.getProjectId().isEmpty()) { - projectId_ = other.projectId_; - onChanged(); - } - if (other.getPageSize() != 0) { - setPageSize(other.getPageSize()); - } - if (!other.getPageToken().isEmpty()) { - pageToken_ = other.pageToken_; - onChanged(); - } - if (!other.getFilter().isEmpty()) { - filter_ = other.filter_; - onChanged(); - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - projectId_ = input.readStringRequireUtf8(); - - break; - } // case 10 - case 16: - { - pageSize_ = input.readInt32(); - - break; - } // case 16 - case 26: - { - pageToken_ = input.readStringRequireUtf8(); - - break; - } // case 26 - case 66: - { - filter_ = input.readStringRequireUtf8(); - - break; - } // case 66 - case 74: - { - parent_ = input.readStringRequireUtf8(); - - break; - } // case 74 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private java.lang.Object parent_ = ""; - /** - * - * - *
-     * The parent of the collection of `Builds`.
-     * Format: `projects/{project}/locations/location`
-     * 
- * - * string parent = 9 [(.google.api.resource_reference) = { ... } - * - * @return The parent. - */ - public java.lang.String getParent() { - java.lang.Object ref = parent_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - parent_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * The parent of the collection of `Builds`.
-     * Format: `projects/{project}/locations/location`
-     * 
- * - * string parent = 9 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for parent. - */ - public com.google.protobuf.ByteString getParentBytes() { - java.lang.Object ref = parent_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - parent_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * The parent of the collection of `Builds`.
-     * Format: `projects/{project}/locations/location`
-     * 
- * - * string parent = 9 [(.google.api.resource_reference) = { ... } - * - * @param value The parent to set. - * @return This builder for chaining. - */ - public Builder setParent(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - parent_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The parent of the collection of `Builds`.
-     * Format: `projects/{project}/locations/location`
-     * 
- * - * string parent = 9 [(.google.api.resource_reference) = { ... } - * - * @return This builder for chaining. - */ - public Builder clearParent() { - - parent_ = getDefaultInstance().getParent(); - onChanged(); - return this; - } - /** - * - * - *
-     * The parent of the collection of `Builds`.
-     * Format: `projects/{project}/locations/location`
-     * 
- * - * string parent = 9 [(.google.api.resource_reference) = { ... } - * - * @param value The bytes for parent to set. - * @return This builder for chaining. - */ - public Builder setParentBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - parent_ = value; - onChanged(); - return this; - } - - private java.lang.Object projectId_ = ""; - /** - * - * - *
-     * Required. ID of the project.
-     * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The projectId. - */ - public java.lang.String getProjectId() { - java.lang.Object ref = projectId_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - projectId_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Required. ID of the project.
-     * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for projectId. - */ - public com.google.protobuf.ByteString getProjectIdBytes() { - java.lang.Object ref = projectId_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - projectId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Required. ID of the project.
-     * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @param value The projectId to set. - * @return This builder for chaining. - */ - public Builder setProjectId(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - projectId_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Required. ID of the project.
-     * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return This builder for chaining. - */ - public Builder clearProjectId() { - - projectId_ = getDefaultInstance().getProjectId(); - onChanged(); - return this; - } - /** - * - * - *
-     * Required. ID of the project.
-     * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @param value The bytes for projectId to set. - * @return This builder for chaining. - */ - public Builder setProjectIdBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - projectId_ = value; - onChanged(); - return this; - } - - private int pageSize_; - /** - * - * - *
-     * Number of results to return in the list.
-     * 
- * - * int32 page_size = 2; - * - * @return The pageSize. - */ - @java.lang.Override - public int getPageSize() { - return pageSize_; - } - /** - * - * - *
-     * Number of results to return in the list.
-     * 
- * - * int32 page_size = 2; - * - * @param value The pageSize to set. - * @return This builder for chaining. - */ - public Builder setPageSize(int value) { - - pageSize_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Number of results to return in the list.
-     * 
- * - * int32 page_size = 2; - * - * @return This builder for chaining. - */ - public Builder clearPageSize() { - - pageSize_ = 0; - onChanged(); - return this; - } - - private java.lang.Object pageToken_ = ""; - /** - * - * - *
-     * The page token for the next page of Builds.
-     * If unspecified, the first page of results is returned.
-     * If the token is rejected for any reason, INVALID_ARGUMENT will be thrown.
-     * In this case, the token should be discarded, and pagination should be
-     * restarted from the first page of results.
-     * See https://google.aip.dev/158 for more.
-     * 
- * - * string page_token = 3; - * - * @return The pageToken. - */ - public java.lang.String getPageToken() { - java.lang.Object ref = pageToken_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - pageToken_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * The page token for the next page of Builds.
-     * If unspecified, the first page of results is returned.
-     * If the token is rejected for any reason, INVALID_ARGUMENT will be thrown.
-     * In this case, the token should be discarded, and pagination should be
-     * restarted from the first page of results.
-     * See https://google.aip.dev/158 for more.
-     * 
- * - * string page_token = 3; - * - * @return The bytes for pageToken. - */ - public com.google.protobuf.ByteString getPageTokenBytes() { - java.lang.Object ref = pageToken_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - pageToken_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * The page token for the next page of Builds.
-     * If unspecified, the first page of results is returned.
-     * If the token is rejected for any reason, INVALID_ARGUMENT will be thrown.
-     * In this case, the token should be discarded, and pagination should be
-     * restarted from the first page of results.
-     * See https://google.aip.dev/158 for more.
-     * 
- * - * string page_token = 3; - * - * @param value The pageToken to set. - * @return This builder for chaining. - */ - public Builder setPageToken(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - pageToken_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The page token for the next page of Builds.
-     * If unspecified, the first page of results is returned.
-     * If the token is rejected for any reason, INVALID_ARGUMENT will be thrown.
-     * In this case, the token should be discarded, and pagination should be
-     * restarted from the first page of results.
-     * See https://google.aip.dev/158 for more.
-     * 
- * - * string page_token = 3; - * - * @return This builder for chaining. - */ - public Builder clearPageToken() { - - pageToken_ = getDefaultInstance().getPageToken(); - onChanged(); - return this; - } - /** - * - * - *
-     * The page token for the next page of Builds.
-     * If unspecified, the first page of results is returned.
-     * If the token is rejected for any reason, INVALID_ARGUMENT will be thrown.
-     * In this case, the token should be discarded, and pagination should be
-     * restarted from the first page of results.
-     * See https://google.aip.dev/158 for more.
-     * 
- * - * string page_token = 3; - * - * @param value The bytes for pageToken to set. - * @return This builder for chaining. - */ - public Builder setPageTokenBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - pageToken_ = value; - onChanged(); - return this; - } - - private java.lang.Object filter_ = ""; - /** - * - * - *
-     * The raw filter text to constrain the results.
-     * 
- * - * string filter = 8; - * - * @return The filter. - */ - public java.lang.String getFilter() { - java.lang.Object ref = filter_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - filter_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * The raw filter text to constrain the results.
-     * 
- * - * string filter = 8; - * - * @return The bytes for filter. - */ - public com.google.protobuf.ByteString getFilterBytes() { - java.lang.Object ref = filter_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - filter_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * The raw filter text to constrain the results.
-     * 
- * - * string filter = 8; - * - * @param value The filter to set. - * @return This builder for chaining. - */ - public Builder setFilter(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - filter_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The raw filter text to constrain the results.
-     * 
- * - * string filter = 8; - * - * @return This builder for chaining. - */ - public Builder clearFilter() { - - filter_ = getDefaultInstance().getFilter(); - onChanged(); - return this; - } - /** - * - * - *
-     * The raw filter text to constrain the results.
-     * 
- * - * string filter = 8; - * - * @param value The bytes for filter to set. - * @return This builder for chaining. - */ - public Builder setFilterBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - filter_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.ListBuildsRequest) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.ListBuildsRequest) - private static final com.google.cloudbuild.v1.ListBuildsRequest DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.ListBuildsRequest(); - } - - public static com.google.cloudbuild.v1.ListBuildsRequest getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public ListBuildsRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.ListBuildsRequest getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildsRequestOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildsRequestOrBuilder.java deleted file mode 100644 index 125fc081..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildsRequestOrBuilder.java +++ /dev/null @@ -1,150 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface ListBuildsRequestOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.ListBuildsRequest) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The parent of the collection of `Builds`.
-   * Format: `projects/{project}/locations/location`
-   * 
- * - * string parent = 9 [(.google.api.resource_reference) = { ... } - * - * @return The parent. - */ - java.lang.String getParent(); - /** - * - * - *
-   * The parent of the collection of `Builds`.
-   * Format: `projects/{project}/locations/location`
-   * 
- * - * string parent = 9 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for parent. - */ - com.google.protobuf.ByteString getParentBytes(); - - /** - * - * - *
-   * Required. ID of the project.
-   * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The projectId. - */ - java.lang.String getProjectId(); - /** - * - * - *
-   * Required. ID of the project.
-   * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for projectId. - */ - com.google.protobuf.ByteString getProjectIdBytes(); - - /** - * - * - *
-   * Number of results to return in the list.
-   * 
- * - * int32 page_size = 2; - * - * @return The pageSize. - */ - int getPageSize(); - - /** - * - * - *
-   * The page token for the next page of Builds.
-   * If unspecified, the first page of results is returned.
-   * If the token is rejected for any reason, INVALID_ARGUMENT will be thrown.
-   * In this case, the token should be discarded, and pagination should be
-   * restarted from the first page of results.
-   * See https://google.aip.dev/158 for more.
-   * 
- * - * string page_token = 3; - * - * @return The pageToken. - */ - java.lang.String getPageToken(); - /** - * - * - *
-   * The page token for the next page of Builds.
-   * If unspecified, the first page of results is returned.
-   * If the token is rejected for any reason, INVALID_ARGUMENT will be thrown.
-   * In this case, the token should be discarded, and pagination should be
-   * restarted from the first page of results.
-   * See https://google.aip.dev/158 for more.
-   * 
- * - * string page_token = 3; - * - * @return The bytes for pageToken. - */ - com.google.protobuf.ByteString getPageTokenBytes(); - - /** - * - * - *
-   * The raw filter text to constrain the results.
-   * 
- * - * string filter = 8; - * - * @return The filter. - */ - java.lang.String getFilter(); - /** - * - * - *
-   * The raw filter text to constrain the results.
-   * 
- * - * string filter = 8; - * - * @return The bytes for filter. - */ - com.google.protobuf.ByteString getFilterBytes(); -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildsResponse.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildsResponse.java deleted file mode 100644 index ddf00fb1..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildsResponse.java +++ /dev/null @@ -1,1106 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * Response including listed builds.
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.ListBuildsResponse} - */ -public final class ListBuildsResponse extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.ListBuildsResponse) - ListBuildsResponseOrBuilder { - private static final long serialVersionUID = 0L; - // Use ListBuildsResponse.newBuilder() to construct. - private ListBuildsResponse(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private ListBuildsResponse() { - builds_ = java.util.Collections.emptyList(); - nextPageToken_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new ListBuildsResponse(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ListBuildsResponse_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ListBuildsResponse_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.ListBuildsResponse.class, - com.google.cloudbuild.v1.ListBuildsResponse.Builder.class); - } - - public static final int BUILDS_FIELD_NUMBER = 1; - private java.util.List builds_; - /** - * - * - *
-   * Builds will be sorted by `create_time`, descending.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Build builds = 1; - */ - @java.lang.Override - public java.util.List getBuildsList() { - return builds_; - } - /** - * - * - *
-   * Builds will be sorted by `create_time`, descending.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Build builds = 1; - */ - @java.lang.Override - public java.util.List - getBuildsOrBuilderList() { - return builds_; - } - /** - * - * - *
-   * Builds will be sorted by `create_time`, descending.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Build builds = 1; - */ - @java.lang.Override - public int getBuildsCount() { - return builds_.size(); - } - /** - * - * - *
-   * Builds will be sorted by `create_time`, descending.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Build builds = 1; - */ - @java.lang.Override - public com.google.cloudbuild.v1.Build getBuilds(int index) { - return builds_.get(index); - } - /** - * - * - *
-   * Builds will be sorted by `create_time`, descending.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Build builds = 1; - */ - @java.lang.Override - public com.google.cloudbuild.v1.BuildOrBuilder getBuildsOrBuilder(int index) { - return builds_.get(index); - } - - public static final int NEXT_PAGE_TOKEN_FIELD_NUMBER = 2; - private volatile java.lang.Object nextPageToken_; - /** - * - * - *
-   * Token to receive the next page of results.
-   * This will be absent if the end of the response list has been reached.
-   * 
- * - * string next_page_token = 2; - * - * @return The nextPageToken. - */ - @java.lang.Override - public java.lang.String getNextPageToken() { - java.lang.Object ref = nextPageToken_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - nextPageToken_ = s; - return s; - } - } - /** - * - * - *
-   * Token to receive the next page of results.
-   * This will be absent if the end of the response list has been reached.
-   * 
- * - * string next_page_token = 2; - * - * @return The bytes for nextPageToken. - */ - @java.lang.Override - public com.google.protobuf.ByteString getNextPageTokenBytes() { - java.lang.Object ref = nextPageToken_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - nextPageToken_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - for (int i = 0; i < builds_.size(); i++) { - output.writeMessage(1, builds_.get(i)); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(nextPageToken_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, nextPageToken_); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - for (int i = 0; i < builds_.size(); i++) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, builds_.get(i)); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(nextPageToken_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, nextPageToken_); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.ListBuildsResponse)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.ListBuildsResponse other = - (com.google.cloudbuild.v1.ListBuildsResponse) obj; - - if (!getBuildsList().equals(other.getBuildsList())) return false; - if (!getNextPageToken().equals(other.getNextPageToken())) return false; - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (getBuildsCount() > 0) { - hash = (37 * hash) + BUILDS_FIELD_NUMBER; - hash = (53 * hash) + getBuildsList().hashCode(); - } - hash = (37 * hash) + NEXT_PAGE_TOKEN_FIELD_NUMBER; - hash = (53 * hash) + getNextPageToken().hashCode(); - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.ListBuildsResponse parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.ListBuildsResponse parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ListBuildsResponse parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.ListBuildsResponse parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ListBuildsResponse parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.ListBuildsResponse parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ListBuildsResponse parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.ListBuildsResponse parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ListBuildsResponse parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.ListBuildsResponse parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ListBuildsResponse parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.ListBuildsResponse parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.ListBuildsResponse prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * Response including listed builds.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.ListBuildsResponse} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.ListBuildsResponse) - com.google.cloudbuild.v1.ListBuildsResponseOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ListBuildsResponse_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ListBuildsResponse_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.ListBuildsResponse.class, - com.google.cloudbuild.v1.ListBuildsResponse.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.ListBuildsResponse.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - if (buildsBuilder_ == null) { - builds_ = java.util.Collections.emptyList(); - } else { - builds_ = null; - buildsBuilder_.clear(); - } - bitField0_ = (bitField0_ & ~0x00000001); - nextPageToken_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ListBuildsResponse_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.ListBuildsResponse getDefaultInstanceForType() { - return com.google.cloudbuild.v1.ListBuildsResponse.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.ListBuildsResponse build() { - com.google.cloudbuild.v1.ListBuildsResponse result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.ListBuildsResponse buildPartial() { - com.google.cloudbuild.v1.ListBuildsResponse result = - new com.google.cloudbuild.v1.ListBuildsResponse(this); - int from_bitField0_ = bitField0_; - if (buildsBuilder_ == null) { - if (((bitField0_ & 0x00000001) != 0)) { - builds_ = java.util.Collections.unmodifiableList(builds_); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.builds_ = builds_; - } else { - result.builds_ = buildsBuilder_.build(); - } - result.nextPageToken_ = nextPageToken_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.ListBuildsResponse) { - return mergeFrom((com.google.cloudbuild.v1.ListBuildsResponse) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.ListBuildsResponse other) { - if (other == com.google.cloudbuild.v1.ListBuildsResponse.getDefaultInstance()) return this; - if (buildsBuilder_ == null) { - if (!other.builds_.isEmpty()) { - if (builds_.isEmpty()) { - builds_ = other.builds_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureBuildsIsMutable(); - builds_.addAll(other.builds_); - } - onChanged(); - } - } else { - if (!other.builds_.isEmpty()) { - if (buildsBuilder_.isEmpty()) { - buildsBuilder_.dispose(); - buildsBuilder_ = null; - builds_ = other.builds_; - bitField0_ = (bitField0_ & ~0x00000001); - buildsBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders - ? getBuildsFieldBuilder() - : null; - } else { - buildsBuilder_.addAllMessages(other.builds_); - } - } - } - if (!other.getNextPageToken().isEmpty()) { - nextPageToken_ = other.nextPageToken_; - onChanged(); - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - com.google.cloudbuild.v1.Build m = - input.readMessage(com.google.cloudbuild.v1.Build.parser(), extensionRegistry); - if (buildsBuilder_ == null) { - ensureBuildsIsMutable(); - builds_.add(m); - } else { - buildsBuilder_.addMessage(m); - } - break; - } // case 10 - case 18: - { - nextPageToken_ = input.readStringRequireUtf8(); - - break; - } // case 18 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private int bitField0_; - - private java.util.List builds_ = - java.util.Collections.emptyList(); - - private void ensureBuildsIsMutable() { - if (!((bitField0_ & 0x00000001) != 0)) { - builds_ = new java.util.ArrayList(builds_); - bitField0_ |= 0x00000001; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloudbuild.v1.Build, - com.google.cloudbuild.v1.Build.Builder, - com.google.cloudbuild.v1.BuildOrBuilder> - buildsBuilder_; - - /** - * - * - *
-     * Builds will be sorted by `create_time`, descending.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Build builds = 1; - */ - public java.util.List getBuildsList() { - if (buildsBuilder_ == null) { - return java.util.Collections.unmodifiableList(builds_); - } else { - return buildsBuilder_.getMessageList(); - } - } - /** - * - * - *
-     * Builds will be sorted by `create_time`, descending.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Build builds = 1; - */ - public int getBuildsCount() { - if (buildsBuilder_ == null) { - return builds_.size(); - } else { - return buildsBuilder_.getCount(); - } - } - /** - * - * - *
-     * Builds will be sorted by `create_time`, descending.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Build builds = 1; - */ - public com.google.cloudbuild.v1.Build getBuilds(int index) { - if (buildsBuilder_ == null) { - return builds_.get(index); - } else { - return buildsBuilder_.getMessage(index); - } - } - /** - * - * - *
-     * Builds will be sorted by `create_time`, descending.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Build builds = 1; - */ - public Builder setBuilds(int index, com.google.cloudbuild.v1.Build value) { - if (buildsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureBuildsIsMutable(); - builds_.set(index, value); - onChanged(); - } else { - buildsBuilder_.setMessage(index, value); - } - return this; - } - /** - * - * - *
-     * Builds will be sorted by `create_time`, descending.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Build builds = 1; - */ - public Builder setBuilds(int index, com.google.cloudbuild.v1.Build.Builder builderForValue) { - if (buildsBuilder_ == null) { - ensureBuildsIsMutable(); - builds_.set(index, builderForValue.build()); - onChanged(); - } else { - buildsBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * Builds will be sorted by `create_time`, descending.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Build builds = 1; - */ - public Builder addBuilds(com.google.cloudbuild.v1.Build value) { - if (buildsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureBuildsIsMutable(); - builds_.add(value); - onChanged(); - } else { - buildsBuilder_.addMessage(value); - } - return this; - } - /** - * - * - *
-     * Builds will be sorted by `create_time`, descending.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Build builds = 1; - */ - public Builder addBuilds(int index, com.google.cloudbuild.v1.Build value) { - if (buildsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureBuildsIsMutable(); - builds_.add(index, value); - onChanged(); - } else { - buildsBuilder_.addMessage(index, value); - } - return this; - } - /** - * - * - *
-     * Builds will be sorted by `create_time`, descending.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Build builds = 1; - */ - public Builder addBuilds(com.google.cloudbuild.v1.Build.Builder builderForValue) { - if (buildsBuilder_ == null) { - ensureBuildsIsMutable(); - builds_.add(builderForValue.build()); - onChanged(); - } else { - buildsBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * Builds will be sorted by `create_time`, descending.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Build builds = 1; - */ - public Builder addBuilds(int index, com.google.cloudbuild.v1.Build.Builder builderForValue) { - if (buildsBuilder_ == null) { - ensureBuildsIsMutable(); - builds_.add(index, builderForValue.build()); - onChanged(); - } else { - buildsBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * Builds will be sorted by `create_time`, descending.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Build builds = 1; - */ - public Builder addAllBuilds( - java.lang.Iterable values) { - if (buildsBuilder_ == null) { - ensureBuildsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, builds_); - onChanged(); - } else { - buildsBuilder_.addAllMessages(values); - } - return this; - } - /** - * - * - *
-     * Builds will be sorted by `create_time`, descending.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Build builds = 1; - */ - public Builder clearBuilds() { - if (buildsBuilder_ == null) { - builds_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - } else { - buildsBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * Builds will be sorted by `create_time`, descending.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Build builds = 1; - */ - public Builder removeBuilds(int index) { - if (buildsBuilder_ == null) { - ensureBuildsIsMutable(); - builds_.remove(index); - onChanged(); - } else { - buildsBuilder_.remove(index); - } - return this; - } - /** - * - * - *
-     * Builds will be sorted by `create_time`, descending.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Build builds = 1; - */ - public com.google.cloudbuild.v1.Build.Builder getBuildsBuilder(int index) { - return getBuildsFieldBuilder().getBuilder(index); - } - /** - * - * - *
-     * Builds will be sorted by `create_time`, descending.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Build builds = 1; - */ - public com.google.cloudbuild.v1.BuildOrBuilder getBuildsOrBuilder(int index) { - if (buildsBuilder_ == null) { - return builds_.get(index); - } else { - return buildsBuilder_.getMessageOrBuilder(index); - } - } - /** - * - * - *
-     * Builds will be sorted by `create_time`, descending.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Build builds = 1; - */ - public java.util.List - getBuildsOrBuilderList() { - if (buildsBuilder_ != null) { - return buildsBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(builds_); - } - } - /** - * - * - *
-     * Builds will be sorted by `create_time`, descending.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Build builds = 1; - */ - public com.google.cloudbuild.v1.Build.Builder addBuildsBuilder() { - return getBuildsFieldBuilder() - .addBuilder(com.google.cloudbuild.v1.Build.getDefaultInstance()); - } - /** - * - * - *
-     * Builds will be sorted by `create_time`, descending.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Build builds = 1; - */ - public com.google.cloudbuild.v1.Build.Builder addBuildsBuilder(int index) { - return getBuildsFieldBuilder() - .addBuilder(index, com.google.cloudbuild.v1.Build.getDefaultInstance()); - } - /** - * - * - *
-     * Builds will be sorted by `create_time`, descending.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.Build builds = 1; - */ - public java.util.List getBuildsBuilderList() { - return getBuildsFieldBuilder().getBuilderList(); - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloudbuild.v1.Build, - com.google.cloudbuild.v1.Build.Builder, - com.google.cloudbuild.v1.BuildOrBuilder> - getBuildsFieldBuilder() { - if (buildsBuilder_ == null) { - buildsBuilder_ = - new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloudbuild.v1.Build, - com.google.cloudbuild.v1.Build.Builder, - com.google.cloudbuild.v1.BuildOrBuilder>( - builds_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); - builds_ = null; - } - return buildsBuilder_; - } - - private java.lang.Object nextPageToken_ = ""; - /** - * - * - *
-     * Token to receive the next page of results.
-     * This will be absent if the end of the response list has been reached.
-     * 
- * - * string next_page_token = 2; - * - * @return The nextPageToken. - */ - public java.lang.String getNextPageToken() { - java.lang.Object ref = nextPageToken_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - nextPageToken_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Token to receive the next page of results.
-     * This will be absent if the end of the response list has been reached.
-     * 
- * - * string next_page_token = 2; - * - * @return The bytes for nextPageToken. - */ - public com.google.protobuf.ByteString getNextPageTokenBytes() { - java.lang.Object ref = nextPageToken_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - nextPageToken_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Token to receive the next page of results.
-     * This will be absent if the end of the response list has been reached.
-     * 
- * - * string next_page_token = 2; - * - * @param value The nextPageToken to set. - * @return This builder for chaining. - */ - public Builder setNextPageToken(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - nextPageToken_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Token to receive the next page of results.
-     * This will be absent if the end of the response list has been reached.
-     * 
- * - * string next_page_token = 2; - * - * @return This builder for chaining. - */ - public Builder clearNextPageToken() { - - nextPageToken_ = getDefaultInstance().getNextPageToken(); - onChanged(); - return this; - } - /** - * - * - *
-     * Token to receive the next page of results.
-     * This will be absent if the end of the response list has been reached.
-     * 
- * - * string next_page_token = 2; - * - * @param value The bytes for nextPageToken to set. - * @return This builder for chaining. - */ - public Builder setNextPageTokenBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - nextPageToken_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.ListBuildsResponse) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.ListBuildsResponse) - private static final com.google.cloudbuild.v1.ListBuildsResponse DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.ListBuildsResponse(); - } - - public static com.google.cloudbuild.v1.ListBuildsResponse getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public ListBuildsResponse parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.ListBuildsResponse getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildsResponseOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildsResponseOrBuilder.java deleted file mode 100644 index a5cbb7c3..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildsResponseOrBuilder.java +++ /dev/null @@ -1,103 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface ListBuildsResponseOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.ListBuildsResponse) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * Builds will be sorted by `create_time`, descending.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Build builds = 1; - */ - java.util.List getBuildsList(); - /** - * - * - *
-   * Builds will be sorted by `create_time`, descending.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Build builds = 1; - */ - com.google.cloudbuild.v1.Build getBuilds(int index); - /** - * - * - *
-   * Builds will be sorted by `create_time`, descending.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Build builds = 1; - */ - int getBuildsCount(); - /** - * - * - *
-   * Builds will be sorted by `create_time`, descending.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Build builds = 1; - */ - java.util.List getBuildsOrBuilderList(); - /** - * - * - *
-   * Builds will be sorted by `create_time`, descending.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.Build builds = 1; - */ - com.google.cloudbuild.v1.BuildOrBuilder getBuildsOrBuilder(int index); - - /** - * - * - *
-   * Token to receive the next page of results.
-   * This will be absent if the end of the response list has been reached.
-   * 
- * - * string next_page_token = 2; - * - * @return The nextPageToken. - */ - java.lang.String getNextPageToken(); - /** - * - * - *
-   * Token to receive the next page of results.
-   * This will be absent if the end of the response list has been reached.
-   * 
- * - * string next_page_token = 2; - * - * @return The bytes for nextPageToken. - */ - com.google.protobuf.ByteString getNextPageTokenBytes(); -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListWorkerPoolsRequest.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListWorkerPoolsRequest.java deleted file mode 100644 index b5fa8093..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListWorkerPoolsRequest.java +++ /dev/null @@ -1,916 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * Request to list `WorkerPool`s.
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.ListWorkerPoolsRequest} - */ -public final class ListWorkerPoolsRequest extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.ListWorkerPoolsRequest) - ListWorkerPoolsRequestOrBuilder { - private static final long serialVersionUID = 0L; - // Use ListWorkerPoolsRequest.newBuilder() to construct. - private ListWorkerPoolsRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private ListWorkerPoolsRequest() { - parent_ = ""; - pageToken_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new ListWorkerPoolsRequest(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ListWorkerPoolsRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ListWorkerPoolsRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.ListWorkerPoolsRequest.class, - com.google.cloudbuild.v1.ListWorkerPoolsRequest.Builder.class); - } - - public static final int PARENT_FIELD_NUMBER = 1; - private volatile java.lang.Object parent_; - /** - * - * - *
-   * Required. The parent of the collection of `WorkerPools`.
-   * Format: `projects/{project}/locations/{location}`.
-   * 
- * - * - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return The parent. - */ - @java.lang.Override - public java.lang.String getParent() { - java.lang.Object ref = parent_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - parent_ = s; - return s; - } - } - /** - * - * - *
-   * Required. The parent of the collection of `WorkerPools`.
-   * Format: `projects/{project}/locations/{location}`.
-   * 
- * - * - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return The bytes for parent. - */ - @java.lang.Override - public com.google.protobuf.ByteString getParentBytes() { - java.lang.Object ref = parent_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - parent_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int PAGE_SIZE_FIELD_NUMBER = 2; - private int pageSize_; - /** - * - * - *
-   * The maximum number of `WorkerPool`s to return. The service may return
-   * fewer than this value. If omitted, the server will use a sensible default.
-   * 
- * - * int32 page_size = 2; - * - * @return The pageSize. - */ - @java.lang.Override - public int getPageSize() { - return pageSize_; - } - - public static final int PAGE_TOKEN_FIELD_NUMBER = 3; - private volatile java.lang.Object pageToken_; - /** - * - * - *
-   * A page token, received from a previous `ListWorkerPools` call. Provide this
-   * to retrieve the subsequent page.
-   * 
- * - * string page_token = 3; - * - * @return The pageToken. - */ - @java.lang.Override - public java.lang.String getPageToken() { - java.lang.Object ref = pageToken_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - pageToken_ = s; - return s; - } - } - /** - * - * - *
-   * A page token, received from a previous `ListWorkerPools` call. Provide this
-   * to retrieve the subsequent page.
-   * 
- * - * string page_token = 3; - * - * @return The bytes for pageToken. - */ - @java.lang.Override - public com.google.protobuf.ByteString getPageTokenBytes() { - java.lang.Object ref = pageToken_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - pageToken_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, parent_); - } - if (pageSize_ != 0) { - output.writeInt32(2, pageSize_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(pageToken_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 3, pageToken_); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(parent_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, parent_); - } - if (pageSize_ != 0) { - size += com.google.protobuf.CodedOutputStream.computeInt32Size(2, pageSize_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(pageToken_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, pageToken_); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.ListWorkerPoolsRequest)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.ListWorkerPoolsRequest other = - (com.google.cloudbuild.v1.ListWorkerPoolsRequest) obj; - - if (!getParent().equals(other.getParent())) return false; - if (getPageSize() != other.getPageSize()) return false; - if (!getPageToken().equals(other.getPageToken())) return false; - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + PARENT_FIELD_NUMBER; - hash = (53 * hash) + getParent().hashCode(); - hash = (37 * hash) + PAGE_SIZE_FIELD_NUMBER; - hash = (53 * hash) + getPageSize(); - hash = (37 * hash) + PAGE_TOKEN_FIELD_NUMBER; - hash = (53 * hash) + getPageToken().hashCode(); - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.ListWorkerPoolsRequest parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.ListWorkerPoolsRequest parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ListWorkerPoolsRequest parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.ListWorkerPoolsRequest parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ListWorkerPoolsRequest parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.ListWorkerPoolsRequest parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ListWorkerPoolsRequest parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.ListWorkerPoolsRequest parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ListWorkerPoolsRequest parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.ListWorkerPoolsRequest parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ListWorkerPoolsRequest parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.ListWorkerPoolsRequest parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.ListWorkerPoolsRequest prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * Request to list `WorkerPool`s.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.ListWorkerPoolsRequest} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.ListWorkerPoolsRequest) - com.google.cloudbuild.v1.ListWorkerPoolsRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ListWorkerPoolsRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ListWorkerPoolsRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.ListWorkerPoolsRequest.class, - com.google.cloudbuild.v1.ListWorkerPoolsRequest.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.ListWorkerPoolsRequest.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - parent_ = ""; - - pageSize_ = 0; - - pageToken_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ListWorkerPoolsRequest_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.ListWorkerPoolsRequest getDefaultInstanceForType() { - return com.google.cloudbuild.v1.ListWorkerPoolsRequest.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.ListWorkerPoolsRequest build() { - com.google.cloudbuild.v1.ListWorkerPoolsRequest result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.ListWorkerPoolsRequest buildPartial() { - com.google.cloudbuild.v1.ListWorkerPoolsRequest result = - new com.google.cloudbuild.v1.ListWorkerPoolsRequest(this); - result.parent_ = parent_; - result.pageSize_ = pageSize_; - result.pageToken_ = pageToken_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.ListWorkerPoolsRequest) { - return mergeFrom((com.google.cloudbuild.v1.ListWorkerPoolsRequest) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.ListWorkerPoolsRequest other) { - if (other == com.google.cloudbuild.v1.ListWorkerPoolsRequest.getDefaultInstance()) - return this; - if (!other.getParent().isEmpty()) { - parent_ = other.parent_; - onChanged(); - } - if (other.getPageSize() != 0) { - setPageSize(other.getPageSize()); - } - if (!other.getPageToken().isEmpty()) { - pageToken_ = other.pageToken_; - onChanged(); - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - parent_ = input.readStringRequireUtf8(); - - break; - } // case 10 - case 16: - { - pageSize_ = input.readInt32(); - - break; - } // case 16 - case 26: - { - pageToken_ = input.readStringRequireUtf8(); - - break; - } // case 26 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private java.lang.Object parent_ = ""; - /** - * - * - *
-     * Required. The parent of the collection of `WorkerPools`.
-     * Format: `projects/{project}/locations/{location}`.
-     * 
- * - * - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return The parent. - */ - public java.lang.String getParent() { - java.lang.Object ref = parent_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - parent_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Required. The parent of the collection of `WorkerPools`.
-     * Format: `projects/{project}/locations/{location}`.
-     * 
- * - * - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return The bytes for parent. - */ - public com.google.protobuf.ByteString getParentBytes() { - java.lang.Object ref = parent_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - parent_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Required. The parent of the collection of `WorkerPools`.
-     * Format: `projects/{project}/locations/{location}`.
-     * 
- * - * - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @param value The parent to set. - * @return This builder for chaining. - */ - public Builder setParent(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - parent_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Required. The parent of the collection of `WorkerPools`.
-     * Format: `projects/{project}/locations/{location}`.
-     * 
- * - * - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return This builder for chaining. - */ - public Builder clearParent() { - - parent_ = getDefaultInstance().getParent(); - onChanged(); - return this; - } - /** - * - * - *
-     * Required. The parent of the collection of `WorkerPools`.
-     * Format: `projects/{project}/locations/{location}`.
-     * 
- * - * - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @param value The bytes for parent to set. - * @return This builder for chaining. - */ - public Builder setParentBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - parent_ = value; - onChanged(); - return this; - } - - private int pageSize_; - /** - * - * - *
-     * The maximum number of `WorkerPool`s to return. The service may return
-     * fewer than this value. If omitted, the server will use a sensible default.
-     * 
- * - * int32 page_size = 2; - * - * @return The pageSize. - */ - @java.lang.Override - public int getPageSize() { - return pageSize_; - } - /** - * - * - *
-     * The maximum number of `WorkerPool`s to return. The service may return
-     * fewer than this value. If omitted, the server will use a sensible default.
-     * 
- * - * int32 page_size = 2; - * - * @param value The pageSize to set. - * @return This builder for chaining. - */ - public Builder setPageSize(int value) { - - pageSize_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The maximum number of `WorkerPool`s to return. The service may return
-     * fewer than this value. If omitted, the server will use a sensible default.
-     * 
- * - * int32 page_size = 2; - * - * @return This builder for chaining. - */ - public Builder clearPageSize() { - - pageSize_ = 0; - onChanged(); - return this; - } - - private java.lang.Object pageToken_ = ""; - /** - * - * - *
-     * A page token, received from a previous `ListWorkerPools` call. Provide this
-     * to retrieve the subsequent page.
-     * 
- * - * string page_token = 3; - * - * @return The pageToken. - */ - public java.lang.String getPageToken() { - java.lang.Object ref = pageToken_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - pageToken_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * A page token, received from a previous `ListWorkerPools` call. Provide this
-     * to retrieve the subsequent page.
-     * 
- * - * string page_token = 3; - * - * @return The bytes for pageToken. - */ - public com.google.protobuf.ByteString getPageTokenBytes() { - java.lang.Object ref = pageToken_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - pageToken_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * A page token, received from a previous `ListWorkerPools` call. Provide this
-     * to retrieve the subsequent page.
-     * 
- * - * string page_token = 3; - * - * @param value The pageToken to set. - * @return This builder for chaining. - */ - public Builder setPageToken(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - pageToken_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * A page token, received from a previous `ListWorkerPools` call. Provide this
-     * to retrieve the subsequent page.
-     * 
- * - * string page_token = 3; - * - * @return This builder for chaining. - */ - public Builder clearPageToken() { - - pageToken_ = getDefaultInstance().getPageToken(); - onChanged(); - return this; - } - /** - * - * - *
-     * A page token, received from a previous `ListWorkerPools` call. Provide this
-     * to retrieve the subsequent page.
-     * 
- * - * string page_token = 3; - * - * @param value The bytes for pageToken to set. - * @return This builder for chaining. - */ - public Builder setPageTokenBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - pageToken_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.ListWorkerPoolsRequest) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.ListWorkerPoolsRequest) - private static final com.google.cloudbuild.v1.ListWorkerPoolsRequest DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.ListWorkerPoolsRequest(); - } - - public static com.google.cloudbuild.v1.ListWorkerPoolsRequest getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public ListWorkerPoolsRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.ListWorkerPoolsRequest getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListWorkerPoolsRequestOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListWorkerPoolsRequestOrBuilder.java deleted file mode 100644 index 1bab955e..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListWorkerPoolsRequestOrBuilder.java +++ /dev/null @@ -1,97 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface ListWorkerPoolsRequestOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.ListWorkerPoolsRequest) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * Required. The parent of the collection of `WorkerPools`.
-   * Format: `projects/{project}/locations/{location}`.
-   * 
- * - * - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return The parent. - */ - java.lang.String getParent(); - /** - * - * - *
-   * Required. The parent of the collection of `WorkerPools`.
-   * Format: `projects/{project}/locations/{location}`.
-   * 
- * - * - * string parent = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return The bytes for parent. - */ - com.google.protobuf.ByteString getParentBytes(); - - /** - * - * - *
-   * The maximum number of `WorkerPool`s to return. The service may return
-   * fewer than this value. If omitted, the server will use a sensible default.
-   * 
- * - * int32 page_size = 2; - * - * @return The pageSize. - */ - int getPageSize(); - - /** - * - * - *
-   * A page token, received from a previous `ListWorkerPools` call. Provide this
-   * to retrieve the subsequent page.
-   * 
- * - * string page_token = 3; - * - * @return The pageToken. - */ - java.lang.String getPageToken(); - /** - * - * - *
-   * A page token, received from a previous `ListWorkerPools` call. Provide this
-   * to retrieve the subsequent page.
-   * 
- * - * string page_token = 3; - * - * @return The bytes for pageToken. - */ - com.google.protobuf.ByteString getPageTokenBytes(); -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListWorkerPoolsResponse.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListWorkerPoolsResponse.java deleted file mode 100644 index d4a6099b..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListWorkerPoolsResponse.java +++ /dev/null @@ -1,1117 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * Response containing existing `WorkerPools`.
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.ListWorkerPoolsResponse} - */ -public final class ListWorkerPoolsResponse extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.ListWorkerPoolsResponse) - ListWorkerPoolsResponseOrBuilder { - private static final long serialVersionUID = 0L; - // Use ListWorkerPoolsResponse.newBuilder() to construct. - private ListWorkerPoolsResponse(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private ListWorkerPoolsResponse() { - workerPools_ = java.util.Collections.emptyList(); - nextPageToken_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new ListWorkerPoolsResponse(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ListWorkerPoolsResponse_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ListWorkerPoolsResponse_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.ListWorkerPoolsResponse.class, - com.google.cloudbuild.v1.ListWorkerPoolsResponse.Builder.class); - } - - public static final int WORKER_POOLS_FIELD_NUMBER = 1; - private java.util.List workerPools_; - /** - * - * - *
-   * `WorkerPools` for the specified project.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.WorkerPool worker_pools = 1; - */ - @java.lang.Override - public java.util.List getWorkerPoolsList() { - return workerPools_; - } - /** - * - * - *
-   * `WorkerPools` for the specified project.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.WorkerPool worker_pools = 1; - */ - @java.lang.Override - public java.util.List - getWorkerPoolsOrBuilderList() { - return workerPools_; - } - /** - * - * - *
-   * `WorkerPools` for the specified project.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.WorkerPool worker_pools = 1; - */ - @java.lang.Override - public int getWorkerPoolsCount() { - return workerPools_.size(); - } - /** - * - * - *
-   * `WorkerPools` for the specified project.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.WorkerPool worker_pools = 1; - */ - @java.lang.Override - public com.google.cloudbuild.v1.WorkerPool getWorkerPools(int index) { - return workerPools_.get(index); - } - /** - * - * - *
-   * `WorkerPools` for the specified project.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.WorkerPool worker_pools = 1; - */ - @java.lang.Override - public com.google.cloudbuild.v1.WorkerPoolOrBuilder getWorkerPoolsOrBuilder(int index) { - return workerPools_.get(index); - } - - public static final int NEXT_PAGE_TOKEN_FIELD_NUMBER = 2; - private volatile java.lang.Object nextPageToken_; - /** - * - * - *
-   * Continuation token used to page through large result sets. Provide this
-   * value in a subsequent ListWorkerPoolsRequest to return the next page of
-   * results.
-   * 
- * - * string next_page_token = 2; - * - * @return The nextPageToken. - */ - @java.lang.Override - public java.lang.String getNextPageToken() { - java.lang.Object ref = nextPageToken_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - nextPageToken_ = s; - return s; - } - } - /** - * - * - *
-   * Continuation token used to page through large result sets. Provide this
-   * value in a subsequent ListWorkerPoolsRequest to return the next page of
-   * results.
-   * 
- * - * string next_page_token = 2; - * - * @return The bytes for nextPageToken. - */ - @java.lang.Override - public com.google.protobuf.ByteString getNextPageTokenBytes() { - java.lang.Object ref = nextPageToken_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - nextPageToken_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - for (int i = 0; i < workerPools_.size(); i++) { - output.writeMessage(1, workerPools_.get(i)); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(nextPageToken_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, nextPageToken_); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - for (int i = 0; i < workerPools_.size(); i++) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, workerPools_.get(i)); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(nextPageToken_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, nextPageToken_); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.ListWorkerPoolsResponse)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.ListWorkerPoolsResponse other = - (com.google.cloudbuild.v1.ListWorkerPoolsResponse) obj; - - if (!getWorkerPoolsList().equals(other.getWorkerPoolsList())) return false; - if (!getNextPageToken().equals(other.getNextPageToken())) return false; - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (getWorkerPoolsCount() > 0) { - hash = (37 * hash) + WORKER_POOLS_FIELD_NUMBER; - hash = (53 * hash) + getWorkerPoolsList().hashCode(); - } - hash = (37 * hash) + NEXT_PAGE_TOKEN_FIELD_NUMBER; - hash = (53 * hash) + getNextPageToken().hashCode(); - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.ListWorkerPoolsResponse parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.ListWorkerPoolsResponse parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ListWorkerPoolsResponse parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.ListWorkerPoolsResponse parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ListWorkerPoolsResponse parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.ListWorkerPoolsResponse parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ListWorkerPoolsResponse parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.ListWorkerPoolsResponse parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ListWorkerPoolsResponse parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.ListWorkerPoolsResponse parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ListWorkerPoolsResponse parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.ListWorkerPoolsResponse parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.ListWorkerPoolsResponse prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * Response containing existing `WorkerPools`.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.ListWorkerPoolsResponse} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.ListWorkerPoolsResponse) - com.google.cloudbuild.v1.ListWorkerPoolsResponseOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ListWorkerPoolsResponse_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ListWorkerPoolsResponse_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.ListWorkerPoolsResponse.class, - com.google.cloudbuild.v1.ListWorkerPoolsResponse.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.ListWorkerPoolsResponse.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - if (workerPoolsBuilder_ == null) { - workerPools_ = java.util.Collections.emptyList(); - } else { - workerPools_ = null; - workerPoolsBuilder_.clear(); - } - bitField0_ = (bitField0_ & ~0x00000001); - nextPageToken_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ListWorkerPoolsResponse_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.ListWorkerPoolsResponse getDefaultInstanceForType() { - return com.google.cloudbuild.v1.ListWorkerPoolsResponse.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.ListWorkerPoolsResponse build() { - com.google.cloudbuild.v1.ListWorkerPoolsResponse result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.ListWorkerPoolsResponse buildPartial() { - com.google.cloudbuild.v1.ListWorkerPoolsResponse result = - new com.google.cloudbuild.v1.ListWorkerPoolsResponse(this); - int from_bitField0_ = bitField0_; - if (workerPoolsBuilder_ == null) { - if (((bitField0_ & 0x00000001) != 0)) { - workerPools_ = java.util.Collections.unmodifiableList(workerPools_); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.workerPools_ = workerPools_; - } else { - result.workerPools_ = workerPoolsBuilder_.build(); - } - result.nextPageToken_ = nextPageToken_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.ListWorkerPoolsResponse) { - return mergeFrom((com.google.cloudbuild.v1.ListWorkerPoolsResponse) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.ListWorkerPoolsResponse other) { - if (other == com.google.cloudbuild.v1.ListWorkerPoolsResponse.getDefaultInstance()) - return this; - if (workerPoolsBuilder_ == null) { - if (!other.workerPools_.isEmpty()) { - if (workerPools_.isEmpty()) { - workerPools_ = other.workerPools_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureWorkerPoolsIsMutable(); - workerPools_.addAll(other.workerPools_); - } - onChanged(); - } - } else { - if (!other.workerPools_.isEmpty()) { - if (workerPoolsBuilder_.isEmpty()) { - workerPoolsBuilder_.dispose(); - workerPoolsBuilder_ = null; - workerPools_ = other.workerPools_; - bitField0_ = (bitField0_ & ~0x00000001); - workerPoolsBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders - ? getWorkerPoolsFieldBuilder() - : null; - } else { - workerPoolsBuilder_.addAllMessages(other.workerPools_); - } - } - } - if (!other.getNextPageToken().isEmpty()) { - nextPageToken_ = other.nextPageToken_; - onChanged(); - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - com.google.cloudbuild.v1.WorkerPool m = - input.readMessage( - com.google.cloudbuild.v1.WorkerPool.parser(), extensionRegistry); - if (workerPoolsBuilder_ == null) { - ensureWorkerPoolsIsMutable(); - workerPools_.add(m); - } else { - workerPoolsBuilder_.addMessage(m); - } - break; - } // case 10 - case 18: - { - nextPageToken_ = input.readStringRequireUtf8(); - - break; - } // case 18 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private int bitField0_; - - private java.util.List workerPools_ = - java.util.Collections.emptyList(); - - private void ensureWorkerPoolsIsMutable() { - if (!((bitField0_ & 0x00000001) != 0)) { - workerPools_ = new java.util.ArrayList(workerPools_); - bitField0_ |= 0x00000001; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloudbuild.v1.WorkerPool, - com.google.cloudbuild.v1.WorkerPool.Builder, - com.google.cloudbuild.v1.WorkerPoolOrBuilder> - workerPoolsBuilder_; - - /** - * - * - *
-     * `WorkerPools` for the specified project.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.WorkerPool worker_pools = 1; - */ - public java.util.List getWorkerPoolsList() { - if (workerPoolsBuilder_ == null) { - return java.util.Collections.unmodifiableList(workerPools_); - } else { - return workerPoolsBuilder_.getMessageList(); - } - } - /** - * - * - *
-     * `WorkerPools` for the specified project.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.WorkerPool worker_pools = 1; - */ - public int getWorkerPoolsCount() { - if (workerPoolsBuilder_ == null) { - return workerPools_.size(); - } else { - return workerPoolsBuilder_.getCount(); - } - } - /** - * - * - *
-     * `WorkerPools` for the specified project.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.WorkerPool worker_pools = 1; - */ - public com.google.cloudbuild.v1.WorkerPool getWorkerPools(int index) { - if (workerPoolsBuilder_ == null) { - return workerPools_.get(index); - } else { - return workerPoolsBuilder_.getMessage(index); - } - } - /** - * - * - *
-     * `WorkerPools` for the specified project.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.WorkerPool worker_pools = 1; - */ - public Builder setWorkerPools(int index, com.google.cloudbuild.v1.WorkerPool value) { - if (workerPoolsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureWorkerPoolsIsMutable(); - workerPools_.set(index, value); - onChanged(); - } else { - workerPoolsBuilder_.setMessage(index, value); - } - return this; - } - /** - * - * - *
-     * `WorkerPools` for the specified project.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.WorkerPool worker_pools = 1; - */ - public Builder setWorkerPools( - int index, com.google.cloudbuild.v1.WorkerPool.Builder builderForValue) { - if (workerPoolsBuilder_ == null) { - ensureWorkerPoolsIsMutable(); - workerPools_.set(index, builderForValue.build()); - onChanged(); - } else { - workerPoolsBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * `WorkerPools` for the specified project.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.WorkerPool worker_pools = 1; - */ - public Builder addWorkerPools(com.google.cloudbuild.v1.WorkerPool value) { - if (workerPoolsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureWorkerPoolsIsMutable(); - workerPools_.add(value); - onChanged(); - } else { - workerPoolsBuilder_.addMessage(value); - } - return this; - } - /** - * - * - *
-     * `WorkerPools` for the specified project.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.WorkerPool worker_pools = 1; - */ - public Builder addWorkerPools(int index, com.google.cloudbuild.v1.WorkerPool value) { - if (workerPoolsBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureWorkerPoolsIsMutable(); - workerPools_.add(index, value); - onChanged(); - } else { - workerPoolsBuilder_.addMessage(index, value); - } - return this; - } - /** - * - * - *
-     * `WorkerPools` for the specified project.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.WorkerPool worker_pools = 1; - */ - public Builder addWorkerPools(com.google.cloudbuild.v1.WorkerPool.Builder builderForValue) { - if (workerPoolsBuilder_ == null) { - ensureWorkerPoolsIsMutable(); - workerPools_.add(builderForValue.build()); - onChanged(); - } else { - workerPoolsBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * `WorkerPools` for the specified project.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.WorkerPool worker_pools = 1; - */ - public Builder addWorkerPools( - int index, com.google.cloudbuild.v1.WorkerPool.Builder builderForValue) { - if (workerPoolsBuilder_ == null) { - ensureWorkerPoolsIsMutable(); - workerPools_.add(index, builderForValue.build()); - onChanged(); - } else { - workerPoolsBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * `WorkerPools` for the specified project.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.WorkerPool worker_pools = 1; - */ - public Builder addAllWorkerPools( - java.lang.Iterable values) { - if (workerPoolsBuilder_ == null) { - ensureWorkerPoolsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, workerPools_); - onChanged(); - } else { - workerPoolsBuilder_.addAllMessages(values); - } - return this; - } - /** - * - * - *
-     * `WorkerPools` for the specified project.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.WorkerPool worker_pools = 1; - */ - public Builder clearWorkerPools() { - if (workerPoolsBuilder_ == null) { - workerPools_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - } else { - workerPoolsBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * `WorkerPools` for the specified project.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.WorkerPool worker_pools = 1; - */ - public Builder removeWorkerPools(int index) { - if (workerPoolsBuilder_ == null) { - ensureWorkerPoolsIsMutable(); - workerPools_.remove(index); - onChanged(); - } else { - workerPoolsBuilder_.remove(index); - } - return this; - } - /** - * - * - *
-     * `WorkerPools` for the specified project.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.WorkerPool worker_pools = 1; - */ - public com.google.cloudbuild.v1.WorkerPool.Builder getWorkerPoolsBuilder(int index) { - return getWorkerPoolsFieldBuilder().getBuilder(index); - } - /** - * - * - *
-     * `WorkerPools` for the specified project.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.WorkerPool worker_pools = 1; - */ - public com.google.cloudbuild.v1.WorkerPoolOrBuilder getWorkerPoolsOrBuilder(int index) { - if (workerPoolsBuilder_ == null) { - return workerPools_.get(index); - } else { - return workerPoolsBuilder_.getMessageOrBuilder(index); - } - } - /** - * - * - *
-     * `WorkerPools` for the specified project.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.WorkerPool worker_pools = 1; - */ - public java.util.List - getWorkerPoolsOrBuilderList() { - if (workerPoolsBuilder_ != null) { - return workerPoolsBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(workerPools_); - } - } - /** - * - * - *
-     * `WorkerPools` for the specified project.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.WorkerPool worker_pools = 1; - */ - public com.google.cloudbuild.v1.WorkerPool.Builder addWorkerPoolsBuilder() { - return getWorkerPoolsFieldBuilder() - .addBuilder(com.google.cloudbuild.v1.WorkerPool.getDefaultInstance()); - } - /** - * - * - *
-     * `WorkerPools` for the specified project.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.WorkerPool worker_pools = 1; - */ - public com.google.cloudbuild.v1.WorkerPool.Builder addWorkerPoolsBuilder(int index) { - return getWorkerPoolsFieldBuilder() - .addBuilder(index, com.google.cloudbuild.v1.WorkerPool.getDefaultInstance()); - } - /** - * - * - *
-     * `WorkerPools` for the specified project.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.WorkerPool worker_pools = 1; - */ - public java.util.List getWorkerPoolsBuilderList() { - return getWorkerPoolsFieldBuilder().getBuilderList(); - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloudbuild.v1.WorkerPool, - com.google.cloudbuild.v1.WorkerPool.Builder, - com.google.cloudbuild.v1.WorkerPoolOrBuilder> - getWorkerPoolsFieldBuilder() { - if (workerPoolsBuilder_ == null) { - workerPoolsBuilder_ = - new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloudbuild.v1.WorkerPool, - com.google.cloudbuild.v1.WorkerPool.Builder, - com.google.cloudbuild.v1.WorkerPoolOrBuilder>( - workerPools_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); - workerPools_ = null; - } - return workerPoolsBuilder_; - } - - private java.lang.Object nextPageToken_ = ""; - /** - * - * - *
-     * Continuation token used to page through large result sets. Provide this
-     * value in a subsequent ListWorkerPoolsRequest to return the next page of
-     * results.
-     * 
- * - * string next_page_token = 2; - * - * @return The nextPageToken. - */ - public java.lang.String getNextPageToken() { - java.lang.Object ref = nextPageToken_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - nextPageToken_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Continuation token used to page through large result sets. Provide this
-     * value in a subsequent ListWorkerPoolsRequest to return the next page of
-     * results.
-     * 
- * - * string next_page_token = 2; - * - * @return The bytes for nextPageToken. - */ - public com.google.protobuf.ByteString getNextPageTokenBytes() { - java.lang.Object ref = nextPageToken_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - nextPageToken_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Continuation token used to page through large result sets. Provide this
-     * value in a subsequent ListWorkerPoolsRequest to return the next page of
-     * results.
-     * 
- * - * string next_page_token = 2; - * - * @param value The nextPageToken to set. - * @return This builder for chaining. - */ - public Builder setNextPageToken(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - nextPageToken_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Continuation token used to page through large result sets. Provide this
-     * value in a subsequent ListWorkerPoolsRequest to return the next page of
-     * results.
-     * 
- * - * string next_page_token = 2; - * - * @return This builder for chaining. - */ - public Builder clearNextPageToken() { - - nextPageToken_ = getDefaultInstance().getNextPageToken(); - onChanged(); - return this; - } - /** - * - * - *
-     * Continuation token used to page through large result sets. Provide this
-     * value in a subsequent ListWorkerPoolsRequest to return the next page of
-     * results.
-     * 
- * - * string next_page_token = 2; - * - * @param value The bytes for nextPageToken to set. - * @return This builder for chaining. - */ - public Builder setNextPageTokenBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - nextPageToken_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.ListWorkerPoolsResponse) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.ListWorkerPoolsResponse) - private static final com.google.cloudbuild.v1.ListWorkerPoolsResponse DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.ListWorkerPoolsResponse(); - } - - public static com.google.cloudbuild.v1.ListWorkerPoolsResponse getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public ListWorkerPoolsResponse parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.ListWorkerPoolsResponse getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListWorkerPoolsResponseOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListWorkerPoolsResponseOrBuilder.java deleted file mode 100644 index 003682c9..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListWorkerPoolsResponseOrBuilder.java +++ /dev/null @@ -1,106 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface ListWorkerPoolsResponseOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.ListWorkerPoolsResponse) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * `WorkerPools` for the specified project.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.WorkerPool worker_pools = 1; - */ - java.util.List getWorkerPoolsList(); - /** - * - * - *
-   * `WorkerPools` for the specified project.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.WorkerPool worker_pools = 1; - */ - com.google.cloudbuild.v1.WorkerPool getWorkerPools(int index); - /** - * - * - *
-   * `WorkerPools` for the specified project.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.WorkerPool worker_pools = 1; - */ - int getWorkerPoolsCount(); - /** - * - * - *
-   * `WorkerPools` for the specified project.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.WorkerPool worker_pools = 1; - */ - java.util.List - getWorkerPoolsOrBuilderList(); - /** - * - * - *
-   * `WorkerPools` for the specified project.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.WorkerPool worker_pools = 1; - */ - com.google.cloudbuild.v1.WorkerPoolOrBuilder getWorkerPoolsOrBuilder(int index); - - /** - * - * - *
-   * Continuation token used to page through large result sets. Provide this
-   * value in a subsequent ListWorkerPoolsRequest to return the next page of
-   * results.
-   * 
- * - * string next_page_token = 2; - * - * @return The nextPageToken. - */ - java.lang.String getNextPageToken(); - /** - * - * - *
-   * Continuation token used to page through large result sets. Provide this
-   * value in a subsequent ListWorkerPoolsRequest to return the next page of
-   * results.
-   * 
- * - * string next_page_token = 2; - * - * @return The bytes for nextPageToken. - */ - com.google.protobuf.ByteString getNextPageTokenBytes(); -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/LocationName.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/LocationName.java deleted file mode 100644 index 70891b2e..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/LocationName.java +++ /dev/null @@ -1,192 +0,0 @@ -/* - * Copyright 2022 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package com.google.cloudbuild.v1; - -import com.google.api.pathtemplate.PathTemplate; -import com.google.api.resourcenames.ResourceName; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; -import java.util.Objects; -import javax.annotation.Generated; - -// AUTO-GENERATED DOCUMENTATION AND CLASS. -@Generated("by gapic-generator-java") -public class LocationName implements ResourceName { - private static final PathTemplate PROJECT_LOCATION = - PathTemplate.createWithoutUrlEncoding("projects/{project}/locations/{location}"); - private volatile Map fieldValuesMap; - private final String project; - private final String location; - - @Deprecated - protected LocationName() { - project = null; - location = null; - } - - private LocationName(Builder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - location = Preconditions.checkNotNull(builder.getLocation()); - } - - public String getProject() { - return project; - } - - public String getLocation() { - return location; - } - - public static Builder newBuilder() { - return new Builder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - public static LocationName of(String project, String location) { - return newBuilder().setProject(project).setLocation(location).build(); - } - - public static String format(String project, String location) { - return newBuilder().setProject(project).setLocation(location).build().toString(); - } - - public static LocationName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - Map matchMap = - PROJECT_LOCATION.validatedMatch( - formattedString, "LocationName.parse: formattedString not in valid format"); - return of(matchMap.get("project"), matchMap.get("location")); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList<>(values.size()); - for (LocationName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PROJECT_LOCATION.matches(formattedString); - } - - @Override - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - if (project != null) { - fieldMapBuilder.put("project", project); - } - if (location != null) { - fieldMapBuilder.put("location", location); - } - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - @Override - public String toString() { - return PROJECT_LOCATION.instantiate("project", project, "location", location); - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o != null || getClass() == o.getClass()) { - LocationName that = ((LocationName) o); - return Objects.equals(this.project, that.project) - && Objects.equals(this.location, that.location); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= Objects.hashCode(project); - h *= 1000003; - h ^= Objects.hashCode(location); - return h; - } - - /** Builder for projects/{project}/locations/{location}. */ - public static class Builder { - private String project; - private String location; - - protected Builder() {} - - public String getProject() { - return project; - } - - public String getLocation() { - return location; - } - - public Builder setProject(String project) { - this.project = project; - return this; - } - - public Builder setLocation(String location) { - this.location = location; - return this; - } - - private Builder(LocationName locationName) { - this.project = locationName.project; - this.location = locationName.location; - } - - public LocationName build() { - return new LocationName(this); - } - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/PrivatePoolV1Config.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/PrivatePoolV1Config.java deleted file mode 100644 index b939aca1..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/PrivatePoolV1Config.java +++ /dev/null @@ -1,2876 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * Configuration for a V1 `PrivatePool`.
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.PrivatePoolV1Config} - */ -public final class PrivatePoolV1Config extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.PrivatePoolV1Config) - PrivatePoolV1ConfigOrBuilder { - private static final long serialVersionUID = 0L; - // Use PrivatePoolV1Config.newBuilder() to construct. - private PrivatePoolV1Config(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private PrivatePoolV1Config() {} - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new PrivatePoolV1Config(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_PrivatePoolV1Config_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_PrivatePoolV1Config_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.PrivatePoolV1Config.class, - com.google.cloudbuild.v1.PrivatePoolV1Config.Builder.class); - } - - public interface WorkerConfigOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-     * Machine type of a worker, such as `e2-medium`.
-     * See [Worker pool config
-     * file](https://cloud.google.com/build/docs/private-pools/worker-pool-config-file-schema).
-     * If left blank, Cloud Build will use a sensible default.
-     * 
- * - * string machine_type = 1; - * - * @return The machineType. - */ - java.lang.String getMachineType(); - /** - * - * - *
-     * Machine type of a worker, such as `e2-medium`.
-     * See [Worker pool config
-     * file](https://cloud.google.com/build/docs/private-pools/worker-pool-config-file-schema).
-     * If left blank, Cloud Build will use a sensible default.
-     * 
- * - * string machine_type = 1; - * - * @return The bytes for machineType. - */ - com.google.protobuf.ByteString getMachineTypeBytes(); - - /** - * - * - *
-     * Size of the disk attached to the worker, in GB.
-     * See [Worker pool config
-     * file](https://cloud.google.com/build/docs/private-pools/worker-pool-config-file-schema).
-     * Specify a value of up to 1000. If `0` is specified, Cloud Build will use
-     * a standard disk size.
-     * 
- * - * int64 disk_size_gb = 2; - * - * @return The diskSizeGb. - */ - long getDiskSizeGb(); - } - /** - * - * - *
-   * Defines the configuration to be used for creating workers in
-   * the pool.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig} - */ - public static final class WorkerConfig extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig) - WorkerConfigOrBuilder { - private static final long serialVersionUID = 0L; - // Use WorkerConfig.newBuilder() to construct. - private WorkerConfig(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private WorkerConfig() { - machineType_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new WorkerConfig(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_PrivatePoolV1Config_WorkerConfig_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_PrivatePoolV1Config_WorkerConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig.class, - com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig.Builder.class); - } - - public static final int MACHINE_TYPE_FIELD_NUMBER = 1; - private volatile java.lang.Object machineType_; - /** - * - * - *
-     * Machine type of a worker, such as `e2-medium`.
-     * See [Worker pool config
-     * file](https://cloud.google.com/build/docs/private-pools/worker-pool-config-file-schema).
-     * If left blank, Cloud Build will use a sensible default.
-     * 
- * - * string machine_type = 1; - * - * @return The machineType. - */ - @java.lang.Override - public java.lang.String getMachineType() { - java.lang.Object ref = machineType_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - machineType_ = s; - return s; - } - } - /** - * - * - *
-     * Machine type of a worker, such as `e2-medium`.
-     * See [Worker pool config
-     * file](https://cloud.google.com/build/docs/private-pools/worker-pool-config-file-schema).
-     * If left blank, Cloud Build will use a sensible default.
-     * 
- * - * string machine_type = 1; - * - * @return The bytes for machineType. - */ - @java.lang.Override - public com.google.protobuf.ByteString getMachineTypeBytes() { - java.lang.Object ref = machineType_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - machineType_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int DISK_SIZE_GB_FIELD_NUMBER = 2; - private long diskSizeGb_; - /** - * - * - *
-     * Size of the disk attached to the worker, in GB.
-     * See [Worker pool config
-     * file](https://cloud.google.com/build/docs/private-pools/worker-pool-config-file-schema).
-     * Specify a value of up to 1000. If `0` is specified, Cloud Build will use
-     * a standard disk size.
-     * 
- * - * int64 disk_size_gb = 2; - * - * @return The diskSizeGb. - */ - @java.lang.Override - public long getDiskSizeGb() { - return diskSizeGb_; - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(machineType_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, machineType_); - } - if (diskSizeGb_ != 0L) { - output.writeInt64(2, diskSizeGb_); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(machineType_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, machineType_); - } - if (diskSizeGb_ != 0L) { - size += com.google.protobuf.CodedOutputStream.computeInt64Size(2, diskSizeGb_); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig other = - (com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig) obj; - - if (!getMachineType().equals(other.getMachineType())) return false; - if (getDiskSizeGb() != other.getDiskSizeGb()) return false; - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + MACHINE_TYPE_FIELD_NUMBER; - hash = (53 * hash) + getMachineType().hashCode(); - hash = (37 * hash) + DISK_SIZE_GB_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getDiskSizeGb()); - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder( - com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-     * Defines the configuration to be used for creating workers in
-     * the pool.
-     * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig} - */ - public static final class Builder - extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig) - com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfigOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_PrivatePoolV1Config_WorkerConfig_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_PrivatePoolV1Config_WorkerConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig.class, - com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - machineType_ = ""; - - diskSizeGb_ = 0L; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_PrivatePoolV1Config_WorkerConfig_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig getDefaultInstanceForType() { - return com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig build() { - com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig buildPartial() { - com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig result = - new com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig(this); - result.machineType_ = machineType_; - result.diskSizeGb_ = diskSizeGb_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, - java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig) { - return mergeFrom((com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig other) { - if (other == com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig.getDefaultInstance()) - return this; - if (!other.getMachineType().isEmpty()) { - machineType_ = other.machineType_; - onChanged(); - } - if (other.getDiskSizeGb() != 0L) { - setDiskSizeGb(other.getDiskSizeGb()); - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - machineType_ = input.readStringRequireUtf8(); - - break; - } // case 10 - case 16: - { - diskSizeGb_ = input.readInt64(); - - break; - } // case 16 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private java.lang.Object machineType_ = ""; - /** - * - * - *
-       * Machine type of a worker, such as `e2-medium`.
-       * See [Worker pool config
-       * file](https://cloud.google.com/build/docs/private-pools/worker-pool-config-file-schema).
-       * If left blank, Cloud Build will use a sensible default.
-       * 
- * - * string machine_type = 1; - * - * @return The machineType. - */ - public java.lang.String getMachineType() { - java.lang.Object ref = machineType_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - machineType_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-       * Machine type of a worker, such as `e2-medium`.
-       * See [Worker pool config
-       * file](https://cloud.google.com/build/docs/private-pools/worker-pool-config-file-schema).
-       * If left blank, Cloud Build will use a sensible default.
-       * 
- * - * string machine_type = 1; - * - * @return The bytes for machineType. - */ - public com.google.protobuf.ByteString getMachineTypeBytes() { - java.lang.Object ref = machineType_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - machineType_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-       * Machine type of a worker, such as `e2-medium`.
-       * See [Worker pool config
-       * file](https://cloud.google.com/build/docs/private-pools/worker-pool-config-file-schema).
-       * If left blank, Cloud Build will use a sensible default.
-       * 
- * - * string machine_type = 1; - * - * @param value The machineType to set. - * @return This builder for chaining. - */ - public Builder setMachineType(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - machineType_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * Machine type of a worker, such as `e2-medium`.
-       * See [Worker pool config
-       * file](https://cloud.google.com/build/docs/private-pools/worker-pool-config-file-schema).
-       * If left blank, Cloud Build will use a sensible default.
-       * 
- * - * string machine_type = 1; - * - * @return This builder for chaining. - */ - public Builder clearMachineType() { - - machineType_ = getDefaultInstance().getMachineType(); - onChanged(); - return this; - } - /** - * - * - *
-       * Machine type of a worker, such as `e2-medium`.
-       * See [Worker pool config
-       * file](https://cloud.google.com/build/docs/private-pools/worker-pool-config-file-schema).
-       * If left blank, Cloud Build will use a sensible default.
-       * 
- * - * string machine_type = 1; - * - * @param value The bytes for machineType to set. - * @return This builder for chaining. - */ - public Builder setMachineTypeBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - machineType_ = value; - onChanged(); - return this; - } - - private long diskSizeGb_; - /** - * - * - *
-       * Size of the disk attached to the worker, in GB.
-       * See [Worker pool config
-       * file](https://cloud.google.com/build/docs/private-pools/worker-pool-config-file-schema).
-       * Specify a value of up to 1000. If `0` is specified, Cloud Build will use
-       * a standard disk size.
-       * 
- * - * int64 disk_size_gb = 2; - * - * @return The diskSizeGb. - */ - @java.lang.Override - public long getDiskSizeGb() { - return diskSizeGb_; - } - /** - * - * - *
-       * Size of the disk attached to the worker, in GB.
-       * See [Worker pool config
-       * file](https://cloud.google.com/build/docs/private-pools/worker-pool-config-file-schema).
-       * Specify a value of up to 1000. If `0` is specified, Cloud Build will use
-       * a standard disk size.
-       * 
- * - * int64 disk_size_gb = 2; - * - * @param value The diskSizeGb to set. - * @return This builder for chaining. - */ - public Builder setDiskSizeGb(long value) { - - diskSizeGb_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * Size of the disk attached to the worker, in GB.
-       * See [Worker pool config
-       * file](https://cloud.google.com/build/docs/private-pools/worker-pool-config-file-schema).
-       * Specify a value of up to 1000. If `0` is specified, Cloud Build will use
-       * a standard disk size.
-       * 
- * - * int64 disk_size_gb = 2; - * - * @return This builder for chaining. - */ - public Builder clearDiskSizeGb() { - - diskSizeGb_ = 0L; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig) - private static final com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig(); - } - - public static com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public WorkerConfig parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException() - .setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - } - - public interface NetworkConfigOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-     * Required. Immutable. The network definition that the workers are peered
-     * to. If this section is left empty, the workers will be peered to
-     * `WorkerPool.project_id` on the service producer network. Must be in the
-     * format `projects/{project}/global/networks/{network}`, where `{project}`
-     * is a project number, such as `12345`, and `{network}` is the name of a
-     * VPC network in the project. See
-     * [Understanding network configuration
-     * options](https://cloud.google.com/build/docs/private-pools/set-up-private-pool-environment)
-     * 
- * - * - * string peered_network = 1 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return The peeredNetwork. - */ - java.lang.String getPeeredNetwork(); - /** - * - * - *
-     * Required. Immutable. The network definition that the workers are peered
-     * to. If this section is left empty, the workers will be peered to
-     * `WorkerPool.project_id` on the service producer network. Must be in the
-     * format `projects/{project}/global/networks/{network}`, where `{project}`
-     * is a project number, such as `12345`, and `{network}` is the name of a
-     * VPC network in the project. See
-     * [Understanding network configuration
-     * options](https://cloud.google.com/build/docs/private-pools/set-up-private-pool-environment)
-     * 
- * - * - * string peered_network = 1 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return The bytes for peeredNetwork. - */ - com.google.protobuf.ByteString getPeeredNetworkBytes(); - - /** - * - * - *
-     * Option to configure network egress for the workers.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig.EgressOption egress_option = 2; - * - * - * @return The enum numeric value on the wire for egressOption. - */ - int getEgressOptionValue(); - /** - * - * - *
-     * Option to configure network egress for the workers.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig.EgressOption egress_option = 2; - * - * - * @return The egressOption. - */ - com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig.EgressOption getEgressOption(); - } - /** - * - * - *
-   * Defines the network configuration for the pool.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig} - */ - public static final class NetworkConfig extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig) - NetworkConfigOrBuilder { - private static final long serialVersionUID = 0L; - // Use NetworkConfig.newBuilder() to construct. - private NetworkConfig(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private NetworkConfig() { - peeredNetwork_ = ""; - egressOption_ = 0; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new NetworkConfig(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_PrivatePoolV1Config_NetworkConfig_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_PrivatePoolV1Config_NetworkConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig.class, - com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig.Builder.class); - } - - /** - * - * - *
-     * Defines the egress option for the pool.
-     * 
- * - * Protobuf enum {@code - * google.devtools.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig.EgressOption} - */ - public enum EgressOption implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
-       * If set, defaults to PUBLIC_EGRESS.
-       * 
- * - * EGRESS_OPTION_UNSPECIFIED = 0; - */ - EGRESS_OPTION_UNSPECIFIED(0), - /** - * - * - *
-       * If set, workers are created without any public address, which prevents
-       * network egress to public IPs unless a network proxy is configured.
-       * 
- * - * NO_PUBLIC_EGRESS = 1; - */ - NO_PUBLIC_EGRESS(1), - /** - * - * - *
-       * If set, workers are created with a public address which allows for
-       * public internet egress.
-       * 
- * - * PUBLIC_EGRESS = 2; - */ - PUBLIC_EGRESS(2), - UNRECOGNIZED(-1), - ; - - /** - * - * - *
-       * If set, defaults to PUBLIC_EGRESS.
-       * 
- * - * EGRESS_OPTION_UNSPECIFIED = 0; - */ - public static final int EGRESS_OPTION_UNSPECIFIED_VALUE = 0; - /** - * - * - *
-       * If set, workers are created without any public address, which prevents
-       * network egress to public IPs unless a network proxy is configured.
-       * 
- * - * NO_PUBLIC_EGRESS = 1; - */ - public static final int NO_PUBLIC_EGRESS_VALUE = 1; - /** - * - * - *
-       * If set, workers are created with a public address which allows for
-       * public internet egress.
-       * 
- * - * PUBLIC_EGRESS = 2; - */ - public static final int PUBLIC_EGRESS_VALUE = 2; - - public final int getNumber() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalArgumentException( - "Can't get the number of an unknown enum value."); - } - return value; - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static EgressOption valueOf(int value) { - return forNumber(value); - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - */ - public static EgressOption forNumber(int value) { - switch (value) { - case 0: - return EGRESS_OPTION_UNSPECIFIED; - case 1: - return NO_PUBLIC_EGRESS; - case 2: - return PUBLIC_EGRESS; - default: - return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { - return internalValueMap; - } - - private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public EgressOption findValueByNumber(int number) { - return EgressOption.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalStateException( - "Can't get the descriptor of an unrecognized enum value."); - } - return getDescriptor().getValues().get(ordinal()); - } - - public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { - return getDescriptor(); - } - - public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig.getDescriptor() - .getEnumTypes() - .get(0); - } - - private static final EgressOption[] VALUES = values(); - - public static EgressOption valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); - } - if (desc.getIndex() == -1) { - return UNRECOGNIZED; - } - return VALUES[desc.getIndex()]; - } - - private final int value; - - private EgressOption(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:google.devtools.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig.EgressOption) - } - - public static final int PEERED_NETWORK_FIELD_NUMBER = 1; - private volatile java.lang.Object peeredNetwork_; - /** - * - * - *
-     * Required. Immutable. The network definition that the workers are peered
-     * to. If this section is left empty, the workers will be peered to
-     * `WorkerPool.project_id` on the service producer network. Must be in the
-     * format `projects/{project}/global/networks/{network}`, where `{project}`
-     * is a project number, such as `12345`, and `{network}` is the name of a
-     * VPC network in the project. See
-     * [Understanding network configuration
-     * options](https://cloud.google.com/build/docs/private-pools/set-up-private-pool-environment)
-     * 
- * - * - * string peered_network = 1 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return The peeredNetwork. - */ - @java.lang.Override - public java.lang.String getPeeredNetwork() { - java.lang.Object ref = peeredNetwork_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - peeredNetwork_ = s; - return s; - } - } - /** - * - * - *
-     * Required. Immutable. The network definition that the workers are peered
-     * to. If this section is left empty, the workers will be peered to
-     * `WorkerPool.project_id` on the service producer network. Must be in the
-     * format `projects/{project}/global/networks/{network}`, where `{project}`
-     * is a project number, such as `12345`, and `{network}` is the name of a
-     * VPC network in the project. See
-     * [Understanding network configuration
-     * options](https://cloud.google.com/build/docs/private-pools/set-up-private-pool-environment)
-     * 
- * - * - * string peered_network = 1 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return The bytes for peeredNetwork. - */ - @java.lang.Override - public com.google.protobuf.ByteString getPeeredNetworkBytes() { - java.lang.Object ref = peeredNetwork_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - peeredNetwork_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int EGRESS_OPTION_FIELD_NUMBER = 2; - private int egressOption_; - /** - * - * - *
-     * Option to configure network egress for the workers.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig.EgressOption egress_option = 2; - * - * - * @return The enum numeric value on the wire for egressOption. - */ - @java.lang.Override - public int getEgressOptionValue() { - return egressOption_; - } - /** - * - * - *
-     * Option to configure network egress for the workers.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig.EgressOption egress_option = 2; - * - * - * @return The egressOption. - */ - @java.lang.Override - public com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig.EgressOption - getEgressOption() { - @SuppressWarnings("deprecation") - com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig.EgressOption result = - com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig.EgressOption.valueOf( - egressOption_); - return result == null - ? com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig.EgressOption.UNRECOGNIZED - : result; - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(peeredNetwork_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, peeredNetwork_); - } - if (egressOption_ - != com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig.EgressOption - .EGRESS_OPTION_UNSPECIFIED - .getNumber()) { - output.writeEnum(2, egressOption_); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(peeredNetwork_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, peeredNetwork_); - } - if (egressOption_ - != com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig.EgressOption - .EGRESS_OPTION_UNSPECIFIED - .getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(2, egressOption_); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig other = - (com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig) obj; - - if (!getPeeredNetwork().equals(other.getPeeredNetwork())) return false; - if (egressOption_ != other.egressOption_) return false; - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + PEERED_NETWORK_FIELD_NUMBER; - hash = (53 * hash) + getPeeredNetwork().hashCode(); - hash = (37 * hash) + EGRESS_OPTION_FIELD_NUMBER; - hash = (53 * hash) + egressOption_; - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder( - com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-     * Defines the network configuration for the pool.
-     * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig} - */ - public static final class Builder - extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig) - com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfigOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_PrivatePoolV1Config_NetworkConfig_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_PrivatePoolV1Config_NetworkConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig.class, - com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - peeredNetwork_ = ""; - - egressOption_ = 0; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_PrivatePoolV1Config_NetworkConfig_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig - getDefaultInstanceForType() { - return com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig build() { - com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig buildPartial() { - com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig result = - new com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig(this); - result.peeredNetwork_ = peeredNetwork_; - result.egressOption_ = egressOption_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, - java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig) { - return mergeFrom((com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig other) { - if (other - == com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig.getDefaultInstance()) - return this; - if (!other.getPeeredNetwork().isEmpty()) { - peeredNetwork_ = other.peeredNetwork_; - onChanged(); - } - if (other.egressOption_ != 0) { - setEgressOptionValue(other.getEgressOptionValue()); - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - peeredNetwork_ = input.readStringRequireUtf8(); - - break; - } // case 10 - case 16: - { - egressOption_ = input.readEnum(); - - break; - } // case 16 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private java.lang.Object peeredNetwork_ = ""; - /** - * - * - *
-       * Required. Immutable. The network definition that the workers are peered
-       * to. If this section is left empty, the workers will be peered to
-       * `WorkerPool.project_id` on the service producer network. Must be in the
-       * format `projects/{project}/global/networks/{network}`, where `{project}`
-       * is a project number, such as `12345`, and `{network}` is the name of a
-       * VPC network in the project. See
-       * [Understanding network configuration
-       * options](https://cloud.google.com/build/docs/private-pools/set-up-private-pool-environment)
-       * 
- * - * - * string peered_network = 1 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return The peeredNetwork. - */ - public java.lang.String getPeeredNetwork() { - java.lang.Object ref = peeredNetwork_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - peeredNetwork_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-       * Required. Immutable. The network definition that the workers are peered
-       * to. If this section is left empty, the workers will be peered to
-       * `WorkerPool.project_id` on the service producer network. Must be in the
-       * format `projects/{project}/global/networks/{network}`, where `{project}`
-       * is a project number, such as `12345`, and `{network}` is the name of a
-       * VPC network in the project. See
-       * [Understanding network configuration
-       * options](https://cloud.google.com/build/docs/private-pools/set-up-private-pool-environment)
-       * 
- * - * - * string peered_network = 1 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return The bytes for peeredNetwork. - */ - public com.google.protobuf.ByteString getPeeredNetworkBytes() { - java.lang.Object ref = peeredNetwork_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - peeredNetwork_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-       * Required. Immutable. The network definition that the workers are peered
-       * to. If this section is left empty, the workers will be peered to
-       * `WorkerPool.project_id` on the service producer network. Must be in the
-       * format `projects/{project}/global/networks/{network}`, where `{project}`
-       * is a project number, such as `12345`, and `{network}` is the name of a
-       * VPC network in the project. See
-       * [Understanding network configuration
-       * options](https://cloud.google.com/build/docs/private-pools/set-up-private-pool-environment)
-       * 
- * - * - * string peered_network = 1 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @param value The peeredNetwork to set. - * @return This builder for chaining. - */ - public Builder setPeeredNetwork(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - peeredNetwork_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * Required. Immutable. The network definition that the workers are peered
-       * to. If this section is left empty, the workers will be peered to
-       * `WorkerPool.project_id` on the service producer network. Must be in the
-       * format `projects/{project}/global/networks/{network}`, where `{project}`
-       * is a project number, such as `12345`, and `{network}` is the name of a
-       * VPC network in the project. See
-       * [Understanding network configuration
-       * options](https://cloud.google.com/build/docs/private-pools/set-up-private-pool-environment)
-       * 
- * - * - * string peered_network = 1 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return This builder for chaining. - */ - public Builder clearPeeredNetwork() { - - peeredNetwork_ = getDefaultInstance().getPeeredNetwork(); - onChanged(); - return this; - } - /** - * - * - *
-       * Required. Immutable. The network definition that the workers are peered
-       * to. If this section is left empty, the workers will be peered to
-       * `WorkerPool.project_id` on the service producer network. Must be in the
-       * format `projects/{project}/global/networks/{network}`, where `{project}`
-       * is a project number, such as `12345`, and `{network}` is the name of a
-       * VPC network in the project. See
-       * [Understanding network configuration
-       * options](https://cloud.google.com/build/docs/private-pools/set-up-private-pool-environment)
-       * 
- * - * - * string peered_network = 1 [(.google.api.field_behavior) = IMMUTABLE, (.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @param value The bytes for peeredNetwork to set. - * @return This builder for chaining. - */ - public Builder setPeeredNetworkBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - peeredNetwork_ = value; - onChanged(); - return this; - } - - private int egressOption_ = 0; - /** - * - * - *
-       * Option to configure network egress for the workers.
-       * 
- * - * - * .google.devtools.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig.EgressOption egress_option = 2; - * - * - * @return The enum numeric value on the wire for egressOption. - */ - @java.lang.Override - public int getEgressOptionValue() { - return egressOption_; - } - /** - * - * - *
-       * Option to configure network egress for the workers.
-       * 
- * - * - * .google.devtools.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig.EgressOption egress_option = 2; - * - * - * @param value The enum numeric value on the wire for egressOption to set. - * @return This builder for chaining. - */ - public Builder setEgressOptionValue(int value) { - - egressOption_ = value; - onChanged(); - return this; - } - /** - * - * - *
-       * Option to configure network egress for the workers.
-       * 
- * - * - * .google.devtools.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig.EgressOption egress_option = 2; - * - * - * @return The egressOption. - */ - @java.lang.Override - public com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig.EgressOption - getEgressOption() { - @SuppressWarnings("deprecation") - com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig.EgressOption result = - com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig.EgressOption.valueOf( - egressOption_); - return result == null - ? com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig.EgressOption.UNRECOGNIZED - : result; - } - /** - * - * - *
-       * Option to configure network egress for the workers.
-       * 
- * - * - * .google.devtools.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig.EgressOption egress_option = 2; - * - * - * @param value The egressOption to set. - * @return This builder for chaining. - */ - public Builder setEgressOption( - com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig.EgressOption value) { - if (value == null) { - throw new NullPointerException(); - } - - egressOption_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-       * Option to configure network egress for the workers.
-       * 
- * - * - * .google.devtools.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig.EgressOption egress_option = 2; - * - * - * @return This builder for chaining. - */ - public Builder clearEgressOption() { - - egressOption_ = 0; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig) - private static final com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig - DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig(); - } - - public static com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public NetworkConfig parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException() - .setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } - } - - public static final int WORKER_CONFIG_FIELD_NUMBER = 1; - private com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig workerConfig_; - /** - * - * - *
-   * Machine configuration for the workers in the pool.
-   * 
- * - * .google.devtools.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig worker_config = 1; - * - * @return Whether the workerConfig field is set. - */ - @java.lang.Override - public boolean hasWorkerConfig() { - return workerConfig_ != null; - } - /** - * - * - *
-   * Machine configuration for the workers in the pool.
-   * 
- * - * .google.devtools.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig worker_config = 1; - * - * @return The workerConfig. - */ - @java.lang.Override - public com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig getWorkerConfig() { - return workerConfig_ == null - ? com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig.getDefaultInstance() - : workerConfig_; - } - /** - * - * - *
-   * Machine configuration for the workers in the pool.
-   * 
- * - * .google.devtools.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig worker_config = 1; - */ - @java.lang.Override - public com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfigOrBuilder - getWorkerConfigOrBuilder() { - return getWorkerConfig(); - } - - public static final int NETWORK_CONFIG_FIELD_NUMBER = 2; - private com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig networkConfig_; - /** - * - * - *
-   * Network configuration for the pool.
-   * 
- * - * .google.devtools.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig network_config = 2; - * - * - * @return Whether the networkConfig field is set. - */ - @java.lang.Override - public boolean hasNetworkConfig() { - return networkConfig_ != null; - } - /** - * - * - *
-   * Network configuration for the pool.
-   * 
- * - * .google.devtools.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig network_config = 2; - * - * - * @return The networkConfig. - */ - @java.lang.Override - public com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig getNetworkConfig() { - return networkConfig_ == null - ? com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig.getDefaultInstance() - : networkConfig_; - } - /** - * - * - *
-   * Network configuration for the pool.
-   * 
- * - * .google.devtools.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig network_config = 2; - * - */ - @java.lang.Override - public com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfigOrBuilder - getNetworkConfigOrBuilder() { - return getNetworkConfig(); - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (workerConfig_ != null) { - output.writeMessage(1, getWorkerConfig()); - } - if (networkConfig_ != null) { - output.writeMessage(2, getNetworkConfig()); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (workerConfig_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getWorkerConfig()); - } - if (networkConfig_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getNetworkConfig()); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.PrivatePoolV1Config)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.PrivatePoolV1Config other = - (com.google.cloudbuild.v1.PrivatePoolV1Config) obj; - - if (hasWorkerConfig() != other.hasWorkerConfig()) return false; - if (hasWorkerConfig()) { - if (!getWorkerConfig().equals(other.getWorkerConfig())) return false; - } - if (hasNetworkConfig() != other.hasNetworkConfig()) return false; - if (hasNetworkConfig()) { - if (!getNetworkConfig().equals(other.getNetworkConfig())) return false; - } - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasWorkerConfig()) { - hash = (37 * hash) + WORKER_CONFIG_FIELD_NUMBER; - hash = (53 * hash) + getWorkerConfig().hashCode(); - } - if (hasNetworkConfig()) { - hash = (37 * hash) + NETWORK_CONFIG_FIELD_NUMBER; - hash = (53 * hash) + getNetworkConfig().hashCode(); - } - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.PrivatePoolV1Config parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.PrivatePoolV1Config parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.PrivatePoolV1Config parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.PrivatePoolV1Config parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.PrivatePoolV1Config parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.PrivatePoolV1Config parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.PrivatePoolV1Config parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.PrivatePoolV1Config parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.PrivatePoolV1Config parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.PrivatePoolV1Config parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.PrivatePoolV1Config parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.PrivatePoolV1Config parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.PrivatePoolV1Config prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * Configuration for a V1 `PrivatePool`.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.PrivatePoolV1Config} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.PrivatePoolV1Config) - com.google.cloudbuild.v1.PrivatePoolV1ConfigOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_PrivatePoolV1Config_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_PrivatePoolV1Config_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.PrivatePoolV1Config.class, - com.google.cloudbuild.v1.PrivatePoolV1Config.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.PrivatePoolV1Config.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - if (workerConfigBuilder_ == null) { - workerConfig_ = null; - } else { - workerConfig_ = null; - workerConfigBuilder_ = null; - } - if (networkConfigBuilder_ == null) { - networkConfig_ = null; - } else { - networkConfig_ = null; - networkConfigBuilder_ = null; - } - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_PrivatePoolV1Config_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.PrivatePoolV1Config getDefaultInstanceForType() { - return com.google.cloudbuild.v1.PrivatePoolV1Config.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.PrivatePoolV1Config build() { - com.google.cloudbuild.v1.PrivatePoolV1Config result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.PrivatePoolV1Config buildPartial() { - com.google.cloudbuild.v1.PrivatePoolV1Config result = - new com.google.cloudbuild.v1.PrivatePoolV1Config(this); - if (workerConfigBuilder_ == null) { - result.workerConfig_ = workerConfig_; - } else { - result.workerConfig_ = workerConfigBuilder_.build(); - } - if (networkConfigBuilder_ == null) { - result.networkConfig_ = networkConfig_; - } else { - result.networkConfig_ = networkConfigBuilder_.build(); - } - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.PrivatePoolV1Config) { - return mergeFrom((com.google.cloudbuild.v1.PrivatePoolV1Config) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.PrivatePoolV1Config other) { - if (other == com.google.cloudbuild.v1.PrivatePoolV1Config.getDefaultInstance()) return this; - if (other.hasWorkerConfig()) { - mergeWorkerConfig(other.getWorkerConfig()); - } - if (other.hasNetworkConfig()) { - mergeNetworkConfig(other.getNetworkConfig()); - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - input.readMessage(getWorkerConfigFieldBuilder().getBuilder(), extensionRegistry); - - break; - } // case 10 - case 18: - { - input.readMessage(getNetworkConfigFieldBuilder().getBuilder(), extensionRegistry); - - break; - } // case 18 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig workerConfig_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig, - com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig.Builder, - com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfigOrBuilder> - workerConfigBuilder_; - /** - * - * - *
-     * Machine configuration for the workers in the pool.
-     * 
- * - * .google.devtools.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig worker_config = 1; - * - * - * @return Whether the workerConfig field is set. - */ - public boolean hasWorkerConfig() { - return workerConfigBuilder_ != null || workerConfig_ != null; - } - /** - * - * - *
-     * Machine configuration for the workers in the pool.
-     * 
- * - * .google.devtools.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig worker_config = 1; - * - * - * @return The workerConfig. - */ - public com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig getWorkerConfig() { - if (workerConfigBuilder_ == null) { - return workerConfig_ == null - ? com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig.getDefaultInstance() - : workerConfig_; - } else { - return workerConfigBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Machine configuration for the workers in the pool.
-     * 
- * - * .google.devtools.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig worker_config = 1; - * - */ - public Builder setWorkerConfig( - com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig value) { - if (workerConfigBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - workerConfig_ = value; - onChanged(); - } else { - workerConfigBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * Machine configuration for the workers in the pool.
-     * 
- * - * .google.devtools.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig worker_config = 1; - * - */ - public Builder setWorkerConfig( - com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig.Builder builderForValue) { - if (workerConfigBuilder_ == null) { - workerConfig_ = builderForValue.build(); - onChanged(); - } else { - workerConfigBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Machine configuration for the workers in the pool.
-     * 
- * - * .google.devtools.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig worker_config = 1; - * - */ - public Builder mergeWorkerConfig( - com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig value) { - if (workerConfigBuilder_ == null) { - if (workerConfig_ != null) { - workerConfig_ = - com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig.newBuilder(workerConfig_) - .mergeFrom(value) - .buildPartial(); - } else { - workerConfig_ = value; - } - onChanged(); - } else { - workerConfigBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * Machine configuration for the workers in the pool.
-     * 
- * - * .google.devtools.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig worker_config = 1; - * - */ - public Builder clearWorkerConfig() { - if (workerConfigBuilder_ == null) { - workerConfig_ = null; - onChanged(); - } else { - workerConfig_ = null; - workerConfigBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Machine configuration for the workers in the pool.
-     * 
- * - * .google.devtools.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig worker_config = 1; - * - */ - public com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig.Builder - getWorkerConfigBuilder() { - - onChanged(); - return getWorkerConfigFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Machine configuration for the workers in the pool.
-     * 
- * - * .google.devtools.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig worker_config = 1; - * - */ - public com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfigOrBuilder - getWorkerConfigOrBuilder() { - if (workerConfigBuilder_ != null) { - return workerConfigBuilder_.getMessageOrBuilder(); - } else { - return workerConfig_ == null - ? com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig.getDefaultInstance() - : workerConfig_; - } - } - /** - * - * - *
-     * Machine configuration for the workers in the pool.
-     * 
- * - * .google.devtools.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig worker_config = 1; - * - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig, - com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig.Builder, - com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfigOrBuilder> - getWorkerConfigFieldBuilder() { - if (workerConfigBuilder_ == null) { - workerConfigBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig, - com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig.Builder, - com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfigOrBuilder>( - getWorkerConfig(), getParentForChildren(), isClean()); - workerConfig_ = null; - } - return workerConfigBuilder_; - } - - private com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig networkConfig_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig, - com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig.Builder, - com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfigOrBuilder> - networkConfigBuilder_; - /** - * - * - *
-     * Network configuration for the pool.
-     * 
- * - * .google.devtools.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig network_config = 2; - * - * - * @return Whether the networkConfig field is set. - */ - public boolean hasNetworkConfig() { - return networkConfigBuilder_ != null || networkConfig_ != null; - } - /** - * - * - *
-     * Network configuration for the pool.
-     * 
- * - * .google.devtools.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig network_config = 2; - * - * - * @return The networkConfig. - */ - public com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig getNetworkConfig() { - if (networkConfigBuilder_ == null) { - return networkConfig_ == null - ? com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig.getDefaultInstance() - : networkConfig_; - } else { - return networkConfigBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Network configuration for the pool.
-     * 
- * - * .google.devtools.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig network_config = 2; - * - */ - public Builder setNetworkConfig( - com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig value) { - if (networkConfigBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - networkConfig_ = value; - onChanged(); - } else { - networkConfigBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * Network configuration for the pool.
-     * 
- * - * .google.devtools.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig network_config = 2; - * - */ - public Builder setNetworkConfig( - com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig.Builder builderForValue) { - if (networkConfigBuilder_ == null) { - networkConfig_ = builderForValue.build(); - onChanged(); - } else { - networkConfigBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Network configuration for the pool.
-     * 
- * - * .google.devtools.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig network_config = 2; - * - */ - public Builder mergeNetworkConfig( - com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig value) { - if (networkConfigBuilder_ == null) { - if (networkConfig_ != null) { - networkConfig_ = - com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig.newBuilder(networkConfig_) - .mergeFrom(value) - .buildPartial(); - } else { - networkConfig_ = value; - } - onChanged(); - } else { - networkConfigBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * Network configuration for the pool.
-     * 
- * - * .google.devtools.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig network_config = 2; - * - */ - public Builder clearNetworkConfig() { - if (networkConfigBuilder_ == null) { - networkConfig_ = null; - onChanged(); - } else { - networkConfig_ = null; - networkConfigBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Network configuration for the pool.
-     * 
- * - * .google.devtools.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig network_config = 2; - * - */ - public com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig.Builder - getNetworkConfigBuilder() { - - onChanged(); - return getNetworkConfigFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Network configuration for the pool.
-     * 
- * - * .google.devtools.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig network_config = 2; - * - */ - public com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfigOrBuilder - getNetworkConfigOrBuilder() { - if (networkConfigBuilder_ != null) { - return networkConfigBuilder_.getMessageOrBuilder(); - } else { - return networkConfig_ == null - ? com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig.getDefaultInstance() - : networkConfig_; - } - } - /** - * - * - *
-     * Network configuration for the pool.
-     * 
- * - * .google.devtools.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig network_config = 2; - * - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig, - com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig.Builder, - com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfigOrBuilder> - getNetworkConfigFieldBuilder() { - if (networkConfigBuilder_ == null) { - networkConfigBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig, - com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig.Builder, - com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfigOrBuilder>( - getNetworkConfig(), getParentForChildren(), isClean()); - networkConfig_ = null; - } - return networkConfigBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.PrivatePoolV1Config) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.PrivatePoolV1Config) - private static final com.google.cloudbuild.v1.PrivatePoolV1Config DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.PrivatePoolV1Config(); - } - - public static com.google.cloudbuild.v1.PrivatePoolV1Config getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public PrivatePoolV1Config parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.PrivatePoolV1Config getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/PrivatePoolV1ConfigOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/PrivatePoolV1ConfigOrBuilder.java deleted file mode 100644 index 14d14d9f..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/PrivatePoolV1ConfigOrBuilder.java +++ /dev/null @@ -1,98 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface PrivatePoolV1ConfigOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.PrivatePoolV1Config) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * Machine configuration for the workers in the pool.
-   * 
- * - * .google.devtools.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig worker_config = 1; - * - * @return Whether the workerConfig field is set. - */ - boolean hasWorkerConfig(); - /** - * - * - *
-   * Machine configuration for the workers in the pool.
-   * 
- * - * .google.devtools.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig worker_config = 1; - * - * @return The workerConfig. - */ - com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig getWorkerConfig(); - /** - * - * - *
-   * Machine configuration for the workers in the pool.
-   * 
- * - * .google.devtools.cloudbuild.v1.PrivatePoolV1Config.WorkerConfig worker_config = 1; - */ - com.google.cloudbuild.v1.PrivatePoolV1Config.WorkerConfigOrBuilder getWorkerConfigOrBuilder(); - - /** - * - * - *
-   * Network configuration for the pool.
-   * 
- * - * .google.devtools.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig network_config = 2; - * - * - * @return Whether the networkConfig field is set. - */ - boolean hasNetworkConfig(); - /** - * - * - *
-   * Network configuration for the pool.
-   * 
- * - * .google.devtools.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig network_config = 2; - * - * - * @return The networkConfig. - */ - com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig getNetworkConfig(); - /** - * - * - *
-   * Network configuration for the pool.
-   * 
- * - * .google.devtools.cloudbuild.v1.PrivatePoolV1Config.NetworkConfig network_config = 2; - * - */ - com.google.cloudbuild.v1.PrivatePoolV1Config.NetworkConfigOrBuilder getNetworkConfigOrBuilder(); -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/PubsubConfig.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/PubsubConfig.java deleted file mode 100644 index 8f06a140..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/PubsubConfig.java +++ /dev/null @@ -1,1356 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * PubsubConfig describes the configuration of a trigger that
- * creates a build whenever a Pub/Sub message is published.
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.PubsubConfig} - */ -public final class PubsubConfig extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.PubsubConfig) - PubsubConfigOrBuilder { - private static final long serialVersionUID = 0L; - // Use PubsubConfig.newBuilder() to construct. - private PubsubConfig(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private PubsubConfig() { - subscription_ = ""; - topic_ = ""; - serviceAccountEmail_ = ""; - state_ = 0; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new PubsubConfig(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_PubsubConfig_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_PubsubConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.PubsubConfig.class, - com.google.cloudbuild.v1.PubsubConfig.Builder.class); - } - - /** - * - * - *
-   * Enumerates potential issues with the underlying Pub/Sub subscription
-   * configuration.
-   * 
- * - * Protobuf enum {@code google.devtools.cloudbuild.v1.PubsubConfig.State} - */ - public enum State implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
-     * The subscription configuration has not been checked.
-     * 
- * - * STATE_UNSPECIFIED = 0; - */ - STATE_UNSPECIFIED(0), - /** - * - * - *
-     * The Pub/Sub subscription is properly configured.
-     * 
- * - * OK = 1; - */ - OK(1), - /** - * - * - *
-     * The subscription has been deleted.
-     * 
- * - * SUBSCRIPTION_DELETED = 2; - */ - SUBSCRIPTION_DELETED(2), - /** - * - * - *
-     * The topic has been deleted.
-     * 
- * - * TOPIC_DELETED = 3; - */ - TOPIC_DELETED(3), - /** - * - * - *
-     * Some of the subscription's field are misconfigured.
-     * 
- * - * SUBSCRIPTION_MISCONFIGURED = 4; - */ - SUBSCRIPTION_MISCONFIGURED(4), - UNRECOGNIZED(-1), - ; - - /** - * - * - *
-     * The subscription configuration has not been checked.
-     * 
- * - * STATE_UNSPECIFIED = 0; - */ - public static final int STATE_UNSPECIFIED_VALUE = 0; - /** - * - * - *
-     * The Pub/Sub subscription is properly configured.
-     * 
- * - * OK = 1; - */ - public static final int OK_VALUE = 1; - /** - * - * - *
-     * The subscription has been deleted.
-     * 
- * - * SUBSCRIPTION_DELETED = 2; - */ - public static final int SUBSCRIPTION_DELETED_VALUE = 2; - /** - * - * - *
-     * The topic has been deleted.
-     * 
- * - * TOPIC_DELETED = 3; - */ - public static final int TOPIC_DELETED_VALUE = 3; - /** - * - * - *
-     * Some of the subscription's field are misconfigured.
-     * 
- * - * SUBSCRIPTION_MISCONFIGURED = 4; - */ - public static final int SUBSCRIPTION_MISCONFIGURED_VALUE = 4; - - public final int getNumber() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalArgumentException( - "Can't get the number of an unknown enum value."); - } - return value; - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static State valueOf(int value) { - return forNumber(value); - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - */ - public static State forNumber(int value) { - switch (value) { - case 0: - return STATE_UNSPECIFIED; - case 1: - return OK; - case 2: - return SUBSCRIPTION_DELETED; - case 3: - return TOPIC_DELETED; - case 4: - return SUBSCRIPTION_MISCONFIGURED; - default: - return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { - return internalValueMap; - } - - private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public State findValueByNumber(int number) { - return State.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalStateException( - "Can't get the descriptor of an unrecognized enum value."); - } - return getDescriptor().getValues().get(ordinal()); - } - - public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { - return getDescriptor(); - } - - public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return com.google.cloudbuild.v1.PubsubConfig.getDescriptor().getEnumTypes().get(0); - } - - private static final State[] VALUES = values(); - - public static State valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); - } - if (desc.getIndex() == -1) { - return UNRECOGNIZED; - } - return VALUES[desc.getIndex()]; - } - - private final int value; - - private State(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:google.devtools.cloudbuild.v1.PubsubConfig.State) - } - - public static final int SUBSCRIPTION_FIELD_NUMBER = 1; - private volatile java.lang.Object subscription_; - /** - * - * - *
-   * Output only. Name of the subscription. Format is
-   * `projects/{project}/subscriptions/{subscription}`.
-   * 
- * - * - * string subscription = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } - * - * - * @return The subscription. - */ - @java.lang.Override - public java.lang.String getSubscription() { - java.lang.Object ref = subscription_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - subscription_ = s; - return s; - } - } - /** - * - * - *
-   * Output only. Name of the subscription. Format is
-   * `projects/{project}/subscriptions/{subscription}`.
-   * 
- * - * - * string subscription = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } - * - * - * @return The bytes for subscription. - */ - @java.lang.Override - public com.google.protobuf.ByteString getSubscriptionBytes() { - java.lang.Object ref = subscription_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - subscription_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int TOPIC_FIELD_NUMBER = 2; - private volatile java.lang.Object topic_; - /** - * - * - *
-   * The name of the topic from which this subscription is receiving messages.
-   * Format is `projects/{project}/topics/{topic}`.
-   * 
- * - * string topic = 2 [(.google.api.resource_reference) = { ... } - * - * @return The topic. - */ - @java.lang.Override - public java.lang.String getTopic() { - java.lang.Object ref = topic_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - topic_ = s; - return s; - } - } - /** - * - * - *
-   * The name of the topic from which this subscription is receiving messages.
-   * Format is `projects/{project}/topics/{topic}`.
-   * 
- * - * string topic = 2 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for topic. - */ - @java.lang.Override - public com.google.protobuf.ByteString getTopicBytes() { - java.lang.Object ref = topic_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - topic_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int SERVICE_ACCOUNT_EMAIL_FIELD_NUMBER = 3; - private volatile java.lang.Object serviceAccountEmail_; - /** - * - * - *
-   * Service account that will make the push request.
-   * 
- * - * string service_account_email = 3 [(.google.api.resource_reference) = { ... } - * - * @return The serviceAccountEmail. - */ - @java.lang.Override - public java.lang.String getServiceAccountEmail() { - java.lang.Object ref = serviceAccountEmail_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - serviceAccountEmail_ = s; - return s; - } - } - /** - * - * - *
-   * Service account that will make the push request.
-   * 
- * - * string service_account_email = 3 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for serviceAccountEmail. - */ - @java.lang.Override - public com.google.protobuf.ByteString getServiceAccountEmailBytes() { - java.lang.Object ref = serviceAccountEmail_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - serviceAccountEmail_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int STATE_FIELD_NUMBER = 4; - private int state_; - /** - * - * - *
-   * Potential issues with the underlying Pub/Sub subscription configuration.
-   * Only populated on get requests.
-   * 
- * - * .google.devtools.cloudbuild.v1.PubsubConfig.State state = 4; - * - * @return The enum numeric value on the wire for state. - */ - @java.lang.Override - public int getStateValue() { - return state_; - } - /** - * - * - *
-   * Potential issues with the underlying Pub/Sub subscription configuration.
-   * Only populated on get requests.
-   * 
- * - * .google.devtools.cloudbuild.v1.PubsubConfig.State state = 4; - * - * @return The state. - */ - @java.lang.Override - public com.google.cloudbuild.v1.PubsubConfig.State getState() { - @SuppressWarnings("deprecation") - com.google.cloudbuild.v1.PubsubConfig.State result = - com.google.cloudbuild.v1.PubsubConfig.State.valueOf(state_); - return result == null ? com.google.cloudbuild.v1.PubsubConfig.State.UNRECOGNIZED : result; - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(subscription_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, subscription_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(topic_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, topic_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(serviceAccountEmail_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 3, serviceAccountEmail_); - } - if (state_ != com.google.cloudbuild.v1.PubsubConfig.State.STATE_UNSPECIFIED.getNumber()) { - output.writeEnum(4, state_); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(subscription_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, subscription_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(topic_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, topic_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(serviceAccountEmail_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, serviceAccountEmail_); - } - if (state_ != com.google.cloudbuild.v1.PubsubConfig.State.STATE_UNSPECIFIED.getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(4, state_); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.PubsubConfig)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.PubsubConfig other = (com.google.cloudbuild.v1.PubsubConfig) obj; - - if (!getSubscription().equals(other.getSubscription())) return false; - if (!getTopic().equals(other.getTopic())) return false; - if (!getServiceAccountEmail().equals(other.getServiceAccountEmail())) return false; - if (state_ != other.state_) return false; - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + SUBSCRIPTION_FIELD_NUMBER; - hash = (53 * hash) + getSubscription().hashCode(); - hash = (37 * hash) + TOPIC_FIELD_NUMBER; - hash = (53 * hash) + getTopic().hashCode(); - hash = (37 * hash) + SERVICE_ACCOUNT_EMAIL_FIELD_NUMBER; - hash = (53 * hash) + getServiceAccountEmail().hashCode(); - hash = (37 * hash) + STATE_FIELD_NUMBER; - hash = (53 * hash) + state_; - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.PubsubConfig parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.PubsubConfig parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.PubsubConfig parseFrom(com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.PubsubConfig parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.PubsubConfig parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.PubsubConfig parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.PubsubConfig parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.PubsubConfig parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.PubsubConfig parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.PubsubConfig parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.PubsubConfig parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.PubsubConfig parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.PubsubConfig prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * PubsubConfig describes the configuration of a trigger that
-   * creates a build whenever a Pub/Sub message is published.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.PubsubConfig} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.PubsubConfig) - com.google.cloudbuild.v1.PubsubConfigOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_PubsubConfig_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_PubsubConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.PubsubConfig.class, - com.google.cloudbuild.v1.PubsubConfig.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.PubsubConfig.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - subscription_ = ""; - - topic_ = ""; - - serviceAccountEmail_ = ""; - - state_ = 0; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_PubsubConfig_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.PubsubConfig getDefaultInstanceForType() { - return com.google.cloudbuild.v1.PubsubConfig.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.PubsubConfig build() { - com.google.cloudbuild.v1.PubsubConfig result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.PubsubConfig buildPartial() { - com.google.cloudbuild.v1.PubsubConfig result = - new com.google.cloudbuild.v1.PubsubConfig(this); - result.subscription_ = subscription_; - result.topic_ = topic_; - result.serviceAccountEmail_ = serviceAccountEmail_; - result.state_ = state_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.PubsubConfig) { - return mergeFrom((com.google.cloudbuild.v1.PubsubConfig) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.PubsubConfig other) { - if (other == com.google.cloudbuild.v1.PubsubConfig.getDefaultInstance()) return this; - if (!other.getSubscription().isEmpty()) { - subscription_ = other.subscription_; - onChanged(); - } - if (!other.getTopic().isEmpty()) { - topic_ = other.topic_; - onChanged(); - } - if (!other.getServiceAccountEmail().isEmpty()) { - serviceAccountEmail_ = other.serviceAccountEmail_; - onChanged(); - } - if (other.state_ != 0) { - setStateValue(other.getStateValue()); - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - subscription_ = input.readStringRequireUtf8(); - - break; - } // case 10 - case 18: - { - topic_ = input.readStringRequireUtf8(); - - break; - } // case 18 - case 26: - { - serviceAccountEmail_ = input.readStringRequireUtf8(); - - break; - } // case 26 - case 32: - { - state_ = input.readEnum(); - - break; - } // case 32 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private java.lang.Object subscription_ = ""; - /** - * - * - *
-     * Output only. Name of the subscription. Format is
-     * `projects/{project}/subscriptions/{subscription}`.
-     * 
- * - * - * string subscription = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } - * - * - * @return The subscription. - */ - public java.lang.String getSubscription() { - java.lang.Object ref = subscription_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - subscription_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Output only. Name of the subscription. Format is
-     * `projects/{project}/subscriptions/{subscription}`.
-     * 
- * - * - * string subscription = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } - * - * - * @return The bytes for subscription. - */ - public com.google.protobuf.ByteString getSubscriptionBytes() { - java.lang.Object ref = subscription_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - subscription_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Output only. Name of the subscription. Format is
-     * `projects/{project}/subscriptions/{subscription}`.
-     * 
- * - * - * string subscription = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } - * - * - * @param value The subscription to set. - * @return This builder for chaining. - */ - public Builder setSubscription(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - subscription_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. Name of the subscription. Format is
-     * `projects/{project}/subscriptions/{subscription}`.
-     * 
- * - * - * string subscription = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } - * - * - * @return This builder for chaining. - */ - public Builder clearSubscription() { - - subscription_ = getDefaultInstance().getSubscription(); - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. Name of the subscription. Format is
-     * `projects/{project}/subscriptions/{subscription}`.
-     * 
- * - * - * string subscription = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } - * - * - * @param value The bytes for subscription to set. - * @return This builder for chaining. - */ - public Builder setSubscriptionBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - subscription_ = value; - onChanged(); - return this; - } - - private java.lang.Object topic_ = ""; - /** - * - * - *
-     * The name of the topic from which this subscription is receiving messages.
-     * Format is `projects/{project}/topics/{topic}`.
-     * 
- * - * string topic = 2 [(.google.api.resource_reference) = { ... } - * - * @return The topic. - */ - public java.lang.String getTopic() { - java.lang.Object ref = topic_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - topic_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * The name of the topic from which this subscription is receiving messages.
-     * Format is `projects/{project}/topics/{topic}`.
-     * 
- * - * string topic = 2 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for topic. - */ - public com.google.protobuf.ByteString getTopicBytes() { - java.lang.Object ref = topic_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - topic_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * The name of the topic from which this subscription is receiving messages.
-     * Format is `projects/{project}/topics/{topic}`.
-     * 
- * - * string topic = 2 [(.google.api.resource_reference) = { ... } - * - * @param value The topic to set. - * @return This builder for chaining. - */ - public Builder setTopic(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - topic_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the topic from which this subscription is receiving messages.
-     * Format is `projects/{project}/topics/{topic}`.
-     * 
- * - * string topic = 2 [(.google.api.resource_reference) = { ... } - * - * @return This builder for chaining. - */ - public Builder clearTopic() { - - topic_ = getDefaultInstance().getTopic(); - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the topic from which this subscription is receiving messages.
-     * Format is `projects/{project}/topics/{topic}`.
-     * 
- * - * string topic = 2 [(.google.api.resource_reference) = { ... } - * - * @param value The bytes for topic to set. - * @return This builder for chaining. - */ - public Builder setTopicBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - topic_ = value; - onChanged(); - return this; - } - - private java.lang.Object serviceAccountEmail_ = ""; - /** - * - * - *
-     * Service account that will make the push request.
-     * 
- * - * string service_account_email = 3 [(.google.api.resource_reference) = { ... } - * - * @return The serviceAccountEmail. - */ - public java.lang.String getServiceAccountEmail() { - java.lang.Object ref = serviceAccountEmail_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - serviceAccountEmail_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Service account that will make the push request.
-     * 
- * - * string service_account_email = 3 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for serviceAccountEmail. - */ - public com.google.protobuf.ByteString getServiceAccountEmailBytes() { - java.lang.Object ref = serviceAccountEmail_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - serviceAccountEmail_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Service account that will make the push request.
-     * 
- * - * string service_account_email = 3 [(.google.api.resource_reference) = { ... } - * - * @param value The serviceAccountEmail to set. - * @return This builder for chaining. - */ - public Builder setServiceAccountEmail(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - serviceAccountEmail_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Service account that will make the push request.
-     * 
- * - * string service_account_email = 3 [(.google.api.resource_reference) = { ... } - * - * @return This builder for chaining. - */ - public Builder clearServiceAccountEmail() { - - serviceAccountEmail_ = getDefaultInstance().getServiceAccountEmail(); - onChanged(); - return this; - } - /** - * - * - *
-     * Service account that will make the push request.
-     * 
- * - * string service_account_email = 3 [(.google.api.resource_reference) = { ... } - * - * @param value The bytes for serviceAccountEmail to set. - * @return This builder for chaining. - */ - public Builder setServiceAccountEmailBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - serviceAccountEmail_ = value; - onChanged(); - return this; - } - - private int state_ = 0; - /** - * - * - *
-     * Potential issues with the underlying Pub/Sub subscription configuration.
-     * Only populated on get requests.
-     * 
- * - * .google.devtools.cloudbuild.v1.PubsubConfig.State state = 4; - * - * @return The enum numeric value on the wire for state. - */ - @java.lang.Override - public int getStateValue() { - return state_; - } - /** - * - * - *
-     * Potential issues with the underlying Pub/Sub subscription configuration.
-     * Only populated on get requests.
-     * 
- * - * .google.devtools.cloudbuild.v1.PubsubConfig.State state = 4; - * - * @param value The enum numeric value on the wire for state to set. - * @return This builder for chaining. - */ - public Builder setStateValue(int value) { - - state_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Potential issues with the underlying Pub/Sub subscription configuration.
-     * Only populated on get requests.
-     * 
- * - * .google.devtools.cloudbuild.v1.PubsubConfig.State state = 4; - * - * @return The state. - */ - @java.lang.Override - public com.google.cloudbuild.v1.PubsubConfig.State getState() { - @SuppressWarnings("deprecation") - com.google.cloudbuild.v1.PubsubConfig.State result = - com.google.cloudbuild.v1.PubsubConfig.State.valueOf(state_); - return result == null ? com.google.cloudbuild.v1.PubsubConfig.State.UNRECOGNIZED : result; - } - /** - * - * - *
-     * Potential issues with the underlying Pub/Sub subscription configuration.
-     * Only populated on get requests.
-     * 
- * - * .google.devtools.cloudbuild.v1.PubsubConfig.State state = 4; - * - * @param value The state to set. - * @return This builder for chaining. - */ - public Builder setState(com.google.cloudbuild.v1.PubsubConfig.State value) { - if (value == null) { - throw new NullPointerException(); - } - - state_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-     * Potential issues with the underlying Pub/Sub subscription configuration.
-     * Only populated on get requests.
-     * 
- * - * .google.devtools.cloudbuild.v1.PubsubConfig.State state = 4; - * - * @return This builder for chaining. - */ - public Builder clearState() { - - state_ = 0; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.PubsubConfig) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.PubsubConfig) - private static final com.google.cloudbuild.v1.PubsubConfig DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.PubsubConfig(); - } - - public static com.google.cloudbuild.v1.PubsubConfig getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public PubsubConfig parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.PubsubConfig getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/PubsubConfigOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/PubsubConfigOrBuilder.java deleted file mode 100644 index b26e2062..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/PubsubConfigOrBuilder.java +++ /dev/null @@ -1,135 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface PubsubConfigOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.PubsubConfig) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * Output only. Name of the subscription. Format is
-   * `projects/{project}/subscriptions/{subscription}`.
-   * 
- * - * - * string subscription = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } - * - * - * @return The subscription. - */ - java.lang.String getSubscription(); - /** - * - * - *
-   * Output only. Name of the subscription. Format is
-   * `projects/{project}/subscriptions/{subscription}`.
-   * 
- * - * - * string subscription = 1 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... } - * - * - * @return The bytes for subscription. - */ - com.google.protobuf.ByteString getSubscriptionBytes(); - - /** - * - * - *
-   * The name of the topic from which this subscription is receiving messages.
-   * Format is `projects/{project}/topics/{topic}`.
-   * 
- * - * string topic = 2 [(.google.api.resource_reference) = { ... } - * - * @return The topic. - */ - java.lang.String getTopic(); - /** - * - * - *
-   * The name of the topic from which this subscription is receiving messages.
-   * Format is `projects/{project}/topics/{topic}`.
-   * 
- * - * string topic = 2 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for topic. - */ - com.google.protobuf.ByteString getTopicBytes(); - - /** - * - * - *
-   * Service account that will make the push request.
-   * 
- * - * string service_account_email = 3 [(.google.api.resource_reference) = { ... } - * - * @return The serviceAccountEmail. - */ - java.lang.String getServiceAccountEmail(); - /** - * - * - *
-   * Service account that will make the push request.
-   * 
- * - * string service_account_email = 3 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for serviceAccountEmail. - */ - com.google.protobuf.ByteString getServiceAccountEmailBytes(); - - /** - * - * - *
-   * Potential issues with the underlying Pub/Sub subscription configuration.
-   * Only populated on get requests.
-   * 
- * - * .google.devtools.cloudbuild.v1.PubsubConfig.State state = 4; - * - * @return The enum numeric value on the wire for state. - */ - int getStateValue(); - /** - * - * - *
-   * Potential issues with the underlying Pub/Sub subscription configuration.
-   * Only populated on get requests.
-   * 
- * - * .google.devtools.cloudbuild.v1.PubsubConfig.State state = 4; - * - * @return The state. - */ - com.google.cloudbuild.v1.PubsubConfig.State getState(); -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/PullRequestFilter.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/PullRequestFilter.java deleted file mode 100644 index 62dec8c8..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/PullRequestFilter.java +++ /dev/null @@ -1,1190 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * PullRequestFilter contains filter properties for matching GitHub Pull
- * Requests.
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.PullRequestFilter} - */ -public final class PullRequestFilter extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.PullRequestFilter) - PullRequestFilterOrBuilder { - private static final long serialVersionUID = 0L; - // Use PullRequestFilter.newBuilder() to construct. - private PullRequestFilter(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private PullRequestFilter() { - commentControl_ = 0; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new PullRequestFilter(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_PullRequestFilter_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_PullRequestFilter_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.PullRequestFilter.class, - com.google.cloudbuild.v1.PullRequestFilter.Builder.class); - } - - /** - * - * - *
-   * Controls behavior of Pull Request comments.
-   * 
- * - * Protobuf enum {@code google.devtools.cloudbuild.v1.PullRequestFilter.CommentControl} - */ - public enum CommentControl implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
-     * Do not require comments on Pull Requests before builds are triggered.
-     * 
- * - * COMMENTS_DISABLED = 0; - */ - COMMENTS_DISABLED(0), - /** - * - * - *
-     * Enforce that repository owners or collaborators must comment on Pull
-     * Requests before builds are triggered.
-     * 
- * - * COMMENTS_ENABLED = 1; - */ - COMMENTS_ENABLED(1), - /** - * - * - *
-     * Enforce that repository owners or collaborators must comment on external
-     * contributors' Pull Requests before builds are triggered.
-     * 
- * - * COMMENTS_ENABLED_FOR_EXTERNAL_CONTRIBUTORS_ONLY = 2; - */ - COMMENTS_ENABLED_FOR_EXTERNAL_CONTRIBUTORS_ONLY(2), - UNRECOGNIZED(-1), - ; - - /** - * - * - *
-     * Do not require comments on Pull Requests before builds are triggered.
-     * 
- * - * COMMENTS_DISABLED = 0; - */ - public static final int COMMENTS_DISABLED_VALUE = 0; - /** - * - * - *
-     * Enforce that repository owners or collaborators must comment on Pull
-     * Requests before builds are triggered.
-     * 
- * - * COMMENTS_ENABLED = 1; - */ - public static final int COMMENTS_ENABLED_VALUE = 1; - /** - * - * - *
-     * Enforce that repository owners or collaborators must comment on external
-     * contributors' Pull Requests before builds are triggered.
-     * 
- * - * COMMENTS_ENABLED_FOR_EXTERNAL_CONTRIBUTORS_ONLY = 2; - */ - public static final int COMMENTS_ENABLED_FOR_EXTERNAL_CONTRIBUTORS_ONLY_VALUE = 2; - - public final int getNumber() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalArgumentException( - "Can't get the number of an unknown enum value."); - } - return value; - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static CommentControl valueOf(int value) { - return forNumber(value); - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - */ - public static CommentControl forNumber(int value) { - switch (value) { - case 0: - return COMMENTS_DISABLED; - case 1: - return COMMENTS_ENABLED; - case 2: - return COMMENTS_ENABLED_FOR_EXTERNAL_CONTRIBUTORS_ONLY; - default: - return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { - return internalValueMap; - } - - private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public CommentControl findValueByNumber(int number) { - return CommentControl.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalStateException( - "Can't get the descriptor of an unrecognized enum value."); - } - return getDescriptor().getValues().get(ordinal()); - } - - public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { - return getDescriptor(); - } - - public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return com.google.cloudbuild.v1.PullRequestFilter.getDescriptor().getEnumTypes().get(0); - } - - private static final CommentControl[] VALUES = values(); - - public static CommentControl valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); - } - if (desc.getIndex() == -1) { - return UNRECOGNIZED; - } - return VALUES[desc.getIndex()]; - } - - private final int value; - - private CommentControl(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:google.devtools.cloudbuild.v1.PullRequestFilter.CommentControl) - } - - private int gitRefCase_ = 0; - private java.lang.Object gitRef_; - - public enum GitRefCase - implements - com.google.protobuf.Internal.EnumLite, - com.google.protobuf.AbstractMessage.InternalOneOfEnum { - BRANCH(2), - GITREF_NOT_SET(0); - private final int value; - - private GitRefCase(int value) { - this.value = value; - } - /** - * @param value The number of the enum to look for. - * @return The enum associated with the given number. - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static GitRefCase valueOf(int value) { - return forNumber(value); - } - - public static GitRefCase forNumber(int value) { - switch (value) { - case 2: - return BRANCH; - case 0: - return GITREF_NOT_SET; - default: - return null; - } - } - - public int getNumber() { - return this.value; - } - }; - - public GitRefCase getGitRefCase() { - return GitRefCase.forNumber(gitRefCase_); - } - - public static final int BRANCH_FIELD_NUMBER = 2; - /** - * - * - *
-   * Regex of branches to match.
-   * The syntax of the regular expressions accepted is the syntax accepted by
-   * RE2 and described at https://github.com/google/re2/wiki/Syntax
-   * 
- * - * string branch = 2; - * - * @return Whether the branch field is set. - */ - public boolean hasBranch() { - return gitRefCase_ == 2; - } - /** - * - * - *
-   * Regex of branches to match.
-   * The syntax of the regular expressions accepted is the syntax accepted by
-   * RE2 and described at https://github.com/google/re2/wiki/Syntax
-   * 
- * - * string branch = 2; - * - * @return The branch. - */ - public java.lang.String getBranch() { - java.lang.Object ref = ""; - if (gitRefCase_ == 2) { - ref = gitRef_; - } - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (gitRefCase_ == 2) { - gitRef_ = s; - } - return s; - } - } - /** - * - * - *
-   * Regex of branches to match.
-   * The syntax of the regular expressions accepted is the syntax accepted by
-   * RE2 and described at https://github.com/google/re2/wiki/Syntax
-   * 
- * - * string branch = 2; - * - * @return The bytes for branch. - */ - public com.google.protobuf.ByteString getBranchBytes() { - java.lang.Object ref = ""; - if (gitRefCase_ == 2) { - ref = gitRef_; - } - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - if (gitRefCase_ == 2) { - gitRef_ = b; - } - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int COMMENT_CONTROL_FIELD_NUMBER = 5; - private int commentControl_; - /** - * - * - *
-   * Configure builds to run whether a repository owner or collaborator need to
-   * comment `/gcbrun`.
-   * 
- * - * .google.devtools.cloudbuild.v1.PullRequestFilter.CommentControl comment_control = 5; - * - * - * @return The enum numeric value on the wire for commentControl. - */ - @java.lang.Override - public int getCommentControlValue() { - return commentControl_; - } - /** - * - * - *
-   * Configure builds to run whether a repository owner or collaborator need to
-   * comment `/gcbrun`.
-   * 
- * - * .google.devtools.cloudbuild.v1.PullRequestFilter.CommentControl comment_control = 5; - * - * - * @return The commentControl. - */ - @java.lang.Override - public com.google.cloudbuild.v1.PullRequestFilter.CommentControl getCommentControl() { - @SuppressWarnings("deprecation") - com.google.cloudbuild.v1.PullRequestFilter.CommentControl result = - com.google.cloudbuild.v1.PullRequestFilter.CommentControl.valueOf(commentControl_); - return result == null - ? com.google.cloudbuild.v1.PullRequestFilter.CommentControl.UNRECOGNIZED - : result; - } - - public static final int INVERT_REGEX_FIELD_NUMBER = 6; - private boolean invertRegex_; - /** - * - * - *
-   * If true, branches that do NOT match the git_ref will trigger a build.
-   * 
- * - * bool invert_regex = 6; - * - * @return The invertRegex. - */ - @java.lang.Override - public boolean getInvertRegex() { - return invertRegex_; - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (gitRefCase_ == 2) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, gitRef_); - } - if (commentControl_ - != com.google.cloudbuild.v1.PullRequestFilter.CommentControl.COMMENTS_DISABLED - .getNumber()) { - output.writeEnum(5, commentControl_); - } - if (invertRegex_ != false) { - output.writeBool(6, invertRegex_); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (gitRefCase_ == 2) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, gitRef_); - } - if (commentControl_ - != com.google.cloudbuild.v1.PullRequestFilter.CommentControl.COMMENTS_DISABLED - .getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(5, commentControl_); - } - if (invertRegex_ != false) { - size += com.google.protobuf.CodedOutputStream.computeBoolSize(6, invertRegex_); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.PullRequestFilter)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.PullRequestFilter other = - (com.google.cloudbuild.v1.PullRequestFilter) obj; - - if (commentControl_ != other.commentControl_) return false; - if (getInvertRegex() != other.getInvertRegex()) return false; - if (!getGitRefCase().equals(other.getGitRefCase())) return false; - switch (gitRefCase_) { - case 2: - if (!getBranch().equals(other.getBranch())) return false; - break; - case 0: - default: - } - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + COMMENT_CONTROL_FIELD_NUMBER; - hash = (53 * hash) + commentControl_; - hash = (37 * hash) + INVERT_REGEX_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getInvertRegex()); - switch (gitRefCase_) { - case 2: - hash = (37 * hash) + BRANCH_FIELD_NUMBER; - hash = (53 * hash) + getBranch().hashCode(); - break; - case 0: - default: - } - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.PullRequestFilter parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.PullRequestFilter parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.PullRequestFilter parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.PullRequestFilter parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.PullRequestFilter parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.PullRequestFilter parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.PullRequestFilter parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.PullRequestFilter parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.PullRequestFilter parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.PullRequestFilter parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.PullRequestFilter parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.PullRequestFilter parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.PullRequestFilter prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * PullRequestFilter contains filter properties for matching GitHub Pull
-   * Requests.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.PullRequestFilter} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.PullRequestFilter) - com.google.cloudbuild.v1.PullRequestFilterOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_PullRequestFilter_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_PullRequestFilter_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.PullRequestFilter.class, - com.google.cloudbuild.v1.PullRequestFilter.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.PullRequestFilter.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - commentControl_ = 0; - - invertRegex_ = false; - - gitRefCase_ = 0; - gitRef_ = null; - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_PullRequestFilter_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.PullRequestFilter getDefaultInstanceForType() { - return com.google.cloudbuild.v1.PullRequestFilter.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.PullRequestFilter build() { - com.google.cloudbuild.v1.PullRequestFilter result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.PullRequestFilter buildPartial() { - com.google.cloudbuild.v1.PullRequestFilter result = - new com.google.cloudbuild.v1.PullRequestFilter(this); - if (gitRefCase_ == 2) { - result.gitRef_ = gitRef_; - } - result.commentControl_ = commentControl_; - result.invertRegex_ = invertRegex_; - result.gitRefCase_ = gitRefCase_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.PullRequestFilter) { - return mergeFrom((com.google.cloudbuild.v1.PullRequestFilter) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.PullRequestFilter other) { - if (other == com.google.cloudbuild.v1.PullRequestFilter.getDefaultInstance()) return this; - if (other.commentControl_ != 0) { - setCommentControlValue(other.getCommentControlValue()); - } - if (other.getInvertRegex() != false) { - setInvertRegex(other.getInvertRegex()); - } - switch (other.getGitRefCase()) { - case BRANCH: - { - gitRefCase_ = 2; - gitRef_ = other.gitRef_; - onChanged(); - break; - } - case GITREF_NOT_SET: - { - break; - } - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - gitRefCase_ = 2; - gitRef_ = s; - break; - } // case 18 - case 40: - { - commentControl_ = input.readEnum(); - - break; - } // case 40 - case 48: - { - invertRegex_ = input.readBool(); - - break; - } // case 48 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private int gitRefCase_ = 0; - private java.lang.Object gitRef_; - - public GitRefCase getGitRefCase() { - return GitRefCase.forNumber(gitRefCase_); - } - - public Builder clearGitRef() { - gitRefCase_ = 0; - gitRef_ = null; - onChanged(); - return this; - } - - /** - * - * - *
-     * Regex of branches to match.
-     * The syntax of the regular expressions accepted is the syntax accepted by
-     * RE2 and described at https://github.com/google/re2/wiki/Syntax
-     * 
- * - * string branch = 2; - * - * @return Whether the branch field is set. - */ - @java.lang.Override - public boolean hasBranch() { - return gitRefCase_ == 2; - } - /** - * - * - *
-     * Regex of branches to match.
-     * The syntax of the regular expressions accepted is the syntax accepted by
-     * RE2 and described at https://github.com/google/re2/wiki/Syntax
-     * 
- * - * string branch = 2; - * - * @return The branch. - */ - @java.lang.Override - public java.lang.String getBranch() { - java.lang.Object ref = ""; - if (gitRefCase_ == 2) { - ref = gitRef_; - } - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (gitRefCase_ == 2) { - gitRef_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Regex of branches to match.
-     * The syntax of the regular expressions accepted is the syntax accepted by
-     * RE2 and described at https://github.com/google/re2/wiki/Syntax
-     * 
- * - * string branch = 2; - * - * @return The bytes for branch. - */ - @java.lang.Override - public com.google.protobuf.ByteString getBranchBytes() { - java.lang.Object ref = ""; - if (gitRefCase_ == 2) { - ref = gitRef_; - } - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - if (gitRefCase_ == 2) { - gitRef_ = b; - } - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Regex of branches to match.
-     * The syntax of the regular expressions accepted is the syntax accepted by
-     * RE2 and described at https://github.com/google/re2/wiki/Syntax
-     * 
- * - * string branch = 2; - * - * @param value The branch to set. - * @return This builder for chaining. - */ - public Builder setBranch(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - gitRefCase_ = 2; - gitRef_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Regex of branches to match.
-     * The syntax of the regular expressions accepted is the syntax accepted by
-     * RE2 and described at https://github.com/google/re2/wiki/Syntax
-     * 
- * - * string branch = 2; - * - * @return This builder for chaining. - */ - public Builder clearBranch() { - if (gitRefCase_ == 2) { - gitRefCase_ = 0; - gitRef_ = null; - onChanged(); - } - return this; - } - /** - * - * - *
-     * Regex of branches to match.
-     * The syntax of the regular expressions accepted is the syntax accepted by
-     * RE2 and described at https://github.com/google/re2/wiki/Syntax
-     * 
- * - * string branch = 2; - * - * @param value The bytes for branch to set. - * @return This builder for chaining. - */ - public Builder setBranchBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - gitRefCase_ = 2; - gitRef_ = value; - onChanged(); - return this; - } - - private int commentControl_ = 0; - /** - * - * - *
-     * Configure builds to run whether a repository owner or collaborator need to
-     * comment `/gcbrun`.
-     * 
- * - * .google.devtools.cloudbuild.v1.PullRequestFilter.CommentControl comment_control = 5; - * - * - * @return The enum numeric value on the wire for commentControl. - */ - @java.lang.Override - public int getCommentControlValue() { - return commentControl_; - } - /** - * - * - *
-     * Configure builds to run whether a repository owner or collaborator need to
-     * comment `/gcbrun`.
-     * 
- * - * .google.devtools.cloudbuild.v1.PullRequestFilter.CommentControl comment_control = 5; - * - * - * @param value The enum numeric value on the wire for commentControl to set. - * @return This builder for chaining. - */ - public Builder setCommentControlValue(int value) { - - commentControl_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Configure builds to run whether a repository owner or collaborator need to
-     * comment `/gcbrun`.
-     * 
- * - * .google.devtools.cloudbuild.v1.PullRequestFilter.CommentControl comment_control = 5; - * - * - * @return The commentControl. - */ - @java.lang.Override - public com.google.cloudbuild.v1.PullRequestFilter.CommentControl getCommentControl() { - @SuppressWarnings("deprecation") - com.google.cloudbuild.v1.PullRequestFilter.CommentControl result = - com.google.cloudbuild.v1.PullRequestFilter.CommentControl.valueOf(commentControl_); - return result == null - ? com.google.cloudbuild.v1.PullRequestFilter.CommentControl.UNRECOGNIZED - : result; - } - /** - * - * - *
-     * Configure builds to run whether a repository owner or collaborator need to
-     * comment `/gcbrun`.
-     * 
- * - * .google.devtools.cloudbuild.v1.PullRequestFilter.CommentControl comment_control = 5; - * - * - * @param value The commentControl to set. - * @return This builder for chaining. - */ - public Builder setCommentControl( - com.google.cloudbuild.v1.PullRequestFilter.CommentControl value) { - if (value == null) { - throw new NullPointerException(); - } - - commentControl_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-     * Configure builds to run whether a repository owner or collaborator need to
-     * comment `/gcbrun`.
-     * 
- * - * .google.devtools.cloudbuild.v1.PullRequestFilter.CommentControl comment_control = 5; - * - * - * @return This builder for chaining. - */ - public Builder clearCommentControl() { - - commentControl_ = 0; - onChanged(); - return this; - } - - private boolean invertRegex_; - /** - * - * - *
-     * If true, branches that do NOT match the git_ref will trigger a build.
-     * 
- * - * bool invert_regex = 6; - * - * @return The invertRegex. - */ - @java.lang.Override - public boolean getInvertRegex() { - return invertRegex_; - } - /** - * - * - *
-     * If true, branches that do NOT match the git_ref will trigger a build.
-     * 
- * - * bool invert_regex = 6; - * - * @param value The invertRegex to set. - * @return This builder for chaining. - */ - public Builder setInvertRegex(boolean value) { - - invertRegex_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * If true, branches that do NOT match the git_ref will trigger a build.
-     * 
- * - * bool invert_regex = 6; - * - * @return This builder for chaining. - */ - public Builder clearInvertRegex() { - - invertRegex_ = false; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.PullRequestFilter) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.PullRequestFilter) - private static final com.google.cloudbuild.v1.PullRequestFilter DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.PullRequestFilter(); - } - - public static com.google.cloudbuild.v1.PullRequestFilter getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public PullRequestFilter parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.PullRequestFilter getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/PullRequestFilterOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/PullRequestFilterOrBuilder.java deleted file mode 100644 index 163a27fa..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/PullRequestFilterOrBuilder.java +++ /dev/null @@ -1,112 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface PullRequestFilterOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.PullRequestFilter) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * Regex of branches to match.
-   * The syntax of the regular expressions accepted is the syntax accepted by
-   * RE2 and described at https://github.com/google/re2/wiki/Syntax
-   * 
- * - * string branch = 2; - * - * @return Whether the branch field is set. - */ - boolean hasBranch(); - /** - * - * - *
-   * Regex of branches to match.
-   * The syntax of the regular expressions accepted is the syntax accepted by
-   * RE2 and described at https://github.com/google/re2/wiki/Syntax
-   * 
- * - * string branch = 2; - * - * @return The branch. - */ - java.lang.String getBranch(); - /** - * - * - *
-   * Regex of branches to match.
-   * The syntax of the regular expressions accepted is the syntax accepted by
-   * RE2 and described at https://github.com/google/re2/wiki/Syntax
-   * 
- * - * string branch = 2; - * - * @return The bytes for branch. - */ - com.google.protobuf.ByteString getBranchBytes(); - - /** - * - * - *
-   * Configure builds to run whether a repository owner or collaborator need to
-   * comment `/gcbrun`.
-   * 
- * - * .google.devtools.cloudbuild.v1.PullRequestFilter.CommentControl comment_control = 5; - * - * - * @return The enum numeric value on the wire for commentControl. - */ - int getCommentControlValue(); - /** - * - * - *
-   * Configure builds to run whether a repository owner or collaborator need to
-   * comment `/gcbrun`.
-   * 
- * - * .google.devtools.cloudbuild.v1.PullRequestFilter.CommentControl comment_control = 5; - * - * - * @return The commentControl. - */ - com.google.cloudbuild.v1.PullRequestFilter.CommentControl getCommentControl(); - - /** - * - * - *
-   * If true, branches that do NOT match the git_ref will trigger a build.
-   * 
- * - * bool invert_regex = 6; - * - * @return The invertRegex. - */ - boolean getInvertRegex(); - - public com.google.cloudbuild.v1.PullRequestFilter.GitRefCase getGitRefCase(); -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/PushFilter.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/PushFilter.java deleted file mode 100644 index 7f7d5c41..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/PushFilter.java +++ /dev/null @@ -1,1110 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * Push contains filter properties for matching GitHub git pushes.
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.PushFilter} - */ -public final class PushFilter extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.PushFilter) - PushFilterOrBuilder { - private static final long serialVersionUID = 0L; - // Use PushFilter.newBuilder() to construct. - private PushFilter(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private PushFilter() {} - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new PushFilter(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_PushFilter_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_PushFilter_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.PushFilter.class, - com.google.cloudbuild.v1.PushFilter.Builder.class); - } - - private int gitRefCase_ = 0; - private java.lang.Object gitRef_; - - public enum GitRefCase - implements - com.google.protobuf.Internal.EnumLite, - com.google.protobuf.AbstractMessage.InternalOneOfEnum { - BRANCH(2), - TAG(3), - GITREF_NOT_SET(0); - private final int value; - - private GitRefCase(int value) { - this.value = value; - } - /** - * @param value The number of the enum to look for. - * @return The enum associated with the given number. - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static GitRefCase valueOf(int value) { - return forNumber(value); - } - - public static GitRefCase forNumber(int value) { - switch (value) { - case 2: - return BRANCH; - case 3: - return TAG; - case 0: - return GITREF_NOT_SET; - default: - return null; - } - } - - public int getNumber() { - return this.value; - } - }; - - public GitRefCase getGitRefCase() { - return GitRefCase.forNumber(gitRefCase_); - } - - public static final int BRANCH_FIELD_NUMBER = 2; - /** - * - * - *
-   * Regexes matching branches to build.
-   * The syntax of the regular expressions accepted is the syntax accepted by
-   * RE2 and described at https://github.com/google/re2/wiki/Syntax
-   * 
- * - * string branch = 2; - * - * @return Whether the branch field is set. - */ - public boolean hasBranch() { - return gitRefCase_ == 2; - } - /** - * - * - *
-   * Regexes matching branches to build.
-   * The syntax of the regular expressions accepted is the syntax accepted by
-   * RE2 and described at https://github.com/google/re2/wiki/Syntax
-   * 
- * - * string branch = 2; - * - * @return The branch. - */ - public java.lang.String getBranch() { - java.lang.Object ref = ""; - if (gitRefCase_ == 2) { - ref = gitRef_; - } - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (gitRefCase_ == 2) { - gitRef_ = s; - } - return s; - } - } - /** - * - * - *
-   * Regexes matching branches to build.
-   * The syntax of the regular expressions accepted is the syntax accepted by
-   * RE2 and described at https://github.com/google/re2/wiki/Syntax
-   * 
- * - * string branch = 2; - * - * @return The bytes for branch. - */ - public com.google.protobuf.ByteString getBranchBytes() { - java.lang.Object ref = ""; - if (gitRefCase_ == 2) { - ref = gitRef_; - } - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - if (gitRefCase_ == 2) { - gitRef_ = b; - } - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int TAG_FIELD_NUMBER = 3; - /** - * - * - *
-   * Regexes matching tags to build.
-   * The syntax of the regular expressions accepted is the syntax accepted by
-   * RE2 and described at https://github.com/google/re2/wiki/Syntax
-   * 
- * - * string tag = 3; - * - * @return Whether the tag field is set. - */ - public boolean hasTag() { - return gitRefCase_ == 3; - } - /** - * - * - *
-   * Regexes matching tags to build.
-   * The syntax of the regular expressions accepted is the syntax accepted by
-   * RE2 and described at https://github.com/google/re2/wiki/Syntax
-   * 
- * - * string tag = 3; - * - * @return The tag. - */ - public java.lang.String getTag() { - java.lang.Object ref = ""; - if (gitRefCase_ == 3) { - ref = gitRef_; - } - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (gitRefCase_ == 3) { - gitRef_ = s; - } - return s; - } - } - /** - * - * - *
-   * Regexes matching tags to build.
-   * The syntax of the regular expressions accepted is the syntax accepted by
-   * RE2 and described at https://github.com/google/re2/wiki/Syntax
-   * 
- * - * string tag = 3; - * - * @return The bytes for tag. - */ - public com.google.protobuf.ByteString getTagBytes() { - java.lang.Object ref = ""; - if (gitRefCase_ == 3) { - ref = gitRef_; - } - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - if (gitRefCase_ == 3) { - gitRef_ = b; - } - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int INVERT_REGEX_FIELD_NUMBER = 4; - private boolean invertRegex_; - /** - * - * - *
-   * When true, only trigger a build if the revision regex does NOT match the
-   * git_ref regex.
-   * 
- * - * bool invert_regex = 4; - * - * @return The invertRegex. - */ - @java.lang.Override - public boolean getInvertRegex() { - return invertRegex_; - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (gitRefCase_ == 2) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, gitRef_); - } - if (gitRefCase_ == 3) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 3, gitRef_); - } - if (invertRegex_ != false) { - output.writeBool(4, invertRegex_); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (gitRefCase_ == 2) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, gitRef_); - } - if (gitRefCase_ == 3) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, gitRef_); - } - if (invertRegex_ != false) { - size += com.google.protobuf.CodedOutputStream.computeBoolSize(4, invertRegex_); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.PushFilter)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.PushFilter other = (com.google.cloudbuild.v1.PushFilter) obj; - - if (getInvertRegex() != other.getInvertRegex()) return false; - if (!getGitRefCase().equals(other.getGitRefCase())) return false; - switch (gitRefCase_) { - case 2: - if (!getBranch().equals(other.getBranch())) return false; - break; - case 3: - if (!getTag().equals(other.getTag())) return false; - break; - case 0: - default: - } - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + INVERT_REGEX_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getInvertRegex()); - switch (gitRefCase_) { - case 2: - hash = (37 * hash) + BRANCH_FIELD_NUMBER; - hash = (53 * hash) + getBranch().hashCode(); - break; - case 3: - hash = (37 * hash) + TAG_FIELD_NUMBER; - hash = (53 * hash) + getTag().hashCode(); - break; - case 0: - default: - } - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.PushFilter parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.PushFilter parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.PushFilter parseFrom(com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.PushFilter parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.PushFilter parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.PushFilter parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.PushFilter parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.PushFilter parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.PushFilter parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.PushFilter parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.PushFilter parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.PushFilter parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.PushFilter prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * Push contains filter properties for matching GitHub git pushes.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.PushFilter} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.PushFilter) - com.google.cloudbuild.v1.PushFilterOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_PushFilter_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_PushFilter_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.PushFilter.class, - com.google.cloudbuild.v1.PushFilter.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.PushFilter.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - invertRegex_ = false; - - gitRefCase_ = 0; - gitRef_ = null; - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_PushFilter_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.PushFilter getDefaultInstanceForType() { - return com.google.cloudbuild.v1.PushFilter.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.PushFilter build() { - com.google.cloudbuild.v1.PushFilter result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.PushFilter buildPartial() { - com.google.cloudbuild.v1.PushFilter result = new com.google.cloudbuild.v1.PushFilter(this); - if (gitRefCase_ == 2) { - result.gitRef_ = gitRef_; - } - if (gitRefCase_ == 3) { - result.gitRef_ = gitRef_; - } - result.invertRegex_ = invertRegex_; - result.gitRefCase_ = gitRefCase_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.PushFilter) { - return mergeFrom((com.google.cloudbuild.v1.PushFilter) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.PushFilter other) { - if (other == com.google.cloudbuild.v1.PushFilter.getDefaultInstance()) return this; - if (other.getInvertRegex() != false) { - setInvertRegex(other.getInvertRegex()); - } - switch (other.getGitRefCase()) { - case BRANCH: - { - gitRefCase_ = 2; - gitRef_ = other.gitRef_; - onChanged(); - break; - } - case TAG: - { - gitRefCase_ = 3; - gitRef_ = other.gitRef_; - onChanged(); - break; - } - case GITREF_NOT_SET: - { - break; - } - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 18: - { - java.lang.String s = input.readStringRequireUtf8(); - gitRefCase_ = 2; - gitRef_ = s; - break; - } // case 18 - case 26: - { - java.lang.String s = input.readStringRequireUtf8(); - gitRefCase_ = 3; - gitRef_ = s; - break; - } // case 26 - case 32: - { - invertRegex_ = input.readBool(); - - break; - } // case 32 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private int gitRefCase_ = 0; - private java.lang.Object gitRef_; - - public GitRefCase getGitRefCase() { - return GitRefCase.forNumber(gitRefCase_); - } - - public Builder clearGitRef() { - gitRefCase_ = 0; - gitRef_ = null; - onChanged(); - return this; - } - - /** - * - * - *
-     * Regexes matching branches to build.
-     * The syntax of the regular expressions accepted is the syntax accepted by
-     * RE2 and described at https://github.com/google/re2/wiki/Syntax
-     * 
- * - * string branch = 2; - * - * @return Whether the branch field is set. - */ - @java.lang.Override - public boolean hasBranch() { - return gitRefCase_ == 2; - } - /** - * - * - *
-     * Regexes matching branches to build.
-     * The syntax of the regular expressions accepted is the syntax accepted by
-     * RE2 and described at https://github.com/google/re2/wiki/Syntax
-     * 
- * - * string branch = 2; - * - * @return The branch. - */ - @java.lang.Override - public java.lang.String getBranch() { - java.lang.Object ref = ""; - if (gitRefCase_ == 2) { - ref = gitRef_; - } - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (gitRefCase_ == 2) { - gitRef_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Regexes matching branches to build.
-     * The syntax of the regular expressions accepted is the syntax accepted by
-     * RE2 and described at https://github.com/google/re2/wiki/Syntax
-     * 
- * - * string branch = 2; - * - * @return The bytes for branch. - */ - @java.lang.Override - public com.google.protobuf.ByteString getBranchBytes() { - java.lang.Object ref = ""; - if (gitRefCase_ == 2) { - ref = gitRef_; - } - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - if (gitRefCase_ == 2) { - gitRef_ = b; - } - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Regexes matching branches to build.
-     * The syntax of the regular expressions accepted is the syntax accepted by
-     * RE2 and described at https://github.com/google/re2/wiki/Syntax
-     * 
- * - * string branch = 2; - * - * @param value The branch to set. - * @return This builder for chaining. - */ - public Builder setBranch(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - gitRefCase_ = 2; - gitRef_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Regexes matching branches to build.
-     * The syntax of the regular expressions accepted is the syntax accepted by
-     * RE2 and described at https://github.com/google/re2/wiki/Syntax
-     * 
- * - * string branch = 2; - * - * @return This builder for chaining. - */ - public Builder clearBranch() { - if (gitRefCase_ == 2) { - gitRefCase_ = 0; - gitRef_ = null; - onChanged(); - } - return this; - } - /** - * - * - *
-     * Regexes matching branches to build.
-     * The syntax of the regular expressions accepted is the syntax accepted by
-     * RE2 and described at https://github.com/google/re2/wiki/Syntax
-     * 
- * - * string branch = 2; - * - * @param value The bytes for branch to set. - * @return This builder for chaining. - */ - public Builder setBranchBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - gitRefCase_ = 2; - gitRef_ = value; - onChanged(); - return this; - } - - /** - * - * - *
-     * Regexes matching tags to build.
-     * The syntax of the regular expressions accepted is the syntax accepted by
-     * RE2 and described at https://github.com/google/re2/wiki/Syntax
-     * 
- * - * string tag = 3; - * - * @return Whether the tag field is set. - */ - @java.lang.Override - public boolean hasTag() { - return gitRefCase_ == 3; - } - /** - * - * - *
-     * Regexes matching tags to build.
-     * The syntax of the regular expressions accepted is the syntax accepted by
-     * RE2 and described at https://github.com/google/re2/wiki/Syntax
-     * 
- * - * string tag = 3; - * - * @return The tag. - */ - @java.lang.Override - public java.lang.String getTag() { - java.lang.Object ref = ""; - if (gitRefCase_ == 3) { - ref = gitRef_; - } - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (gitRefCase_ == 3) { - gitRef_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Regexes matching tags to build.
-     * The syntax of the regular expressions accepted is the syntax accepted by
-     * RE2 and described at https://github.com/google/re2/wiki/Syntax
-     * 
- * - * string tag = 3; - * - * @return The bytes for tag. - */ - @java.lang.Override - public com.google.protobuf.ByteString getTagBytes() { - java.lang.Object ref = ""; - if (gitRefCase_ == 3) { - ref = gitRef_; - } - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - if (gitRefCase_ == 3) { - gitRef_ = b; - } - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Regexes matching tags to build.
-     * The syntax of the regular expressions accepted is the syntax accepted by
-     * RE2 and described at https://github.com/google/re2/wiki/Syntax
-     * 
- * - * string tag = 3; - * - * @param value The tag to set. - * @return This builder for chaining. - */ - public Builder setTag(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - gitRefCase_ = 3; - gitRef_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Regexes matching tags to build.
-     * The syntax of the regular expressions accepted is the syntax accepted by
-     * RE2 and described at https://github.com/google/re2/wiki/Syntax
-     * 
- * - * string tag = 3; - * - * @return This builder for chaining. - */ - public Builder clearTag() { - if (gitRefCase_ == 3) { - gitRefCase_ = 0; - gitRef_ = null; - onChanged(); - } - return this; - } - /** - * - * - *
-     * Regexes matching tags to build.
-     * The syntax of the regular expressions accepted is the syntax accepted by
-     * RE2 and described at https://github.com/google/re2/wiki/Syntax
-     * 
- * - * string tag = 3; - * - * @param value The bytes for tag to set. - * @return This builder for chaining. - */ - public Builder setTagBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - gitRefCase_ = 3; - gitRef_ = value; - onChanged(); - return this; - } - - private boolean invertRegex_; - /** - * - * - *
-     * When true, only trigger a build if the revision regex does NOT match the
-     * git_ref regex.
-     * 
- * - * bool invert_regex = 4; - * - * @return The invertRegex. - */ - @java.lang.Override - public boolean getInvertRegex() { - return invertRegex_; - } - /** - * - * - *
-     * When true, only trigger a build if the revision regex does NOT match the
-     * git_ref regex.
-     * 
- * - * bool invert_regex = 4; - * - * @param value The invertRegex to set. - * @return This builder for chaining. - */ - public Builder setInvertRegex(boolean value) { - - invertRegex_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * When true, only trigger a build if the revision regex does NOT match the
-     * git_ref regex.
-     * 
- * - * bool invert_regex = 4; - * - * @return This builder for chaining. - */ - public Builder clearInvertRegex() { - - invertRegex_ = false; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.PushFilter) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.PushFilter) - private static final com.google.cloudbuild.v1.PushFilter DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.PushFilter(); - } - - public static com.google.cloudbuild.v1.PushFilter getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public PushFilter parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.PushFilter getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/PushFilterOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/PushFilterOrBuilder.java deleted file mode 100644 index ab482ece..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/PushFilterOrBuilder.java +++ /dev/null @@ -1,127 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface PushFilterOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.PushFilter) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * Regexes matching branches to build.
-   * The syntax of the regular expressions accepted is the syntax accepted by
-   * RE2 and described at https://github.com/google/re2/wiki/Syntax
-   * 
- * - * string branch = 2; - * - * @return Whether the branch field is set. - */ - boolean hasBranch(); - /** - * - * - *
-   * Regexes matching branches to build.
-   * The syntax of the regular expressions accepted is the syntax accepted by
-   * RE2 and described at https://github.com/google/re2/wiki/Syntax
-   * 
- * - * string branch = 2; - * - * @return The branch. - */ - java.lang.String getBranch(); - /** - * - * - *
-   * Regexes matching branches to build.
-   * The syntax of the regular expressions accepted is the syntax accepted by
-   * RE2 and described at https://github.com/google/re2/wiki/Syntax
-   * 
- * - * string branch = 2; - * - * @return The bytes for branch. - */ - com.google.protobuf.ByteString getBranchBytes(); - - /** - * - * - *
-   * Regexes matching tags to build.
-   * The syntax of the regular expressions accepted is the syntax accepted by
-   * RE2 and described at https://github.com/google/re2/wiki/Syntax
-   * 
- * - * string tag = 3; - * - * @return Whether the tag field is set. - */ - boolean hasTag(); - /** - * - * - *
-   * Regexes matching tags to build.
-   * The syntax of the regular expressions accepted is the syntax accepted by
-   * RE2 and described at https://github.com/google/re2/wiki/Syntax
-   * 
- * - * string tag = 3; - * - * @return The tag. - */ - java.lang.String getTag(); - /** - * - * - *
-   * Regexes matching tags to build.
-   * The syntax of the regular expressions accepted is the syntax accepted by
-   * RE2 and described at https://github.com/google/re2/wiki/Syntax
-   * 
- * - * string tag = 3; - * - * @return The bytes for tag. - */ - com.google.protobuf.ByteString getTagBytes(); - - /** - * - * - *
-   * When true, only trigger a build if the revision regex does NOT match the
-   * git_ref regex.
-   * 
- * - * bool invert_regex = 4; - * - * @return The invertRegex. - */ - boolean getInvertRegex(); - - public com.google.cloudbuild.v1.PushFilter.GitRefCase getGitRefCase(); -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ReceiveTriggerWebhookRequest.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ReceiveTriggerWebhookRequest.java deleted file mode 100644 index 8623b6b1..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ReceiveTriggerWebhookRequest.java +++ /dev/null @@ -1,1416 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * ReceiveTriggerWebhookRequest [Experimental] is the request object accepted by
- * the ReceiveTriggerWebhook method.
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.ReceiveTriggerWebhookRequest} - */ -public final class ReceiveTriggerWebhookRequest extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.ReceiveTriggerWebhookRequest) - ReceiveTriggerWebhookRequestOrBuilder { - private static final long serialVersionUID = 0L; - // Use ReceiveTriggerWebhookRequest.newBuilder() to construct. - private ReceiveTriggerWebhookRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private ReceiveTriggerWebhookRequest() { - name_ = ""; - projectId_ = ""; - trigger_ = ""; - secret_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new ReceiveTriggerWebhookRequest(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ReceiveTriggerWebhookRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ReceiveTriggerWebhookRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest.class, - com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest.Builder.class); - } - - public static final int NAME_FIELD_NUMBER = 5; - private volatile java.lang.Object name_; - /** - * - * - *
-   * The name of the `ReceiveTriggerWebhook` to retrieve.
-   * Format: `projects/{project}/locations/{location}/triggers/{trigger}`
-   * 
- * - * string name = 5; - * - * @return The name. - */ - @java.lang.Override - public java.lang.String getName() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - name_ = s; - return s; - } - } - /** - * - * - *
-   * The name of the `ReceiveTriggerWebhook` to retrieve.
-   * Format: `projects/{project}/locations/{location}/triggers/{trigger}`
-   * 
- * - * string name = 5; - * - * @return The bytes for name. - */ - @java.lang.Override - public com.google.protobuf.ByteString getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int BODY_FIELD_NUMBER = 1; - private com.google.api.HttpBody body_; - /** - * - * - *
-   * HTTP request body.
-   * 
- * - * .google.api.HttpBody body = 1; - * - * @return Whether the body field is set. - */ - @java.lang.Override - public boolean hasBody() { - return body_ != null; - } - /** - * - * - *
-   * HTTP request body.
-   * 
- * - * .google.api.HttpBody body = 1; - * - * @return The body. - */ - @java.lang.Override - public com.google.api.HttpBody getBody() { - return body_ == null ? com.google.api.HttpBody.getDefaultInstance() : body_; - } - /** - * - * - *
-   * HTTP request body.
-   * 
- * - * .google.api.HttpBody body = 1; - */ - @java.lang.Override - public com.google.api.HttpBodyOrBuilder getBodyOrBuilder() { - return getBody(); - } - - public static final int PROJECT_ID_FIELD_NUMBER = 2; - private volatile java.lang.Object projectId_; - /** - * - * - *
-   * Project in which the specified trigger lives
-   * 
- * - * string project_id = 2; - * - * @return The projectId. - */ - @java.lang.Override - public java.lang.String getProjectId() { - java.lang.Object ref = projectId_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - projectId_ = s; - return s; - } - } - /** - * - * - *
-   * Project in which the specified trigger lives
-   * 
- * - * string project_id = 2; - * - * @return The bytes for projectId. - */ - @java.lang.Override - public com.google.protobuf.ByteString getProjectIdBytes() { - java.lang.Object ref = projectId_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - projectId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int TRIGGER_FIELD_NUMBER = 3; - private volatile java.lang.Object trigger_; - /** - * - * - *
-   * Name of the trigger to run the payload against
-   * 
- * - * string trigger = 3; - * - * @return The trigger. - */ - @java.lang.Override - public java.lang.String getTrigger() { - java.lang.Object ref = trigger_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - trigger_ = s; - return s; - } - } - /** - * - * - *
-   * Name of the trigger to run the payload against
-   * 
- * - * string trigger = 3; - * - * @return The bytes for trigger. - */ - @java.lang.Override - public com.google.protobuf.ByteString getTriggerBytes() { - java.lang.Object ref = trigger_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - trigger_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int SECRET_FIELD_NUMBER = 4; - private volatile java.lang.Object secret_; - /** - * - * - *
-   * Secret token used for authorization if an OAuth token isn't provided.
-   * 
- * - * string secret = 4; - * - * @return The secret. - */ - @java.lang.Override - public java.lang.String getSecret() { - java.lang.Object ref = secret_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - secret_ = s; - return s; - } - } - /** - * - * - *
-   * Secret token used for authorization if an OAuth token isn't provided.
-   * 
- * - * string secret = 4; - * - * @return The bytes for secret. - */ - @java.lang.Override - public com.google.protobuf.ByteString getSecretBytes() { - java.lang.Object ref = secret_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - secret_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (body_ != null) { - output.writeMessage(1, getBody()); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(projectId_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, projectId_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(trigger_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 3, trigger_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(secret_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 4, secret_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 5, name_); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (body_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getBody()); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(projectId_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, projectId_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(trigger_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, trigger_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(secret_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, secret_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(5, name_); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest other = - (com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest) obj; - - if (!getName().equals(other.getName())) return false; - if (hasBody() != other.hasBody()) return false; - if (hasBody()) { - if (!getBody().equals(other.getBody())) return false; - } - if (!getProjectId().equals(other.getProjectId())) return false; - if (!getTrigger().equals(other.getTrigger())) return false; - if (!getSecret().equals(other.getSecret())) return false; - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + NAME_FIELD_NUMBER; - hash = (53 * hash) + getName().hashCode(); - if (hasBody()) { - hash = (37 * hash) + BODY_FIELD_NUMBER; - hash = (53 * hash) + getBody().hashCode(); - } - hash = (37 * hash) + PROJECT_ID_FIELD_NUMBER; - hash = (53 * hash) + getProjectId().hashCode(); - hash = (37 * hash) + TRIGGER_FIELD_NUMBER; - hash = (53 * hash) + getTrigger().hashCode(); - hash = (37 * hash) + SECRET_FIELD_NUMBER; - hash = (53 * hash) + getSecret().hashCode(); - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder( - com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * ReceiveTriggerWebhookRequest [Experimental] is the request object accepted by
-   * the ReceiveTriggerWebhook method.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.ReceiveTriggerWebhookRequest} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.ReceiveTriggerWebhookRequest) - com.google.cloudbuild.v1.ReceiveTriggerWebhookRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ReceiveTriggerWebhookRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ReceiveTriggerWebhookRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest.class, - com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - name_ = ""; - - if (bodyBuilder_ == null) { - body_ = null; - } else { - body_ = null; - bodyBuilder_ = null; - } - projectId_ = ""; - - trigger_ = ""; - - secret_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ReceiveTriggerWebhookRequest_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest getDefaultInstanceForType() { - return com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest build() { - com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest buildPartial() { - com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest result = - new com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest(this); - result.name_ = name_; - if (bodyBuilder_ == null) { - result.body_ = body_; - } else { - result.body_ = bodyBuilder_.build(); - } - result.projectId_ = projectId_; - result.trigger_ = trigger_; - result.secret_ = secret_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest) { - return mergeFrom((com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest other) { - if (other == com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest.getDefaultInstance()) - return this; - if (!other.getName().isEmpty()) { - name_ = other.name_; - onChanged(); - } - if (other.hasBody()) { - mergeBody(other.getBody()); - } - if (!other.getProjectId().isEmpty()) { - projectId_ = other.projectId_; - onChanged(); - } - if (!other.getTrigger().isEmpty()) { - trigger_ = other.trigger_; - onChanged(); - } - if (!other.getSecret().isEmpty()) { - secret_ = other.secret_; - onChanged(); - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - input.readMessage(getBodyFieldBuilder().getBuilder(), extensionRegistry); - - break; - } // case 10 - case 18: - { - projectId_ = input.readStringRequireUtf8(); - - break; - } // case 18 - case 26: - { - trigger_ = input.readStringRequireUtf8(); - - break; - } // case 26 - case 34: - { - secret_ = input.readStringRequireUtf8(); - - break; - } // case 34 - case 42: - { - name_ = input.readStringRequireUtf8(); - - break; - } // case 42 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private java.lang.Object name_ = ""; - /** - * - * - *
-     * The name of the `ReceiveTriggerWebhook` to retrieve.
-     * Format: `projects/{project}/locations/{location}/triggers/{trigger}`
-     * 
- * - * string name = 5; - * - * @return The name. - */ - public java.lang.String getName() { - java.lang.Object ref = name_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - name_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * The name of the `ReceiveTriggerWebhook` to retrieve.
-     * Format: `projects/{project}/locations/{location}/triggers/{trigger}`
-     * 
- * - * string name = 5; - * - * @return The bytes for name. - */ - public com.google.protobuf.ByteString getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * The name of the `ReceiveTriggerWebhook` to retrieve.
-     * Format: `projects/{project}/locations/{location}/triggers/{trigger}`
-     * 
- * - * string name = 5; - * - * @param value The name to set. - * @return This builder for chaining. - */ - public Builder setName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - name_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the `ReceiveTriggerWebhook` to retrieve.
-     * Format: `projects/{project}/locations/{location}/triggers/{trigger}`
-     * 
- * - * string name = 5; - * - * @return This builder for chaining. - */ - public Builder clearName() { - - name_ = getDefaultInstance().getName(); - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the `ReceiveTriggerWebhook` to retrieve.
-     * Format: `projects/{project}/locations/{location}/triggers/{trigger}`
-     * 
- * - * string name = 5; - * - * @param value The bytes for name to set. - * @return This builder for chaining. - */ - public Builder setNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - name_ = value; - onChanged(); - return this; - } - - private com.google.api.HttpBody body_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.api.HttpBody, - com.google.api.HttpBody.Builder, - com.google.api.HttpBodyOrBuilder> - bodyBuilder_; - /** - * - * - *
-     * HTTP request body.
-     * 
- * - * .google.api.HttpBody body = 1; - * - * @return Whether the body field is set. - */ - public boolean hasBody() { - return bodyBuilder_ != null || body_ != null; - } - /** - * - * - *
-     * HTTP request body.
-     * 
- * - * .google.api.HttpBody body = 1; - * - * @return The body. - */ - public com.google.api.HttpBody getBody() { - if (bodyBuilder_ == null) { - return body_ == null ? com.google.api.HttpBody.getDefaultInstance() : body_; - } else { - return bodyBuilder_.getMessage(); - } - } - /** - * - * - *
-     * HTTP request body.
-     * 
- * - * .google.api.HttpBody body = 1; - */ - public Builder setBody(com.google.api.HttpBody value) { - if (bodyBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - body_ = value; - onChanged(); - } else { - bodyBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * HTTP request body.
-     * 
- * - * .google.api.HttpBody body = 1; - */ - public Builder setBody(com.google.api.HttpBody.Builder builderForValue) { - if (bodyBuilder_ == null) { - body_ = builderForValue.build(); - onChanged(); - } else { - bodyBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * HTTP request body.
-     * 
- * - * .google.api.HttpBody body = 1; - */ - public Builder mergeBody(com.google.api.HttpBody value) { - if (bodyBuilder_ == null) { - if (body_ != null) { - body_ = com.google.api.HttpBody.newBuilder(body_).mergeFrom(value).buildPartial(); - } else { - body_ = value; - } - onChanged(); - } else { - bodyBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * HTTP request body.
-     * 
- * - * .google.api.HttpBody body = 1; - */ - public Builder clearBody() { - if (bodyBuilder_ == null) { - body_ = null; - onChanged(); - } else { - body_ = null; - bodyBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * HTTP request body.
-     * 
- * - * .google.api.HttpBody body = 1; - */ - public com.google.api.HttpBody.Builder getBodyBuilder() { - - onChanged(); - return getBodyFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * HTTP request body.
-     * 
- * - * .google.api.HttpBody body = 1; - */ - public com.google.api.HttpBodyOrBuilder getBodyOrBuilder() { - if (bodyBuilder_ != null) { - return bodyBuilder_.getMessageOrBuilder(); - } else { - return body_ == null ? com.google.api.HttpBody.getDefaultInstance() : body_; - } - } - /** - * - * - *
-     * HTTP request body.
-     * 
- * - * .google.api.HttpBody body = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.api.HttpBody, - com.google.api.HttpBody.Builder, - com.google.api.HttpBodyOrBuilder> - getBodyFieldBuilder() { - if (bodyBuilder_ == null) { - bodyBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.api.HttpBody, - com.google.api.HttpBody.Builder, - com.google.api.HttpBodyOrBuilder>(getBody(), getParentForChildren(), isClean()); - body_ = null; - } - return bodyBuilder_; - } - - private java.lang.Object projectId_ = ""; - /** - * - * - *
-     * Project in which the specified trigger lives
-     * 
- * - * string project_id = 2; - * - * @return The projectId. - */ - public java.lang.String getProjectId() { - java.lang.Object ref = projectId_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - projectId_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Project in which the specified trigger lives
-     * 
- * - * string project_id = 2; - * - * @return The bytes for projectId. - */ - public com.google.protobuf.ByteString getProjectIdBytes() { - java.lang.Object ref = projectId_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - projectId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Project in which the specified trigger lives
-     * 
- * - * string project_id = 2; - * - * @param value The projectId to set. - * @return This builder for chaining. - */ - public Builder setProjectId(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - projectId_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Project in which the specified trigger lives
-     * 
- * - * string project_id = 2; - * - * @return This builder for chaining. - */ - public Builder clearProjectId() { - - projectId_ = getDefaultInstance().getProjectId(); - onChanged(); - return this; - } - /** - * - * - *
-     * Project in which the specified trigger lives
-     * 
- * - * string project_id = 2; - * - * @param value The bytes for projectId to set. - * @return This builder for chaining. - */ - public Builder setProjectIdBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - projectId_ = value; - onChanged(); - return this; - } - - private java.lang.Object trigger_ = ""; - /** - * - * - *
-     * Name of the trigger to run the payload against
-     * 
- * - * string trigger = 3; - * - * @return The trigger. - */ - public java.lang.String getTrigger() { - java.lang.Object ref = trigger_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - trigger_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Name of the trigger to run the payload against
-     * 
- * - * string trigger = 3; - * - * @return The bytes for trigger. - */ - public com.google.protobuf.ByteString getTriggerBytes() { - java.lang.Object ref = trigger_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - trigger_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Name of the trigger to run the payload against
-     * 
- * - * string trigger = 3; - * - * @param value The trigger to set. - * @return This builder for chaining. - */ - public Builder setTrigger(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - trigger_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Name of the trigger to run the payload against
-     * 
- * - * string trigger = 3; - * - * @return This builder for chaining. - */ - public Builder clearTrigger() { - - trigger_ = getDefaultInstance().getTrigger(); - onChanged(); - return this; - } - /** - * - * - *
-     * Name of the trigger to run the payload against
-     * 
- * - * string trigger = 3; - * - * @param value The bytes for trigger to set. - * @return This builder for chaining. - */ - public Builder setTriggerBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - trigger_ = value; - onChanged(); - return this; - } - - private java.lang.Object secret_ = ""; - /** - * - * - *
-     * Secret token used for authorization if an OAuth token isn't provided.
-     * 
- * - * string secret = 4; - * - * @return The secret. - */ - public java.lang.String getSecret() { - java.lang.Object ref = secret_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - secret_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Secret token used for authorization if an OAuth token isn't provided.
-     * 
- * - * string secret = 4; - * - * @return The bytes for secret. - */ - public com.google.protobuf.ByteString getSecretBytes() { - java.lang.Object ref = secret_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - secret_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Secret token used for authorization if an OAuth token isn't provided.
-     * 
- * - * string secret = 4; - * - * @param value The secret to set. - * @return This builder for chaining. - */ - public Builder setSecret(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - secret_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Secret token used for authorization if an OAuth token isn't provided.
-     * 
- * - * string secret = 4; - * - * @return This builder for chaining. - */ - public Builder clearSecret() { - - secret_ = getDefaultInstance().getSecret(); - onChanged(); - return this; - } - /** - * - * - *
-     * Secret token used for authorization if an OAuth token isn't provided.
-     * 
- * - * string secret = 4; - * - * @param value The bytes for secret to set. - * @return This builder for chaining. - */ - public Builder setSecretBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - secret_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.ReceiveTriggerWebhookRequest) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.ReceiveTriggerWebhookRequest) - private static final com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest(); - } - - public static com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public ReceiveTriggerWebhookRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.ReceiveTriggerWebhookRequest getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ReceiveTriggerWebhookRequestOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ReceiveTriggerWebhookRequestOrBuilder.java deleted file mode 100644 index 7d8c9b5b..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ReceiveTriggerWebhookRequestOrBuilder.java +++ /dev/null @@ -1,162 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface ReceiveTriggerWebhookRequestOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.ReceiveTriggerWebhookRequest) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The name of the `ReceiveTriggerWebhook` to retrieve.
-   * Format: `projects/{project}/locations/{location}/triggers/{trigger}`
-   * 
- * - * string name = 5; - * - * @return The name. - */ - java.lang.String getName(); - /** - * - * - *
-   * The name of the `ReceiveTriggerWebhook` to retrieve.
-   * Format: `projects/{project}/locations/{location}/triggers/{trigger}`
-   * 
- * - * string name = 5; - * - * @return The bytes for name. - */ - com.google.protobuf.ByteString getNameBytes(); - - /** - * - * - *
-   * HTTP request body.
-   * 
- * - * .google.api.HttpBody body = 1; - * - * @return Whether the body field is set. - */ - boolean hasBody(); - /** - * - * - *
-   * HTTP request body.
-   * 
- * - * .google.api.HttpBody body = 1; - * - * @return The body. - */ - com.google.api.HttpBody getBody(); - /** - * - * - *
-   * HTTP request body.
-   * 
- * - * .google.api.HttpBody body = 1; - */ - com.google.api.HttpBodyOrBuilder getBodyOrBuilder(); - - /** - * - * - *
-   * Project in which the specified trigger lives
-   * 
- * - * string project_id = 2; - * - * @return The projectId. - */ - java.lang.String getProjectId(); - /** - * - * - *
-   * Project in which the specified trigger lives
-   * 
- * - * string project_id = 2; - * - * @return The bytes for projectId. - */ - com.google.protobuf.ByteString getProjectIdBytes(); - - /** - * - * - *
-   * Name of the trigger to run the payload against
-   * 
- * - * string trigger = 3; - * - * @return The trigger. - */ - java.lang.String getTrigger(); - /** - * - * - *
-   * Name of the trigger to run the payload against
-   * 
- * - * string trigger = 3; - * - * @return The bytes for trigger. - */ - com.google.protobuf.ByteString getTriggerBytes(); - - /** - * - * - *
-   * Secret token used for authorization if an OAuth token isn't provided.
-   * 
- * - * string secret = 4; - * - * @return The secret. - */ - java.lang.String getSecret(); - /** - * - * - *
-   * Secret token used for authorization if an OAuth token isn't provided.
-   * 
- * - * string secret = 4; - * - * @return The bytes for secret. - */ - com.google.protobuf.ByteString getSecretBytes(); -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ReceiveTriggerWebhookResponse.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ReceiveTriggerWebhookResponse.java deleted file mode 100644 index 39b4a63e..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ReceiveTriggerWebhookResponse.java +++ /dev/null @@ -1,439 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * ReceiveTriggerWebhookResponse [Experimental] is the response object for the
- * ReceiveTriggerWebhook method.
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.ReceiveTriggerWebhookResponse} - */ -public final class ReceiveTriggerWebhookResponse extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.ReceiveTriggerWebhookResponse) - ReceiveTriggerWebhookResponseOrBuilder { - private static final long serialVersionUID = 0L; - // Use ReceiveTriggerWebhookResponse.newBuilder() to construct. - private ReceiveTriggerWebhookResponse(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private ReceiveTriggerWebhookResponse() {} - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new ReceiveTriggerWebhookResponse(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ReceiveTriggerWebhookResponse_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ReceiveTriggerWebhookResponse_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse.class, - com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse.Builder.class); - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse other = - (com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse) obj; - - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder( - com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * ReceiveTriggerWebhookResponse [Experimental] is the response object for the
-   * ReceiveTriggerWebhook method.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.ReceiveTriggerWebhookResponse} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.ReceiveTriggerWebhookResponse) - com.google.cloudbuild.v1.ReceiveTriggerWebhookResponseOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ReceiveTriggerWebhookResponse_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ReceiveTriggerWebhookResponse_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse.class, - com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_ReceiveTriggerWebhookResponse_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse getDefaultInstanceForType() { - return com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse build() { - com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse buildPartial() { - com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse result = - new com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse(this); - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse) { - return mergeFrom((com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse other) { - if (other == com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse.getDefaultInstance()) - return this; - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.ReceiveTriggerWebhookResponse) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.ReceiveTriggerWebhookResponse) - private static final com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse(); - } - - public static com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public ReceiveTriggerWebhookResponse parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.ReceiveTriggerWebhookResponse getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ReceiveTriggerWebhookResponseOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ReceiveTriggerWebhookResponseOrBuilder.java deleted file mode 100644 index 8645ac8f..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ReceiveTriggerWebhookResponseOrBuilder.java +++ /dev/null @@ -1,24 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface ReceiveTriggerWebhookResponseOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.ReceiveTriggerWebhookResponse) - com.google.protobuf.MessageOrBuilder {} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/RepoSource.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/RepoSource.java deleted file mode 100644 index 3e4790e5..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/RepoSource.java +++ /dev/null @@ -1,2242 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * Location of the source in a Google Cloud Source Repository.
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.RepoSource} - */ -public final class RepoSource extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.RepoSource) - RepoSourceOrBuilder { - private static final long serialVersionUID = 0L; - // Use RepoSource.newBuilder() to construct. - private RepoSource(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private RepoSource() { - projectId_ = ""; - repoName_ = ""; - dir_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new RepoSource(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_RepoSource_descriptor; - } - - @SuppressWarnings({"rawtypes"}) - @java.lang.Override - protected com.google.protobuf.MapField internalGetMapField(int number) { - switch (number) { - case 9: - return internalGetSubstitutions(); - default: - throw new RuntimeException("Invalid map field number: " + number); - } - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_RepoSource_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.RepoSource.class, - com.google.cloudbuild.v1.RepoSource.Builder.class); - } - - private int revisionCase_ = 0; - private java.lang.Object revision_; - - public enum RevisionCase - implements - com.google.protobuf.Internal.EnumLite, - com.google.protobuf.AbstractMessage.InternalOneOfEnum { - BRANCH_NAME(3), - TAG_NAME(4), - COMMIT_SHA(5), - REVISION_NOT_SET(0); - private final int value; - - private RevisionCase(int value) { - this.value = value; - } - /** - * @param value The number of the enum to look for. - * @return The enum associated with the given number. - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static RevisionCase valueOf(int value) { - return forNumber(value); - } - - public static RevisionCase forNumber(int value) { - switch (value) { - case 3: - return BRANCH_NAME; - case 4: - return TAG_NAME; - case 5: - return COMMIT_SHA; - case 0: - return REVISION_NOT_SET; - default: - return null; - } - } - - public int getNumber() { - return this.value; - } - }; - - public RevisionCase getRevisionCase() { - return RevisionCase.forNumber(revisionCase_); - } - - public static final int PROJECT_ID_FIELD_NUMBER = 1; - private volatile java.lang.Object projectId_; - /** - * - * - *
-   * ID of the project that owns the Cloud Source Repository. If omitted, the
-   * project ID requesting the build is assumed.
-   * 
- * - * string project_id = 1; - * - * @return The projectId. - */ - @java.lang.Override - public java.lang.String getProjectId() { - java.lang.Object ref = projectId_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - projectId_ = s; - return s; - } - } - /** - * - * - *
-   * ID of the project that owns the Cloud Source Repository. If omitted, the
-   * project ID requesting the build is assumed.
-   * 
- * - * string project_id = 1; - * - * @return The bytes for projectId. - */ - @java.lang.Override - public com.google.protobuf.ByteString getProjectIdBytes() { - java.lang.Object ref = projectId_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - projectId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int REPO_NAME_FIELD_NUMBER = 2; - private volatile java.lang.Object repoName_; - /** - * - * - *
-   * Name of the Cloud Source Repository.
-   * 
- * - * string repo_name = 2; - * - * @return The repoName. - */ - @java.lang.Override - public java.lang.String getRepoName() { - java.lang.Object ref = repoName_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - repoName_ = s; - return s; - } - } - /** - * - * - *
-   * Name of the Cloud Source Repository.
-   * 
- * - * string repo_name = 2; - * - * @return The bytes for repoName. - */ - @java.lang.Override - public com.google.protobuf.ByteString getRepoNameBytes() { - java.lang.Object ref = repoName_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - repoName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int BRANCH_NAME_FIELD_NUMBER = 3; - /** - * - * - *
-   * Regex matching branches to build.
-   * The syntax of the regular expressions accepted is the syntax accepted by
-   * RE2 and described at https://github.com/google/re2/wiki/Syntax
-   * 
- * - * string branch_name = 3; - * - * @return Whether the branchName field is set. - */ - public boolean hasBranchName() { - return revisionCase_ == 3; - } - /** - * - * - *
-   * Regex matching branches to build.
-   * The syntax of the regular expressions accepted is the syntax accepted by
-   * RE2 and described at https://github.com/google/re2/wiki/Syntax
-   * 
- * - * string branch_name = 3; - * - * @return The branchName. - */ - public java.lang.String getBranchName() { - java.lang.Object ref = ""; - if (revisionCase_ == 3) { - ref = revision_; - } - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (revisionCase_ == 3) { - revision_ = s; - } - return s; - } - } - /** - * - * - *
-   * Regex matching branches to build.
-   * The syntax of the regular expressions accepted is the syntax accepted by
-   * RE2 and described at https://github.com/google/re2/wiki/Syntax
-   * 
- * - * string branch_name = 3; - * - * @return The bytes for branchName. - */ - public com.google.protobuf.ByteString getBranchNameBytes() { - java.lang.Object ref = ""; - if (revisionCase_ == 3) { - ref = revision_; - } - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - if (revisionCase_ == 3) { - revision_ = b; - } - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int TAG_NAME_FIELD_NUMBER = 4; - /** - * - * - *
-   * Regex matching tags to build.
-   * The syntax of the regular expressions accepted is the syntax accepted by
-   * RE2 and described at https://github.com/google/re2/wiki/Syntax
-   * 
- * - * string tag_name = 4; - * - * @return Whether the tagName field is set. - */ - public boolean hasTagName() { - return revisionCase_ == 4; - } - /** - * - * - *
-   * Regex matching tags to build.
-   * The syntax of the regular expressions accepted is the syntax accepted by
-   * RE2 and described at https://github.com/google/re2/wiki/Syntax
-   * 
- * - * string tag_name = 4; - * - * @return The tagName. - */ - public java.lang.String getTagName() { - java.lang.Object ref = ""; - if (revisionCase_ == 4) { - ref = revision_; - } - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (revisionCase_ == 4) { - revision_ = s; - } - return s; - } - } - /** - * - * - *
-   * Regex matching tags to build.
-   * The syntax of the regular expressions accepted is the syntax accepted by
-   * RE2 and described at https://github.com/google/re2/wiki/Syntax
-   * 
- * - * string tag_name = 4; - * - * @return The bytes for tagName. - */ - public com.google.protobuf.ByteString getTagNameBytes() { - java.lang.Object ref = ""; - if (revisionCase_ == 4) { - ref = revision_; - } - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - if (revisionCase_ == 4) { - revision_ = b; - } - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int COMMIT_SHA_FIELD_NUMBER = 5; - /** - * - * - *
-   * Explicit commit SHA to build.
-   * 
- * - * string commit_sha = 5; - * - * @return Whether the commitSha field is set. - */ - public boolean hasCommitSha() { - return revisionCase_ == 5; - } - /** - * - * - *
-   * Explicit commit SHA to build.
-   * 
- * - * string commit_sha = 5; - * - * @return The commitSha. - */ - public java.lang.String getCommitSha() { - java.lang.Object ref = ""; - if (revisionCase_ == 5) { - ref = revision_; - } - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (revisionCase_ == 5) { - revision_ = s; - } - return s; - } - } - /** - * - * - *
-   * Explicit commit SHA to build.
-   * 
- * - * string commit_sha = 5; - * - * @return The bytes for commitSha. - */ - public com.google.protobuf.ByteString getCommitShaBytes() { - java.lang.Object ref = ""; - if (revisionCase_ == 5) { - ref = revision_; - } - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - if (revisionCase_ == 5) { - revision_ = b; - } - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int DIR_FIELD_NUMBER = 7; - private volatile java.lang.Object dir_; - /** - * - * - *
-   * Directory, relative to the source root, in which to run the build.
-   * This must be a relative path. If a step's `dir` is specified and is an
-   * absolute path, this value is ignored for that step's execution.
-   * 
- * - * string dir = 7; - * - * @return The dir. - */ - @java.lang.Override - public java.lang.String getDir() { - java.lang.Object ref = dir_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - dir_ = s; - return s; - } - } - /** - * - * - *
-   * Directory, relative to the source root, in which to run the build.
-   * This must be a relative path. If a step's `dir` is specified and is an
-   * absolute path, this value is ignored for that step's execution.
-   * 
- * - * string dir = 7; - * - * @return The bytes for dir. - */ - @java.lang.Override - public com.google.protobuf.ByteString getDirBytes() { - java.lang.Object ref = dir_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - dir_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int INVERT_REGEX_FIELD_NUMBER = 8; - private boolean invertRegex_; - /** - * - * - *
-   * Only trigger a build if the revision regex does NOT match the revision
-   * regex.
-   * 
- * - * bool invert_regex = 8; - * - * @return The invertRegex. - */ - @java.lang.Override - public boolean getInvertRegex() { - return invertRegex_; - } - - public static final int SUBSTITUTIONS_FIELD_NUMBER = 9; - - private static final class SubstitutionsDefaultEntryHolder { - static final com.google.protobuf.MapEntry defaultEntry = - com.google.protobuf.MapEntry.newDefaultInstance( - com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_RepoSource_SubstitutionsEntry_descriptor, - com.google.protobuf.WireFormat.FieldType.STRING, - "", - com.google.protobuf.WireFormat.FieldType.STRING, - ""); - } - - private com.google.protobuf.MapField substitutions_; - - private com.google.protobuf.MapField - internalGetSubstitutions() { - if (substitutions_ == null) { - return com.google.protobuf.MapField.emptyMapField( - SubstitutionsDefaultEntryHolder.defaultEntry); - } - return substitutions_; - } - - public int getSubstitutionsCount() { - return internalGetSubstitutions().getMap().size(); - } - /** - * - * - *
-   * Substitutions to use in a triggered build.
-   * Should only be used with RunBuildTrigger
-   * 
- * - * map<string, string> substitutions = 9; - */ - @java.lang.Override - public boolean containsSubstitutions(java.lang.String key) { - if (key == null) { - throw new NullPointerException("map key"); - } - return internalGetSubstitutions().getMap().containsKey(key); - } - /** Use {@link #getSubstitutionsMap()} instead. */ - @java.lang.Override - @java.lang.Deprecated - public java.util.Map getSubstitutions() { - return getSubstitutionsMap(); - } - /** - * - * - *
-   * Substitutions to use in a triggered build.
-   * Should only be used with RunBuildTrigger
-   * 
- * - * map<string, string> substitutions = 9; - */ - @java.lang.Override - public java.util.Map getSubstitutionsMap() { - return internalGetSubstitutions().getMap(); - } - /** - * - * - *
-   * Substitutions to use in a triggered build.
-   * Should only be used with RunBuildTrigger
-   * 
- * - * map<string, string> substitutions = 9; - */ - @java.lang.Override - public java.lang.String getSubstitutionsOrDefault( - java.lang.String key, java.lang.String defaultValue) { - if (key == null) { - throw new NullPointerException("map key"); - } - java.util.Map map = internalGetSubstitutions().getMap(); - return map.containsKey(key) ? map.get(key) : defaultValue; - } - /** - * - * - *
-   * Substitutions to use in a triggered build.
-   * Should only be used with RunBuildTrigger
-   * 
- * - * map<string, string> substitutions = 9; - */ - @java.lang.Override - public java.lang.String getSubstitutionsOrThrow(java.lang.String key) { - if (key == null) { - throw new NullPointerException("map key"); - } - java.util.Map map = internalGetSubstitutions().getMap(); - if (!map.containsKey(key)) { - throw new java.lang.IllegalArgumentException(); - } - return map.get(key); - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(projectId_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, projectId_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(repoName_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, repoName_); - } - if (revisionCase_ == 3) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 3, revision_); - } - if (revisionCase_ == 4) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 4, revision_); - } - if (revisionCase_ == 5) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 5, revision_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(dir_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 7, dir_); - } - if (invertRegex_ != false) { - output.writeBool(8, invertRegex_); - } - com.google.protobuf.GeneratedMessageV3.serializeStringMapTo( - output, internalGetSubstitutions(), SubstitutionsDefaultEntryHolder.defaultEntry, 9); - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(projectId_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, projectId_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(repoName_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, repoName_); - } - if (revisionCase_ == 3) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, revision_); - } - if (revisionCase_ == 4) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, revision_); - } - if (revisionCase_ == 5) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(5, revision_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(dir_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(7, dir_); - } - if (invertRegex_ != false) { - size += com.google.protobuf.CodedOutputStream.computeBoolSize(8, invertRegex_); - } - for (java.util.Map.Entry entry : - internalGetSubstitutions().getMap().entrySet()) { - com.google.protobuf.MapEntry substitutions__ = - SubstitutionsDefaultEntryHolder.defaultEntry - .newBuilderForType() - .setKey(entry.getKey()) - .setValue(entry.getValue()) - .build(); - size += com.google.protobuf.CodedOutputStream.computeMessageSize(9, substitutions__); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.RepoSource)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.RepoSource other = (com.google.cloudbuild.v1.RepoSource) obj; - - if (!getProjectId().equals(other.getProjectId())) return false; - if (!getRepoName().equals(other.getRepoName())) return false; - if (!getDir().equals(other.getDir())) return false; - if (getInvertRegex() != other.getInvertRegex()) return false; - if (!internalGetSubstitutions().equals(other.internalGetSubstitutions())) return false; - if (!getRevisionCase().equals(other.getRevisionCase())) return false; - switch (revisionCase_) { - case 3: - if (!getBranchName().equals(other.getBranchName())) return false; - break; - case 4: - if (!getTagName().equals(other.getTagName())) return false; - break; - case 5: - if (!getCommitSha().equals(other.getCommitSha())) return false; - break; - case 0: - default: - } - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + PROJECT_ID_FIELD_NUMBER; - hash = (53 * hash) + getProjectId().hashCode(); - hash = (37 * hash) + REPO_NAME_FIELD_NUMBER; - hash = (53 * hash) + getRepoName().hashCode(); - hash = (37 * hash) + DIR_FIELD_NUMBER; - hash = (53 * hash) + getDir().hashCode(); - hash = (37 * hash) + INVERT_REGEX_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getInvertRegex()); - if (!internalGetSubstitutions().getMap().isEmpty()) { - hash = (37 * hash) + SUBSTITUTIONS_FIELD_NUMBER; - hash = (53 * hash) + internalGetSubstitutions().hashCode(); - } - switch (revisionCase_) { - case 3: - hash = (37 * hash) + BRANCH_NAME_FIELD_NUMBER; - hash = (53 * hash) + getBranchName().hashCode(); - break; - case 4: - hash = (37 * hash) + TAG_NAME_FIELD_NUMBER; - hash = (53 * hash) + getTagName().hashCode(); - break; - case 5: - hash = (37 * hash) + COMMIT_SHA_FIELD_NUMBER; - hash = (53 * hash) + getCommitSha().hashCode(); - break; - case 0: - default: - } - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.RepoSource parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.RepoSource parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.RepoSource parseFrom(com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.RepoSource parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.RepoSource parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.RepoSource parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.RepoSource parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.RepoSource parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.RepoSource parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.RepoSource parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.RepoSource parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.RepoSource parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.RepoSource prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * Location of the source in a Google Cloud Source Repository.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.RepoSource} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.RepoSource) - com.google.cloudbuild.v1.RepoSourceOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_RepoSource_descriptor; - } - - @SuppressWarnings({"rawtypes"}) - protected com.google.protobuf.MapField internalGetMapField(int number) { - switch (number) { - case 9: - return internalGetSubstitutions(); - default: - throw new RuntimeException("Invalid map field number: " + number); - } - } - - @SuppressWarnings({"rawtypes"}) - protected com.google.protobuf.MapField internalGetMutableMapField(int number) { - switch (number) { - case 9: - return internalGetMutableSubstitutions(); - default: - throw new RuntimeException("Invalid map field number: " + number); - } - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_RepoSource_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.RepoSource.class, - com.google.cloudbuild.v1.RepoSource.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.RepoSource.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - projectId_ = ""; - - repoName_ = ""; - - dir_ = ""; - - invertRegex_ = false; - - internalGetMutableSubstitutions().clear(); - revisionCase_ = 0; - revision_ = null; - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_RepoSource_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.RepoSource getDefaultInstanceForType() { - return com.google.cloudbuild.v1.RepoSource.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.RepoSource build() { - com.google.cloudbuild.v1.RepoSource result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.RepoSource buildPartial() { - com.google.cloudbuild.v1.RepoSource result = new com.google.cloudbuild.v1.RepoSource(this); - int from_bitField0_ = bitField0_; - result.projectId_ = projectId_; - result.repoName_ = repoName_; - if (revisionCase_ == 3) { - result.revision_ = revision_; - } - if (revisionCase_ == 4) { - result.revision_ = revision_; - } - if (revisionCase_ == 5) { - result.revision_ = revision_; - } - result.dir_ = dir_; - result.invertRegex_ = invertRegex_; - result.substitutions_ = internalGetSubstitutions(); - result.substitutions_.makeImmutable(); - result.revisionCase_ = revisionCase_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.RepoSource) { - return mergeFrom((com.google.cloudbuild.v1.RepoSource) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.RepoSource other) { - if (other == com.google.cloudbuild.v1.RepoSource.getDefaultInstance()) return this; - if (!other.getProjectId().isEmpty()) { - projectId_ = other.projectId_; - onChanged(); - } - if (!other.getRepoName().isEmpty()) { - repoName_ = other.repoName_; - onChanged(); - } - if (!other.getDir().isEmpty()) { - dir_ = other.dir_; - onChanged(); - } - if (other.getInvertRegex() != false) { - setInvertRegex(other.getInvertRegex()); - } - internalGetMutableSubstitutions().mergeFrom(other.internalGetSubstitutions()); - switch (other.getRevisionCase()) { - case BRANCH_NAME: - { - revisionCase_ = 3; - revision_ = other.revision_; - onChanged(); - break; - } - case TAG_NAME: - { - revisionCase_ = 4; - revision_ = other.revision_; - onChanged(); - break; - } - case COMMIT_SHA: - { - revisionCase_ = 5; - revision_ = other.revision_; - onChanged(); - break; - } - case REVISION_NOT_SET: - { - break; - } - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - projectId_ = input.readStringRequireUtf8(); - - break; - } // case 10 - case 18: - { - repoName_ = input.readStringRequireUtf8(); - - break; - } // case 18 - case 26: - { - java.lang.String s = input.readStringRequireUtf8(); - revisionCase_ = 3; - revision_ = s; - break; - } // case 26 - case 34: - { - java.lang.String s = input.readStringRequireUtf8(); - revisionCase_ = 4; - revision_ = s; - break; - } // case 34 - case 42: - { - java.lang.String s = input.readStringRequireUtf8(); - revisionCase_ = 5; - revision_ = s; - break; - } // case 42 - case 58: - { - dir_ = input.readStringRequireUtf8(); - - break; - } // case 58 - case 64: - { - invertRegex_ = input.readBool(); - - break; - } // case 64 - case 74: - { - com.google.protobuf.MapEntry substitutions__ = - input.readMessage( - SubstitutionsDefaultEntryHolder.defaultEntry.getParserForType(), - extensionRegistry); - internalGetMutableSubstitutions() - .getMutableMap() - .put(substitutions__.getKey(), substitutions__.getValue()); - break; - } // case 74 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private int revisionCase_ = 0; - private java.lang.Object revision_; - - public RevisionCase getRevisionCase() { - return RevisionCase.forNumber(revisionCase_); - } - - public Builder clearRevision() { - revisionCase_ = 0; - revision_ = null; - onChanged(); - return this; - } - - private int bitField0_; - - private java.lang.Object projectId_ = ""; - /** - * - * - *
-     * ID of the project that owns the Cloud Source Repository. If omitted, the
-     * project ID requesting the build is assumed.
-     * 
- * - * string project_id = 1; - * - * @return The projectId. - */ - public java.lang.String getProjectId() { - java.lang.Object ref = projectId_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - projectId_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * ID of the project that owns the Cloud Source Repository. If omitted, the
-     * project ID requesting the build is assumed.
-     * 
- * - * string project_id = 1; - * - * @return The bytes for projectId. - */ - public com.google.protobuf.ByteString getProjectIdBytes() { - java.lang.Object ref = projectId_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - projectId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * ID of the project that owns the Cloud Source Repository. If omitted, the
-     * project ID requesting the build is assumed.
-     * 
- * - * string project_id = 1; - * - * @param value The projectId to set. - * @return This builder for chaining. - */ - public Builder setProjectId(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - projectId_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * ID of the project that owns the Cloud Source Repository. If omitted, the
-     * project ID requesting the build is assumed.
-     * 
- * - * string project_id = 1; - * - * @return This builder for chaining. - */ - public Builder clearProjectId() { - - projectId_ = getDefaultInstance().getProjectId(); - onChanged(); - return this; - } - /** - * - * - *
-     * ID of the project that owns the Cloud Source Repository. If omitted, the
-     * project ID requesting the build is assumed.
-     * 
- * - * string project_id = 1; - * - * @param value The bytes for projectId to set. - * @return This builder for chaining. - */ - public Builder setProjectIdBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - projectId_ = value; - onChanged(); - return this; - } - - private java.lang.Object repoName_ = ""; - /** - * - * - *
-     * Name of the Cloud Source Repository.
-     * 
- * - * string repo_name = 2; - * - * @return The repoName. - */ - public java.lang.String getRepoName() { - java.lang.Object ref = repoName_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - repoName_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Name of the Cloud Source Repository.
-     * 
- * - * string repo_name = 2; - * - * @return The bytes for repoName. - */ - public com.google.protobuf.ByteString getRepoNameBytes() { - java.lang.Object ref = repoName_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - repoName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Name of the Cloud Source Repository.
-     * 
- * - * string repo_name = 2; - * - * @param value The repoName to set. - * @return This builder for chaining. - */ - public Builder setRepoName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - repoName_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Name of the Cloud Source Repository.
-     * 
- * - * string repo_name = 2; - * - * @return This builder for chaining. - */ - public Builder clearRepoName() { - - repoName_ = getDefaultInstance().getRepoName(); - onChanged(); - return this; - } - /** - * - * - *
-     * Name of the Cloud Source Repository.
-     * 
- * - * string repo_name = 2; - * - * @param value The bytes for repoName to set. - * @return This builder for chaining. - */ - public Builder setRepoNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - repoName_ = value; - onChanged(); - return this; - } - - /** - * - * - *
-     * Regex matching branches to build.
-     * The syntax of the regular expressions accepted is the syntax accepted by
-     * RE2 and described at https://github.com/google/re2/wiki/Syntax
-     * 
- * - * string branch_name = 3; - * - * @return Whether the branchName field is set. - */ - @java.lang.Override - public boolean hasBranchName() { - return revisionCase_ == 3; - } - /** - * - * - *
-     * Regex matching branches to build.
-     * The syntax of the regular expressions accepted is the syntax accepted by
-     * RE2 and described at https://github.com/google/re2/wiki/Syntax
-     * 
- * - * string branch_name = 3; - * - * @return The branchName. - */ - @java.lang.Override - public java.lang.String getBranchName() { - java.lang.Object ref = ""; - if (revisionCase_ == 3) { - ref = revision_; - } - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (revisionCase_ == 3) { - revision_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Regex matching branches to build.
-     * The syntax of the regular expressions accepted is the syntax accepted by
-     * RE2 and described at https://github.com/google/re2/wiki/Syntax
-     * 
- * - * string branch_name = 3; - * - * @return The bytes for branchName. - */ - @java.lang.Override - public com.google.protobuf.ByteString getBranchNameBytes() { - java.lang.Object ref = ""; - if (revisionCase_ == 3) { - ref = revision_; - } - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - if (revisionCase_ == 3) { - revision_ = b; - } - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Regex matching branches to build.
-     * The syntax of the regular expressions accepted is the syntax accepted by
-     * RE2 and described at https://github.com/google/re2/wiki/Syntax
-     * 
- * - * string branch_name = 3; - * - * @param value The branchName to set. - * @return This builder for chaining. - */ - public Builder setBranchName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - revisionCase_ = 3; - revision_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Regex matching branches to build.
-     * The syntax of the regular expressions accepted is the syntax accepted by
-     * RE2 and described at https://github.com/google/re2/wiki/Syntax
-     * 
- * - * string branch_name = 3; - * - * @return This builder for chaining. - */ - public Builder clearBranchName() { - if (revisionCase_ == 3) { - revisionCase_ = 0; - revision_ = null; - onChanged(); - } - return this; - } - /** - * - * - *
-     * Regex matching branches to build.
-     * The syntax of the regular expressions accepted is the syntax accepted by
-     * RE2 and described at https://github.com/google/re2/wiki/Syntax
-     * 
- * - * string branch_name = 3; - * - * @param value The bytes for branchName to set. - * @return This builder for chaining. - */ - public Builder setBranchNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - revisionCase_ = 3; - revision_ = value; - onChanged(); - return this; - } - - /** - * - * - *
-     * Regex matching tags to build.
-     * The syntax of the regular expressions accepted is the syntax accepted by
-     * RE2 and described at https://github.com/google/re2/wiki/Syntax
-     * 
- * - * string tag_name = 4; - * - * @return Whether the tagName field is set. - */ - @java.lang.Override - public boolean hasTagName() { - return revisionCase_ == 4; - } - /** - * - * - *
-     * Regex matching tags to build.
-     * The syntax of the regular expressions accepted is the syntax accepted by
-     * RE2 and described at https://github.com/google/re2/wiki/Syntax
-     * 
- * - * string tag_name = 4; - * - * @return The tagName. - */ - @java.lang.Override - public java.lang.String getTagName() { - java.lang.Object ref = ""; - if (revisionCase_ == 4) { - ref = revision_; - } - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (revisionCase_ == 4) { - revision_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Regex matching tags to build.
-     * The syntax of the regular expressions accepted is the syntax accepted by
-     * RE2 and described at https://github.com/google/re2/wiki/Syntax
-     * 
- * - * string tag_name = 4; - * - * @return The bytes for tagName. - */ - @java.lang.Override - public com.google.protobuf.ByteString getTagNameBytes() { - java.lang.Object ref = ""; - if (revisionCase_ == 4) { - ref = revision_; - } - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - if (revisionCase_ == 4) { - revision_ = b; - } - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Regex matching tags to build.
-     * The syntax of the regular expressions accepted is the syntax accepted by
-     * RE2 and described at https://github.com/google/re2/wiki/Syntax
-     * 
- * - * string tag_name = 4; - * - * @param value The tagName to set. - * @return This builder for chaining. - */ - public Builder setTagName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - revisionCase_ = 4; - revision_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Regex matching tags to build.
-     * The syntax of the regular expressions accepted is the syntax accepted by
-     * RE2 and described at https://github.com/google/re2/wiki/Syntax
-     * 
- * - * string tag_name = 4; - * - * @return This builder for chaining. - */ - public Builder clearTagName() { - if (revisionCase_ == 4) { - revisionCase_ = 0; - revision_ = null; - onChanged(); - } - return this; - } - /** - * - * - *
-     * Regex matching tags to build.
-     * The syntax of the regular expressions accepted is the syntax accepted by
-     * RE2 and described at https://github.com/google/re2/wiki/Syntax
-     * 
- * - * string tag_name = 4; - * - * @param value The bytes for tagName to set. - * @return This builder for chaining. - */ - public Builder setTagNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - revisionCase_ = 4; - revision_ = value; - onChanged(); - return this; - } - - /** - * - * - *
-     * Explicit commit SHA to build.
-     * 
- * - * string commit_sha = 5; - * - * @return Whether the commitSha field is set. - */ - @java.lang.Override - public boolean hasCommitSha() { - return revisionCase_ == 5; - } - /** - * - * - *
-     * Explicit commit SHA to build.
-     * 
- * - * string commit_sha = 5; - * - * @return The commitSha. - */ - @java.lang.Override - public java.lang.String getCommitSha() { - java.lang.Object ref = ""; - if (revisionCase_ == 5) { - ref = revision_; - } - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (revisionCase_ == 5) { - revision_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Explicit commit SHA to build.
-     * 
- * - * string commit_sha = 5; - * - * @return The bytes for commitSha. - */ - @java.lang.Override - public com.google.protobuf.ByteString getCommitShaBytes() { - java.lang.Object ref = ""; - if (revisionCase_ == 5) { - ref = revision_; - } - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - if (revisionCase_ == 5) { - revision_ = b; - } - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Explicit commit SHA to build.
-     * 
- * - * string commit_sha = 5; - * - * @param value The commitSha to set. - * @return This builder for chaining. - */ - public Builder setCommitSha(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - revisionCase_ = 5; - revision_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Explicit commit SHA to build.
-     * 
- * - * string commit_sha = 5; - * - * @return This builder for chaining. - */ - public Builder clearCommitSha() { - if (revisionCase_ == 5) { - revisionCase_ = 0; - revision_ = null; - onChanged(); - } - return this; - } - /** - * - * - *
-     * Explicit commit SHA to build.
-     * 
- * - * string commit_sha = 5; - * - * @param value The bytes for commitSha to set. - * @return This builder for chaining. - */ - public Builder setCommitShaBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - revisionCase_ = 5; - revision_ = value; - onChanged(); - return this; - } - - private java.lang.Object dir_ = ""; - /** - * - * - *
-     * Directory, relative to the source root, in which to run the build.
-     * This must be a relative path. If a step's `dir` is specified and is an
-     * absolute path, this value is ignored for that step's execution.
-     * 
- * - * string dir = 7; - * - * @return The dir. - */ - public java.lang.String getDir() { - java.lang.Object ref = dir_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - dir_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Directory, relative to the source root, in which to run the build.
-     * This must be a relative path. If a step's `dir` is specified and is an
-     * absolute path, this value is ignored for that step's execution.
-     * 
- * - * string dir = 7; - * - * @return The bytes for dir. - */ - public com.google.protobuf.ByteString getDirBytes() { - java.lang.Object ref = dir_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - dir_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Directory, relative to the source root, in which to run the build.
-     * This must be a relative path. If a step's `dir` is specified and is an
-     * absolute path, this value is ignored for that step's execution.
-     * 
- * - * string dir = 7; - * - * @param value The dir to set. - * @return This builder for chaining. - */ - public Builder setDir(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - dir_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Directory, relative to the source root, in which to run the build.
-     * This must be a relative path. If a step's `dir` is specified and is an
-     * absolute path, this value is ignored for that step's execution.
-     * 
- * - * string dir = 7; - * - * @return This builder for chaining. - */ - public Builder clearDir() { - - dir_ = getDefaultInstance().getDir(); - onChanged(); - return this; - } - /** - * - * - *
-     * Directory, relative to the source root, in which to run the build.
-     * This must be a relative path. If a step's `dir` is specified and is an
-     * absolute path, this value is ignored for that step's execution.
-     * 
- * - * string dir = 7; - * - * @param value The bytes for dir to set. - * @return This builder for chaining. - */ - public Builder setDirBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - dir_ = value; - onChanged(); - return this; - } - - private boolean invertRegex_; - /** - * - * - *
-     * Only trigger a build if the revision regex does NOT match the revision
-     * regex.
-     * 
- * - * bool invert_regex = 8; - * - * @return The invertRegex. - */ - @java.lang.Override - public boolean getInvertRegex() { - return invertRegex_; - } - /** - * - * - *
-     * Only trigger a build if the revision regex does NOT match the revision
-     * regex.
-     * 
- * - * bool invert_regex = 8; - * - * @param value The invertRegex to set. - * @return This builder for chaining. - */ - public Builder setInvertRegex(boolean value) { - - invertRegex_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Only trigger a build if the revision regex does NOT match the revision
-     * regex.
-     * 
- * - * bool invert_regex = 8; - * - * @return This builder for chaining. - */ - public Builder clearInvertRegex() { - - invertRegex_ = false; - onChanged(); - return this; - } - - private com.google.protobuf.MapField substitutions_; - - private com.google.protobuf.MapField - internalGetSubstitutions() { - if (substitutions_ == null) { - return com.google.protobuf.MapField.emptyMapField( - SubstitutionsDefaultEntryHolder.defaultEntry); - } - return substitutions_; - } - - private com.google.protobuf.MapField - internalGetMutableSubstitutions() { - onChanged(); - ; - if (substitutions_ == null) { - substitutions_ = - com.google.protobuf.MapField.newMapField(SubstitutionsDefaultEntryHolder.defaultEntry); - } - if (!substitutions_.isMutable()) { - substitutions_ = substitutions_.copy(); - } - return substitutions_; - } - - public int getSubstitutionsCount() { - return internalGetSubstitutions().getMap().size(); - } - /** - * - * - *
-     * Substitutions to use in a triggered build.
-     * Should only be used with RunBuildTrigger
-     * 
- * - * map<string, string> substitutions = 9; - */ - @java.lang.Override - public boolean containsSubstitutions(java.lang.String key) { - if (key == null) { - throw new NullPointerException("map key"); - } - return internalGetSubstitutions().getMap().containsKey(key); - } - /** Use {@link #getSubstitutionsMap()} instead. */ - @java.lang.Override - @java.lang.Deprecated - public java.util.Map getSubstitutions() { - return getSubstitutionsMap(); - } - /** - * - * - *
-     * Substitutions to use in a triggered build.
-     * Should only be used with RunBuildTrigger
-     * 
- * - * map<string, string> substitutions = 9; - */ - @java.lang.Override - public java.util.Map getSubstitutionsMap() { - return internalGetSubstitutions().getMap(); - } - /** - * - * - *
-     * Substitutions to use in a triggered build.
-     * Should only be used with RunBuildTrigger
-     * 
- * - * map<string, string> substitutions = 9; - */ - @java.lang.Override - public java.lang.String getSubstitutionsOrDefault( - java.lang.String key, java.lang.String defaultValue) { - if (key == null) { - throw new NullPointerException("map key"); - } - java.util.Map map = internalGetSubstitutions().getMap(); - return map.containsKey(key) ? map.get(key) : defaultValue; - } - /** - * - * - *
-     * Substitutions to use in a triggered build.
-     * Should only be used with RunBuildTrigger
-     * 
- * - * map<string, string> substitutions = 9; - */ - @java.lang.Override - public java.lang.String getSubstitutionsOrThrow(java.lang.String key) { - if (key == null) { - throw new NullPointerException("map key"); - } - java.util.Map map = internalGetSubstitutions().getMap(); - if (!map.containsKey(key)) { - throw new java.lang.IllegalArgumentException(); - } - return map.get(key); - } - - public Builder clearSubstitutions() { - internalGetMutableSubstitutions().getMutableMap().clear(); - return this; - } - /** - * - * - *
-     * Substitutions to use in a triggered build.
-     * Should only be used with RunBuildTrigger
-     * 
- * - * map<string, string> substitutions = 9; - */ - public Builder removeSubstitutions(java.lang.String key) { - if (key == null) { - throw new NullPointerException("map key"); - } - internalGetMutableSubstitutions().getMutableMap().remove(key); - return this; - } - /** Use alternate mutation accessors instead. */ - @java.lang.Deprecated - public java.util.Map getMutableSubstitutions() { - return internalGetMutableSubstitutions().getMutableMap(); - } - /** - * - * - *
-     * Substitutions to use in a triggered build.
-     * Should only be used with RunBuildTrigger
-     * 
- * - * map<string, string> substitutions = 9; - */ - public Builder putSubstitutions(java.lang.String key, java.lang.String value) { - if (key == null) { - throw new NullPointerException("map key"); - } - if (value == null) { - throw new NullPointerException("map value"); - } - - internalGetMutableSubstitutions().getMutableMap().put(key, value); - return this; - } - /** - * - * - *
-     * Substitutions to use in a triggered build.
-     * Should only be used with RunBuildTrigger
-     * 
- * - * map<string, string> substitutions = 9; - */ - public Builder putAllSubstitutions(java.util.Map values) { - internalGetMutableSubstitutions().getMutableMap().putAll(values); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.RepoSource) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.RepoSource) - private static final com.google.cloudbuild.v1.RepoSource DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.RepoSource(); - } - - public static com.google.cloudbuild.v1.RepoSource getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public RepoSource parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.RepoSource getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/RepoSourceOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/RepoSourceOrBuilder.java deleted file mode 100644 index 24529ce8..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/RepoSourceOrBuilder.java +++ /dev/null @@ -1,309 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface RepoSourceOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.RepoSource) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * ID of the project that owns the Cloud Source Repository. If omitted, the
-   * project ID requesting the build is assumed.
-   * 
- * - * string project_id = 1; - * - * @return The projectId. - */ - java.lang.String getProjectId(); - /** - * - * - *
-   * ID of the project that owns the Cloud Source Repository. If omitted, the
-   * project ID requesting the build is assumed.
-   * 
- * - * string project_id = 1; - * - * @return The bytes for projectId. - */ - com.google.protobuf.ByteString getProjectIdBytes(); - - /** - * - * - *
-   * Name of the Cloud Source Repository.
-   * 
- * - * string repo_name = 2; - * - * @return The repoName. - */ - java.lang.String getRepoName(); - /** - * - * - *
-   * Name of the Cloud Source Repository.
-   * 
- * - * string repo_name = 2; - * - * @return The bytes for repoName. - */ - com.google.protobuf.ByteString getRepoNameBytes(); - - /** - * - * - *
-   * Regex matching branches to build.
-   * The syntax of the regular expressions accepted is the syntax accepted by
-   * RE2 and described at https://github.com/google/re2/wiki/Syntax
-   * 
- * - * string branch_name = 3; - * - * @return Whether the branchName field is set. - */ - boolean hasBranchName(); - /** - * - * - *
-   * Regex matching branches to build.
-   * The syntax of the regular expressions accepted is the syntax accepted by
-   * RE2 and described at https://github.com/google/re2/wiki/Syntax
-   * 
- * - * string branch_name = 3; - * - * @return The branchName. - */ - java.lang.String getBranchName(); - /** - * - * - *
-   * Regex matching branches to build.
-   * The syntax of the regular expressions accepted is the syntax accepted by
-   * RE2 and described at https://github.com/google/re2/wiki/Syntax
-   * 
- * - * string branch_name = 3; - * - * @return The bytes for branchName. - */ - com.google.protobuf.ByteString getBranchNameBytes(); - - /** - * - * - *
-   * Regex matching tags to build.
-   * The syntax of the regular expressions accepted is the syntax accepted by
-   * RE2 and described at https://github.com/google/re2/wiki/Syntax
-   * 
- * - * string tag_name = 4; - * - * @return Whether the tagName field is set. - */ - boolean hasTagName(); - /** - * - * - *
-   * Regex matching tags to build.
-   * The syntax of the regular expressions accepted is the syntax accepted by
-   * RE2 and described at https://github.com/google/re2/wiki/Syntax
-   * 
- * - * string tag_name = 4; - * - * @return The tagName. - */ - java.lang.String getTagName(); - /** - * - * - *
-   * Regex matching tags to build.
-   * The syntax of the regular expressions accepted is the syntax accepted by
-   * RE2 and described at https://github.com/google/re2/wiki/Syntax
-   * 
- * - * string tag_name = 4; - * - * @return The bytes for tagName. - */ - com.google.protobuf.ByteString getTagNameBytes(); - - /** - * - * - *
-   * Explicit commit SHA to build.
-   * 
- * - * string commit_sha = 5; - * - * @return Whether the commitSha field is set. - */ - boolean hasCommitSha(); - /** - * - * - *
-   * Explicit commit SHA to build.
-   * 
- * - * string commit_sha = 5; - * - * @return The commitSha. - */ - java.lang.String getCommitSha(); - /** - * - * - *
-   * Explicit commit SHA to build.
-   * 
- * - * string commit_sha = 5; - * - * @return The bytes for commitSha. - */ - com.google.protobuf.ByteString getCommitShaBytes(); - - /** - * - * - *
-   * Directory, relative to the source root, in which to run the build.
-   * This must be a relative path. If a step's `dir` is specified and is an
-   * absolute path, this value is ignored for that step's execution.
-   * 
- * - * string dir = 7; - * - * @return The dir. - */ - java.lang.String getDir(); - /** - * - * - *
-   * Directory, relative to the source root, in which to run the build.
-   * This must be a relative path. If a step's `dir` is specified and is an
-   * absolute path, this value is ignored for that step's execution.
-   * 
- * - * string dir = 7; - * - * @return The bytes for dir. - */ - com.google.protobuf.ByteString getDirBytes(); - - /** - * - * - *
-   * Only trigger a build if the revision regex does NOT match the revision
-   * regex.
-   * 
- * - * bool invert_regex = 8; - * - * @return The invertRegex. - */ - boolean getInvertRegex(); - - /** - * - * - *
-   * Substitutions to use in a triggered build.
-   * Should only be used with RunBuildTrigger
-   * 
- * - * map<string, string> substitutions = 9; - */ - int getSubstitutionsCount(); - /** - * - * - *
-   * Substitutions to use in a triggered build.
-   * Should only be used with RunBuildTrigger
-   * 
- * - * map<string, string> substitutions = 9; - */ - boolean containsSubstitutions(java.lang.String key); - /** Use {@link #getSubstitutionsMap()} instead. */ - @java.lang.Deprecated - java.util.Map getSubstitutions(); - /** - * - * - *
-   * Substitutions to use in a triggered build.
-   * Should only be used with RunBuildTrigger
-   * 
- * - * map<string, string> substitutions = 9; - */ - java.util.Map getSubstitutionsMap(); - /** - * - * - *
-   * Substitutions to use in a triggered build.
-   * Should only be used with RunBuildTrigger
-   * 
- * - * map<string, string> substitutions = 9; - */ - - /* nullable */ - java.lang.String getSubstitutionsOrDefault( - java.lang.String key, - /* nullable */ - java.lang.String defaultValue); - /** - * - * - *
-   * Substitutions to use in a triggered build.
-   * Should only be used with RunBuildTrigger
-   * 
- * - * map<string, string> substitutions = 9; - */ - java.lang.String getSubstitutionsOrThrow(java.lang.String key); - - public com.google.cloudbuild.v1.RepoSource.RevisionCase getRevisionCase(); -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Results.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Results.java deleted file mode 100644 index ae128f3e..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Results.java +++ /dev/null @@ -1,2003 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * Artifacts created by the build pipeline.
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.Results} - */ -public final class Results extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.Results) - ResultsOrBuilder { - private static final long serialVersionUID = 0L; - // Use Results.newBuilder() to construct. - private Results(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private Results() { - images_ = java.util.Collections.emptyList(); - buildStepImages_ = com.google.protobuf.LazyStringArrayList.EMPTY; - artifactManifest_ = ""; - buildStepOutputs_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new Results(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Results_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Results_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.Results.class, com.google.cloudbuild.v1.Results.Builder.class); - } - - public static final int IMAGES_FIELD_NUMBER = 2; - private java.util.List images_; - /** - * - * - *
-   * Container images that were built as a part of the build.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.BuiltImage images = 2; - */ - @java.lang.Override - public java.util.List getImagesList() { - return images_; - } - /** - * - * - *
-   * Container images that were built as a part of the build.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.BuiltImage images = 2; - */ - @java.lang.Override - public java.util.List - getImagesOrBuilderList() { - return images_; - } - /** - * - * - *
-   * Container images that were built as a part of the build.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.BuiltImage images = 2; - */ - @java.lang.Override - public int getImagesCount() { - return images_.size(); - } - /** - * - * - *
-   * Container images that were built as a part of the build.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.BuiltImage images = 2; - */ - @java.lang.Override - public com.google.cloudbuild.v1.BuiltImage getImages(int index) { - return images_.get(index); - } - /** - * - * - *
-   * Container images that were built as a part of the build.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.BuiltImage images = 2; - */ - @java.lang.Override - public com.google.cloudbuild.v1.BuiltImageOrBuilder getImagesOrBuilder(int index) { - return images_.get(index); - } - - public static final int BUILD_STEP_IMAGES_FIELD_NUMBER = 3; - private com.google.protobuf.LazyStringList buildStepImages_; - /** - * - * - *
-   * List of build step digests, in the order corresponding to build step
-   * indices.
-   * 
- * - * repeated string build_step_images = 3; - * - * @return A list containing the buildStepImages. - */ - public com.google.protobuf.ProtocolStringList getBuildStepImagesList() { - return buildStepImages_; - } - /** - * - * - *
-   * List of build step digests, in the order corresponding to build step
-   * indices.
-   * 
- * - * repeated string build_step_images = 3; - * - * @return The count of buildStepImages. - */ - public int getBuildStepImagesCount() { - return buildStepImages_.size(); - } - /** - * - * - *
-   * List of build step digests, in the order corresponding to build step
-   * indices.
-   * 
- * - * repeated string build_step_images = 3; - * - * @param index The index of the element to return. - * @return The buildStepImages at the given index. - */ - public java.lang.String getBuildStepImages(int index) { - return buildStepImages_.get(index); - } - /** - * - * - *
-   * List of build step digests, in the order corresponding to build step
-   * indices.
-   * 
- * - * repeated string build_step_images = 3; - * - * @param index The index of the value to return. - * @return The bytes of the buildStepImages at the given index. - */ - public com.google.protobuf.ByteString getBuildStepImagesBytes(int index) { - return buildStepImages_.getByteString(index); - } - - public static final int ARTIFACT_MANIFEST_FIELD_NUMBER = 4; - private volatile java.lang.Object artifactManifest_; - /** - * - * - *
-   * Path to the artifact manifest. Only populated when artifacts are uploaded.
-   * 
- * - * string artifact_manifest = 4; - * - * @return The artifactManifest. - */ - @java.lang.Override - public java.lang.String getArtifactManifest() { - java.lang.Object ref = artifactManifest_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - artifactManifest_ = s; - return s; - } - } - /** - * - * - *
-   * Path to the artifact manifest. Only populated when artifacts are uploaded.
-   * 
- * - * string artifact_manifest = 4; - * - * @return The bytes for artifactManifest. - */ - @java.lang.Override - public com.google.protobuf.ByteString getArtifactManifestBytes() { - java.lang.Object ref = artifactManifest_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - artifactManifest_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int NUM_ARTIFACTS_FIELD_NUMBER = 5; - private long numArtifacts_; - /** - * - * - *
-   * Number of artifacts uploaded. Only populated when artifacts are uploaded.
-   * 
- * - * int64 num_artifacts = 5; - * - * @return The numArtifacts. - */ - @java.lang.Override - public long getNumArtifacts() { - return numArtifacts_; - } - - public static final int BUILD_STEP_OUTPUTS_FIELD_NUMBER = 6; - private java.util.List buildStepOutputs_; - /** - * - * - *
-   * List of build step outputs, produced by builder images, in the order
-   * corresponding to build step indices.
-   * [Cloud Builders](https://cloud.google.com/cloud-build/docs/cloud-builders)
-   * can produce this output by writing to `$BUILDER_OUTPUT/output`.
-   * Only the first 4KB of data is stored.
-   * 
- * - * repeated bytes build_step_outputs = 6; - * - * @return A list containing the buildStepOutputs. - */ - @java.lang.Override - public java.util.List getBuildStepOutputsList() { - return buildStepOutputs_; - } - /** - * - * - *
-   * List of build step outputs, produced by builder images, in the order
-   * corresponding to build step indices.
-   * [Cloud Builders](https://cloud.google.com/cloud-build/docs/cloud-builders)
-   * can produce this output by writing to `$BUILDER_OUTPUT/output`.
-   * Only the first 4KB of data is stored.
-   * 
- * - * repeated bytes build_step_outputs = 6; - * - * @return The count of buildStepOutputs. - */ - public int getBuildStepOutputsCount() { - return buildStepOutputs_.size(); - } - /** - * - * - *
-   * List of build step outputs, produced by builder images, in the order
-   * corresponding to build step indices.
-   * [Cloud Builders](https://cloud.google.com/cloud-build/docs/cloud-builders)
-   * can produce this output by writing to `$BUILDER_OUTPUT/output`.
-   * Only the first 4KB of data is stored.
-   * 
- * - * repeated bytes build_step_outputs = 6; - * - * @param index The index of the element to return. - * @return The buildStepOutputs at the given index. - */ - public com.google.protobuf.ByteString getBuildStepOutputs(int index) { - return buildStepOutputs_.get(index); - } - - public static final int ARTIFACT_TIMING_FIELD_NUMBER = 7; - private com.google.cloudbuild.v1.TimeSpan artifactTiming_; - /** - * - * - *
-   * Time to push all non-container artifacts.
-   * 
- * - * .google.devtools.cloudbuild.v1.TimeSpan artifact_timing = 7; - * - * @return Whether the artifactTiming field is set. - */ - @java.lang.Override - public boolean hasArtifactTiming() { - return artifactTiming_ != null; - } - /** - * - * - *
-   * Time to push all non-container artifacts.
-   * 
- * - * .google.devtools.cloudbuild.v1.TimeSpan artifact_timing = 7; - * - * @return The artifactTiming. - */ - @java.lang.Override - public com.google.cloudbuild.v1.TimeSpan getArtifactTiming() { - return artifactTiming_ == null - ? com.google.cloudbuild.v1.TimeSpan.getDefaultInstance() - : artifactTiming_; - } - /** - * - * - *
-   * Time to push all non-container artifacts.
-   * 
- * - * .google.devtools.cloudbuild.v1.TimeSpan artifact_timing = 7; - */ - @java.lang.Override - public com.google.cloudbuild.v1.TimeSpanOrBuilder getArtifactTimingOrBuilder() { - return getArtifactTiming(); - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - for (int i = 0; i < images_.size(); i++) { - output.writeMessage(2, images_.get(i)); - } - for (int i = 0; i < buildStepImages_.size(); i++) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 3, buildStepImages_.getRaw(i)); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(artifactManifest_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 4, artifactManifest_); - } - if (numArtifacts_ != 0L) { - output.writeInt64(5, numArtifacts_); - } - for (int i = 0; i < buildStepOutputs_.size(); i++) { - output.writeBytes(6, buildStepOutputs_.get(i)); - } - if (artifactTiming_ != null) { - output.writeMessage(7, getArtifactTiming()); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - for (int i = 0; i < images_.size(); i++) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, images_.get(i)); - } - { - int dataSize = 0; - for (int i = 0; i < buildStepImages_.size(); i++) { - dataSize += computeStringSizeNoTag(buildStepImages_.getRaw(i)); - } - size += dataSize; - size += 1 * getBuildStepImagesList().size(); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(artifactManifest_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, artifactManifest_); - } - if (numArtifacts_ != 0L) { - size += com.google.protobuf.CodedOutputStream.computeInt64Size(5, numArtifacts_); - } - { - int dataSize = 0; - for (int i = 0; i < buildStepOutputs_.size(); i++) { - dataSize += - com.google.protobuf.CodedOutputStream.computeBytesSizeNoTag(buildStepOutputs_.get(i)); - } - size += dataSize; - size += 1 * getBuildStepOutputsList().size(); - } - if (artifactTiming_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(7, getArtifactTiming()); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.Results)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.Results other = (com.google.cloudbuild.v1.Results) obj; - - if (!getImagesList().equals(other.getImagesList())) return false; - if (!getBuildStepImagesList().equals(other.getBuildStepImagesList())) return false; - if (!getArtifactManifest().equals(other.getArtifactManifest())) return false; - if (getNumArtifacts() != other.getNumArtifacts()) return false; - if (!getBuildStepOutputsList().equals(other.getBuildStepOutputsList())) return false; - if (hasArtifactTiming() != other.hasArtifactTiming()) return false; - if (hasArtifactTiming()) { - if (!getArtifactTiming().equals(other.getArtifactTiming())) return false; - } - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (getImagesCount() > 0) { - hash = (37 * hash) + IMAGES_FIELD_NUMBER; - hash = (53 * hash) + getImagesList().hashCode(); - } - if (getBuildStepImagesCount() > 0) { - hash = (37 * hash) + BUILD_STEP_IMAGES_FIELD_NUMBER; - hash = (53 * hash) + getBuildStepImagesList().hashCode(); - } - hash = (37 * hash) + ARTIFACT_MANIFEST_FIELD_NUMBER; - hash = (53 * hash) + getArtifactManifest().hashCode(); - hash = (37 * hash) + NUM_ARTIFACTS_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getNumArtifacts()); - if (getBuildStepOutputsCount() > 0) { - hash = (37 * hash) + BUILD_STEP_OUTPUTS_FIELD_NUMBER; - hash = (53 * hash) + getBuildStepOutputsList().hashCode(); - } - if (hasArtifactTiming()) { - hash = (37 * hash) + ARTIFACT_TIMING_FIELD_NUMBER; - hash = (53 * hash) + getArtifactTiming().hashCode(); - } - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.Results parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.Results parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.Results parseFrom(com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.Results parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.Results parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.Results parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.Results parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.Results parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.Results parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.Results parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.Results parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.Results parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.Results prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * Artifacts created by the build pipeline.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.Results} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.Results) - com.google.cloudbuild.v1.ResultsOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Results_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Results_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.Results.class, - com.google.cloudbuild.v1.Results.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.Results.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - if (imagesBuilder_ == null) { - images_ = java.util.Collections.emptyList(); - } else { - images_ = null; - imagesBuilder_.clear(); - } - bitField0_ = (bitField0_ & ~0x00000001); - buildStepImages_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000002); - artifactManifest_ = ""; - - numArtifacts_ = 0L; - - buildStepOutputs_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000004); - if (artifactTimingBuilder_ == null) { - artifactTiming_ = null; - } else { - artifactTiming_ = null; - artifactTimingBuilder_ = null; - } - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Results_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.Results getDefaultInstanceForType() { - return com.google.cloudbuild.v1.Results.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.Results build() { - com.google.cloudbuild.v1.Results result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.Results buildPartial() { - com.google.cloudbuild.v1.Results result = new com.google.cloudbuild.v1.Results(this); - int from_bitField0_ = bitField0_; - if (imagesBuilder_ == null) { - if (((bitField0_ & 0x00000001) != 0)) { - images_ = java.util.Collections.unmodifiableList(images_); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.images_ = images_; - } else { - result.images_ = imagesBuilder_.build(); - } - if (((bitField0_ & 0x00000002) != 0)) { - buildStepImages_ = buildStepImages_.getUnmodifiableView(); - bitField0_ = (bitField0_ & ~0x00000002); - } - result.buildStepImages_ = buildStepImages_; - result.artifactManifest_ = artifactManifest_; - result.numArtifacts_ = numArtifacts_; - if (((bitField0_ & 0x00000004) != 0)) { - buildStepOutputs_ = java.util.Collections.unmodifiableList(buildStepOutputs_); - bitField0_ = (bitField0_ & ~0x00000004); - } - result.buildStepOutputs_ = buildStepOutputs_; - if (artifactTimingBuilder_ == null) { - result.artifactTiming_ = artifactTiming_; - } else { - result.artifactTiming_ = artifactTimingBuilder_.build(); - } - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.Results) { - return mergeFrom((com.google.cloudbuild.v1.Results) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.Results other) { - if (other == com.google.cloudbuild.v1.Results.getDefaultInstance()) return this; - if (imagesBuilder_ == null) { - if (!other.images_.isEmpty()) { - if (images_.isEmpty()) { - images_ = other.images_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureImagesIsMutable(); - images_.addAll(other.images_); - } - onChanged(); - } - } else { - if (!other.images_.isEmpty()) { - if (imagesBuilder_.isEmpty()) { - imagesBuilder_.dispose(); - imagesBuilder_ = null; - images_ = other.images_; - bitField0_ = (bitField0_ & ~0x00000001); - imagesBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders - ? getImagesFieldBuilder() - : null; - } else { - imagesBuilder_.addAllMessages(other.images_); - } - } - } - if (!other.buildStepImages_.isEmpty()) { - if (buildStepImages_.isEmpty()) { - buildStepImages_ = other.buildStepImages_; - bitField0_ = (bitField0_ & ~0x00000002); - } else { - ensureBuildStepImagesIsMutable(); - buildStepImages_.addAll(other.buildStepImages_); - } - onChanged(); - } - if (!other.getArtifactManifest().isEmpty()) { - artifactManifest_ = other.artifactManifest_; - onChanged(); - } - if (other.getNumArtifacts() != 0L) { - setNumArtifacts(other.getNumArtifacts()); - } - if (!other.buildStepOutputs_.isEmpty()) { - if (buildStepOutputs_.isEmpty()) { - buildStepOutputs_ = other.buildStepOutputs_; - bitField0_ = (bitField0_ & ~0x00000004); - } else { - ensureBuildStepOutputsIsMutable(); - buildStepOutputs_.addAll(other.buildStepOutputs_); - } - onChanged(); - } - if (other.hasArtifactTiming()) { - mergeArtifactTiming(other.getArtifactTiming()); - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 18: - { - com.google.cloudbuild.v1.BuiltImage m = - input.readMessage( - com.google.cloudbuild.v1.BuiltImage.parser(), extensionRegistry); - if (imagesBuilder_ == null) { - ensureImagesIsMutable(); - images_.add(m); - } else { - imagesBuilder_.addMessage(m); - } - break; - } // case 18 - case 26: - { - java.lang.String s = input.readStringRequireUtf8(); - ensureBuildStepImagesIsMutable(); - buildStepImages_.add(s); - break; - } // case 26 - case 34: - { - artifactManifest_ = input.readStringRequireUtf8(); - - break; - } // case 34 - case 40: - { - numArtifacts_ = input.readInt64(); - - break; - } // case 40 - case 50: - { - com.google.protobuf.ByteString v = input.readBytes(); - ensureBuildStepOutputsIsMutable(); - buildStepOutputs_.add(v); - break; - } // case 50 - case 58: - { - input.readMessage(getArtifactTimingFieldBuilder().getBuilder(), extensionRegistry); - - break; - } // case 58 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private int bitField0_; - - private java.util.List images_ = - java.util.Collections.emptyList(); - - private void ensureImagesIsMutable() { - if (!((bitField0_ & 0x00000001) != 0)) { - images_ = new java.util.ArrayList(images_); - bitField0_ |= 0x00000001; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloudbuild.v1.BuiltImage, - com.google.cloudbuild.v1.BuiltImage.Builder, - com.google.cloudbuild.v1.BuiltImageOrBuilder> - imagesBuilder_; - - /** - * - * - *
-     * Container images that were built as a part of the build.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.BuiltImage images = 2; - */ - public java.util.List getImagesList() { - if (imagesBuilder_ == null) { - return java.util.Collections.unmodifiableList(images_); - } else { - return imagesBuilder_.getMessageList(); - } - } - /** - * - * - *
-     * Container images that were built as a part of the build.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.BuiltImage images = 2; - */ - public int getImagesCount() { - if (imagesBuilder_ == null) { - return images_.size(); - } else { - return imagesBuilder_.getCount(); - } - } - /** - * - * - *
-     * Container images that were built as a part of the build.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.BuiltImage images = 2; - */ - public com.google.cloudbuild.v1.BuiltImage getImages(int index) { - if (imagesBuilder_ == null) { - return images_.get(index); - } else { - return imagesBuilder_.getMessage(index); - } - } - /** - * - * - *
-     * Container images that were built as a part of the build.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.BuiltImage images = 2; - */ - public Builder setImages(int index, com.google.cloudbuild.v1.BuiltImage value) { - if (imagesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureImagesIsMutable(); - images_.set(index, value); - onChanged(); - } else { - imagesBuilder_.setMessage(index, value); - } - return this; - } - /** - * - * - *
-     * Container images that were built as a part of the build.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.BuiltImage images = 2; - */ - public Builder setImages( - int index, com.google.cloudbuild.v1.BuiltImage.Builder builderForValue) { - if (imagesBuilder_ == null) { - ensureImagesIsMutable(); - images_.set(index, builderForValue.build()); - onChanged(); - } else { - imagesBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * Container images that were built as a part of the build.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.BuiltImage images = 2; - */ - public Builder addImages(com.google.cloudbuild.v1.BuiltImage value) { - if (imagesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureImagesIsMutable(); - images_.add(value); - onChanged(); - } else { - imagesBuilder_.addMessage(value); - } - return this; - } - /** - * - * - *
-     * Container images that were built as a part of the build.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.BuiltImage images = 2; - */ - public Builder addImages(int index, com.google.cloudbuild.v1.BuiltImage value) { - if (imagesBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureImagesIsMutable(); - images_.add(index, value); - onChanged(); - } else { - imagesBuilder_.addMessage(index, value); - } - return this; - } - /** - * - * - *
-     * Container images that were built as a part of the build.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.BuiltImage images = 2; - */ - public Builder addImages(com.google.cloudbuild.v1.BuiltImage.Builder builderForValue) { - if (imagesBuilder_ == null) { - ensureImagesIsMutable(); - images_.add(builderForValue.build()); - onChanged(); - } else { - imagesBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * Container images that were built as a part of the build.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.BuiltImage images = 2; - */ - public Builder addImages( - int index, com.google.cloudbuild.v1.BuiltImage.Builder builderForValue) { - if (imagesBuilder_ == null) { - ensureImagesIsMutable(); - images_.add(index, builderForValue.build()); - onChanged(); - } else { - imagesBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * Container images that were built as a part of the build.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.BuiltImage images = 2; - */ - public Builder addAllImages( - java.lang.Iterable values) { - if (imagesBuilder_ == null) { - ensureImagesIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, images_); - onChanged(); - } else { - imagesBuilder_.addAllMessages(values); - } - return this; - } - /** - * - * - *
-     * Container images that were built as a part of the build.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.BuiltImage images = 2; - */ - public Builder clearImages() { - if (imagesBuilder_ == null) { - images_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - } else { - imagesBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * Container images that were built as a part of the build.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.BuiltImage images = 2; - */ - public Builder removeImages(int index) { - if (imagesBuilder_ == null) { - ensureImagesIsMutable(); - images_.remove(index); - onChanged(); - } else { - imagesBuilder_.remove(index); - } - return this; - } - /** - * - * - *
-     * Container images that were built as a part of the build.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.BuiltImage images = 2; - */ - public com.google.cloudbuild.v1.BuiltImage.Builder getImagesBuilder(int index) { - return getImagesFieldBuilder().getBuilder(index); - } - /** - * - * - *
-     * Container images that were built as a part of the build.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.BuiltImage images = 2; - */ - public com.google.cloudbuild.v1.BuiltImageOrBuilder getImagesOrBuilder(int index) { - if (imagesBuilder_ == null) { - return images_.get(index); - } else { - return imagesBuilder_.getMessageOrBuilder(index); - } - } - /** - * - * - *
-     * Container images that were built as a part of the build.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.BuiltImage images = 2; - */ - public java.util.List - getImagesOrBuilderList() { - if (imagesBuilder_ != null) { - return imagesBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(images_); - } - } - /** - * - * - *
-     * Container images that were built as a part of the build.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.BuiltImage images = 2; - */ - public com.google.cloudbuild.v1.BuiltImage.Builder addImagesBuilder() { - return getImagesFieldBuilder() - .addBuilder(com.google.cloudbuild.v1.BuiltImage.getDefaultInstance()); - } - /** - * - * - *
-     * Container images that were built as a part of the build.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.BuiltImage images = 2; - */ - public com.google.cloudbuild.v1.BuiltImage.Builder addImagesBuilder(int index) { - return getImagesFieldBuilder() - .addBuilder(index, com.google.cloudbuild.v1.BuiltImage.getDefaultInstance()); - } - /** - * - * - *
-     * Container images that were built as a part of the build.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.BuiltImage images = 2; - */ - public java.util.List getImagesBuilderList() { - return getImagesFieldBuilder().getBuilderList(); - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloudbuild.v1.BuiltImage, - com.google.cloudbuild.v1.BuiltImage.Builder, - com.google.cloudbuild.v1.BuiltImageOrBuilder> - getImagesFieldBuilder() { - if (imagesBuilder_ == null) { - imagesBuilder_ = - new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloudbuild.v1.BuiltImage, - com.google.cloudbuild.v1.BuiltImage.Builder, - com.google.cloudbuild.v1.BuiltImageOrBuilder>( - images_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean()); - images_ = null; - } - return imagesBuilder_; - } - - private com.google.protobuf.LazyStringList buildStepImages_ = - com.google.protobuf.LazyStringArrayList.EMPTY; - - private void ensureBuildStepImagesIsMutable() { - if (!((bitField0_ & 0x00000002) != 0)) { - buildStepImages_ = new com.google.protobuf.LazyStringArrayList(buildStepImages_); - bitField0_ |= 0x00000002; - } - } - /** - * - * - *
-     * List of build step digests, in the order corresponding to build step
-     * indices.
-     * 
- * - * repeated string build_step_images = 3; - * - * @return A list containing the buildStepImages. - */ - public com.google.protobuf.ProtocolStringList getBuildStepImagesList() { - return buildStepImages_.getUnmodifiableView(); - } - /** - * - * - *
-     * List of build step digests, in the order corresponding to build step
-     * indices.
-     * 
- * - * repeated string build_step_images = 3; - * - * @return The count of buildStepImages. - */ - public int getBuildStepImagesCount() { - return buildStepImages_.size(); - } - /** - * - * - *
-     * List of build step digests, in the order corresponding to build step
-     * indices.
-     * 
- * - * repeated string build_step_images = 3; - * - * @param index The index of the element to return. - * @return The buildStepImages at the given index. - */ - public java.lang.String getBuildStepImages(int index) { - return buildStepImages_.get(index); - } - /** - * - * - *
-     * List of build step digests, in the order corresponding to build step
-     * indices.
-     * 
- * - * repeated string build_step_images = 3; - * - * @param index The index of the value to return. - * @return The bytes of the buildStepImages at the given index. - */ - public com.google.protobuf.ByteString getBuildStepImagesBytes(int index) { - return buildStepImages_.getByteString(index); - } - /** - * - * - *
-     * List of build step digests, in the order corresponding to build step
-     * indices.
-     * 
- * - * repeated string build_step_images = 3; - * - * @param index The index to set the value at. - * @param value The buildStepImages to set. - * @return This builder for chaining. - */ - public Builder setBuildStepImages(int index, java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureBuildStepImagesIsMutable(); - buildStepImages_.set(index, value); - onChanged(); - return this; - } - /** - * - * - *
-     * List of build step digests, in the order corresponding to build step
-     * indices.
-     * 
- * - * repeated string build_step_images = 3; - * - * @param value The buildStepImages to add. - * @return This builder for chaining. - */ - public Builder addBuildStepImages(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - ensureBuildStepImagesIsMutable(); - buildStepImages_.add(value); - onChanged(); - return this; - } - /** - * - * - *
-     * List of build step digests, in the order corresponding to build step
-     * indices.
-     * 
- * - * repeated string build_step_images = 3; - * - * @param values The buildStepImages to add. - * @return This builder for chaining. - */ - public Builder addAllBuildStepImages(java.lang.Iterable values) { - ensureBuildStepImagesIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, buildStepImages_); - onChanged(); - return this; - } - /** - * - * - *
-     * List of build step digests, in the order corresponding to build step
-     * indices.
-     * 
- * - * repeated string build_step_images = 3; - * - * @return This builder for chaining. - */ - public Builder clearBuildStepImages() { - buildStepImages_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000002); - onChanged(); - return this; - } - /** - * - * - *
-     * List of build step digests, in the order corresponding to build step
-     * indices.
-     * 
- * - * repeated string build_step_images = 3; - * - * @param value The bytes of the buildStepImages to add. - * @return This builder for chaining. - */ - public Builder addBuildStepImagesBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - ensureBuildStepImagesIsMutable(); - buildStepImages_.add(value); - onChanged(); - return this; - } - - private java.lang.Object artifactManifest_ = ""; - /** - * - * - *
-     * Path to the artifact manifest. Only populated when artifacts are uploaded.
-     * 
- * - * string artifact_manifest = 4; - * - * @return The artifactManifest. - */ - public java.lang.String getArtifactManifest() { - java.lang.Object ref = artifactManifest_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - artifactManifest_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Path to the artifact manifest. Only populated when artifacts are uploaded.
-     * 
- * - * string artifact_manifest = 4; - * - * @return The bytes for artifactManifest. - */ - public com.google.protobuf.ByteString getArtifactManifestBytes() { - java.lang.Object ref = artifactManifest_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - artifactManifest_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Path to the artifact manifest. Only populated when artifacts are uploaded.
-     * 
- * - * string artifact_manifest = 4; - * - * @param value The artifactManifest to set. - * @return This builder for chaining. - */ - public Builder setArtifactManifest(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - artifactManifest_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Path to the artifact manifest. Only populated when artifacts are uploaded.
-     * 
- * - * string artifact_manifest = 4; - * - * @return This builder for chaining. - */ - public Builder clearArtifactManifest() { - - artifactManifest_ = getDefaultInstance().getArtifactManifest(); - onChanged(); - return this; - } - /** - * - * - *
-     * Path to the artifact manifest. Only populated when artifacts are uploaded.
-     * 
- * - * string artifact_manifest = 4; - * - * @param value The bytes for artifactManifest to set. - * @return This builder for chaining. - */ - public Builder setArtifactManifestBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - artifactManifest_ = value; - onChanged(); - return this; - } - - private long numArtifacts_; - /** - * - * - *
-     * Number of artifacts uploaded. Only populated when artifacts are uploaded.
-     * 
- * - * int64 num_artifacts = 5; - * - * @return The numArtifacts. - */ - @java.lang.Override - public long getNumArtifacts() { - return numArtifacts_; - } - /** - * - * - *
-     * Number of artifacts uploaded. Only populated when artifacts are uploaded.
-     * 
- * - * int64 num_artifacts = 5; - * - * @param value The numArtifacts to set. - * @return This builder for chaining. - */ - public Builder setNumArtifacts(long value) { - - numArtifacts_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Number of artifacts uploaded. Only populated when artifacts are uploaded.
-     * 
- * - * int64 num_artifacts = 5; - * - * @return This builder for chaining. - */ - public Builder clearNumArtifacts() { - - numArtifacts_ = 0L; - onChanged(); - return this; - } - - private java.util.List buildStepOutputs_ = - java.util.Collections.emptyList(); - - private void ensureBuildStepOutputsIsMutable() { - if (!((bitField0_ & 0x00000004) != 0)) { - buildStepOutputs_ = - new java.util.ArrayList(buildStepOutputs_); - bitField0_ |= 0x00000004; - } - } - /** - * - * - *
-     * List of build step outputs, produced by builder images, in the order
-     * corresponding to build step indices.
-     * [Cloud Builders](https://cloud.google.com/cloud-build/docs/cloud-builders)
-     * can produce this output by writing to `$BUILDER_OUTPUT/output`.
-     * Only the first 4KB of data is stored.
-     * 
- * - * repeated bytes build_step_outputs = 6; - * - * @return A list containing the buildStepOutputs. - */ - public java.util.List getBuildStepOutputsList() { - return ((bitField0_ & 0x00000004) != 0) - ? java.util.Collections.unmodifiableList(buildStepOutputs_) - : buildStepOutputs_; - } - /** - * - * - *
-     * List of build step outputs, produced by builder images, in the order
-     * corresponding to build step indices.
-     * [Cloud Builders](https://cloud.google.com/cloud-build/docs/cloud-builders)
-     * can produce this output by writing to `$BUILDER_OUTPUT/output`.
-     * Only the first 4KB of data is stored.
-     * 
- * - * repeated bytes build_step_outputs = 6; - * - * @return The count of buildStepOutputs. - */ - public int getBuildStepOutputsCount() { - return buildStepOutputs_.size(); - } - /** - * - * - *
-     * List of build step outputs, produced by builder images, in the order
-     * corresponding to build step indices.
-     * [Cloud Builders](https://cloud.google.com/cloud-build/docs/cloud-builders)
-     * can produce this output by writing to `$BUILDER_OUTPUT/output`.
-     * Only the first 4KB of data is stored.
-     * 
- * - * repeated bytes build_step_outputs = 6; - * - * @param index The index of the element to return. - * @return The buildStepOutputs at the given index. - */ - public com.google.protobuf.ByteString getBuildStepOutputs(int index) { - return buildStepOutputs_.get(index); - } - /** - * - * - *
-     * List of build step outputs, produced by builder images, in the order
-     * corresponding to build step indices.
-     * [Cloud Builders](https://cloud.google.com/cloud-build/docs/cloud-builders)
-     * can produce this output by writing to `$BUILDER_OUTPUT/output`.
-     * Only the first 4KB of data is stored.
-     * 
- * - * repeated bytes build_step_outputs = 6; - * - * @param index The index to set the value at. - * @param value The buildStepOutputs to set. - * @return This builder for chaining. - */ - public Builder setBuildStepOutputs(int index, com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - ensureBuildStepOutputsIsMutable(); - buildStepOutputs_.set(index, value); - onChanged(); - return this; - } - /** - * - * - *
-     * List of build step outputs, produced by builder images, in the order
-     * corresponding to build step indices.
-     * [Cloud Builders](https://cloud.google.com/cloud-build/docs/cloud-builders)
-     * can produce this output by writing to `$BUILDER_OUTPUT/output`.
-     * Only the first 4KB of data is stored.
-     * 
- * - * repeated bytes build_step_outputs = 6; - * - * @param value The buildStepOutputs to add. - * @return This builder for chaining. - */ - public Builder addBuildStepOutputs(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - ensureBuildStepOutputsIsMutable(); - buildStepOutputs_.add(value); - onChanged(); - return this; - } - /** - * - * - *
-     * List of build step outputs, produced by builder images, in the order
-     * corresponding to build step indices.
-     * [Cloud Builders](https://cloud.google.com/cloud-build/docs/cloud-builders)
-     * can produce this output by writing to `$BUILDER_OUTPUT/output`.
-     * Only the first 4KB of data is stored.
-     * 
- * - * repeated bytes build_step_outputs = 6; - * - * @param values The buildStepOutputs to add. - * @return This builder for chaining. - */ - public Builder addAllBuildStepOutputs( - java.lang.Iterable values) { - ensureBuildStepOutputsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, buildStepOutputs_); - onChanged(); - return this; - } - /** - * - * - *
-     * List of build step outputs, produced by builder images, in the order
-     * corresponding to build step indices.
-     * [Cloud Builders](https://cloud.google.com/cloud-build/docs/cloud-builders)
-     * can produce this output by writing to `$BUILDER_OUTPUT/output`.
-     * Only the first 4KB of data is stored.
-     * 
- * - * repeated bytes build_step_outputs = 6; - * - * @return This builder for chaining. - */ - public Builder clearBuildStepOutputs() { - buildStepOutputs_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000004); - onChanged(); - return this; - } - - private com.google.cloudbuild.v1.TimeSpan artifactTiming_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.TimeSpan, - com.google.cloudbuild.v1.TimeSpan.Builder, - com.google.cloudbuild.v1.TimeSpanOrBuilder> - artifactTimingBuilder_; - /** - * - * - *
-     * Time to push all non-container artifacts.
-     * 
- * - * .google.devtools.cloudbuild.v1.TimeSpan artifact_timing = 7; - * - * @return Whether the artifactTiming field is set. - */ - public boolean hasArtifactTiming() { - return artifactTimingBuilder_ != null || artifactTiming_ != null; - } - /** - * - * - *
-     * Time to push all non-container artifacts.
-     * 
- * - * .google.devtools.cloudbuild.v1.TimeSpan artifact_timing = 7; - * - * @return The artifactTiming. - */ - public com.google.cloudbuild.v1.TimeSpan getArtifactTiming() { - if (artifactTimingBuilder_ == null) { - return artifactTiming_ == null - ? com.google.cloudbuild.v1.TimeSpan.getDefaultInstance() - : artifactTiming_; - } else { - return artifactTimingBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Time to push all non-container artifacts.
-     * 
- * - * .google.devtools.cloudbuild.v1.TimeSpan artifact_timing = 7; - */ - public Builder setArtifactTiming(com.google.cloudbuild.v1.TimeSpan value) { - if (artifactTimingBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - artifactTiming_ = value; - onChanged(); - } else { - artifactTimingBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * Time to push all non-container artifacts.
-     * 
- * - * .google.devtools.cloudbuild.v1.TimeSpan artifact_timing = 7; - */ - public Builder setArtifactTiming(com.google.cloudbuild.v1.TimeSpan.Builder builderForValue) { - if (artifactTimingBuilder_ == null) { - artifactTiming_ = builderForValue.build(); - onChanged(); - } else { - artifactTimingBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Time to push all non-container artifacts.
-     * 
- * - * .google.devtools.cloudbuild.v1.TimeSpan artifact_timing = 7; - */ - public Builder mergeArtifactTiming(com.google.cloudbuild.v1.TimeSpan value) { - if (artifactTimingBuilder_ == null) { - if (artifactTiming_ != null) { - artifactTiming_ = - com.google.cloudbuild.v1.TimeSpan.newBuilder(artifactTiming_) - .mergeFrom(value) - .buildPartial(); - } else { - artifactTiming_ = value; - } - onChanged(); - } else { - artifactTimingBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * Time to push all non-container artifacts.
-     * 
- * - * .google.devtools.cloudbuild.v1.TimeSpan artifact_timing = 7; - */ - public Builder clearArtifactTiming() { - if (artifactTimingBuilder_ == null) { - artifactTiming_ = null; - onChanged(); - } else { - artifactTiming_ = null; - artifactTimingBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Time to push all non-container artifacts.
-     * 
- * - * .google.devtools.cloudbuild.v1.TimeSpan artifact_timing = 7; - */ - public com.google.cloudbuild.v1.TimeSpan.Builder getArtifactTimingBuilder() { - - onChanged(); - return getArtifactTimingFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Time to push all non-container artifacts.
-     * 
- * - * .google.devtools.cloudbuild.v1.TimeSpan artifact_timing = 7; - */ - public com.google.cloudbuild.v1.TimeSpanOrBuilder getArtifactTimingOrBuilder() { - if (artifactTimingBuilder_ != null) { - return artifactTimingBuilder_.getMessageOrBuilder(); - } else { - return artifactTiming_ == null - ? com.google.cloudbuild.v1.TimeSpan.getDefaultInstance() - : artifactTiming_; - } - } - /** - * - * - *
-     * Time to push all non-container artifacts.
-     * 
- * - * .google.devtools.cloudbuild.v1.TimeSpan artifact_timing = 7; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.TimeSpan, - com.google.cloudbuild.v1.TimeSpan.Builder, - com.google.cloudbuild.v1.TimeSpanOrBuilder> - getArtifactTimingFieldBuilder() { - if (artifactTimingBuilder_ == null) { - artifactTimingBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.TimeSpan, - com.google.cloudbuild.v1.TimeSpan.Builder, - com.google.cloudbuild.v1.TimeSpanOrBuilder>( - getArtifactTiming(), getParentForChildren(), isClean()); - artifactTiming_ = null; - } - return artifactTimingBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.Results) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.Results) - private static final com.google.cloudbuild.v1.Results DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.Results(); - } - - public static com.google.cloudbuild.v1.Results getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public Results parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.Results getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ResultsOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ResultsOrBuilder.java deleted file mode 100644 index 42c21510..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ResultsOrBuilder.java +++ /dev/null @@ -1,254 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface ResultsOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.Results) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * Container images that were built as a part of the build.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.BuiltImage images = 2; - */ - java.util.List getImagesList(); - /** - * - * - *
-   * Container images that were built as a part of the build.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.BuiltImage images = 2; - */ - com.google.cloudbuild.v1.BuiltImage getImages(int index); - /** - * - * - *
-   * Container images that were built as a part of the build.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.BuiltImage images = 2; - */ - int getImagesCount(); - /** - * - * - *
-   * Container images that were built as a part of the build.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.BuiltImage images = 2; - */ - java.util.List getImagesOrBuilderList(); - /** - * - * - *
-   * Container images that were built as a part of the build.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.BuiltImage images = 2; - */ - com.google.cloudbuild.v1.BuiltImageOrBuilder getImagesOrBuilder(int index); - - /** - * - * - *
-   * List of build step digests, in the order corresponding to build step
-   * indices.
-   * 
- * - * repeated string build_step_images = 3; - * - * @return A list containing the buildStepImages. - */ - java.util.List getBuildStepImagesList(); - /** - * - * - *
-   * List of build step digests, in the order corresponding to build step
-   * indices.
-   * 
- * - * repeated string build_step_images = 3; - * - * @return The count of buildStepImages. - */ - int getBuildStepImagesCount(); - /** - * - * - *
-   * List of build step digests, in the order corresponding to build step
-   * indices.
-   * 
- * - * repeated string build_step_images = 3; - * - * @param index The index of the element to return. - * @return The buildStepImages at the given index. - */ - java.lang.String getBuildStepImages(int index); - /** - * - * - *
-   * List of build step digests, in the order corresponding to build step
-   * indices.
-   * 
- * - * repeated string build_step_images = 3; - * - * @param index The index of the value to return. - * @return The bytes of the buildStepImages at the given index. - */ - com.google.protobuf.ByteString getBuildStepImagesBytes(int index); - - /** - * - * - *
-   * Path to the artifact manifest. Only populated when artifacts are uploaded.
-   * 
- * - * string artifact_manifest = 4; - * - * @return The artifactManifest. - */ - java.lang.String getArtifactManifest(); - /** - * - * - *
-   * Path to the artifact manifest. Only populated when artifacts are uploaded.
-   * 
- * - * string artifact_manifest = 4; - * - * @return The bytes for artifactManifest. - */ - com.google.protobuf.ByteString getArtifactManifestBytes(); - - /** - * - * - *
-   * Number of artifacts uploaded. Only populated when artifacts are uploaded.
-   * 
- * - * int64 num_artifacts = 5; - * - * @return The numArtifacts. - */ - long getNumArtifacts(); - - /** - * - * - *
-   * List of build step outputs, produced by builder images, in the order
-   * corresponding to build step indices.
-   * [Cloud Builders](https://cloud.google.com/cloud-build/docs/cloud-builders)
-   * can produce this output by writing to `$BUILDER_OUTPUT/output`.
-   * Only the first 4KB of data is stored.
-   * 
- * - * repeated bytes build_step_outputs = 6; - * - * @return A list containing the buildStepOutputs. - */ - java.util.List getBuildStepOutputsList(); - /** - * - * - *
-   * List of build step outputs, produced by builder images, in the order
-   * corresponding to build step indices.
-   * [Cloud Builders](https://cloud.google.com/cloud-build/docs/cloud-builders)
-   * can produce this output by writing to `$BUILDER_OUTPUT/output`.
-   * Only the first 4KB of data is stored.
-   * 
- * - * repeated bytes build_step_outputs = 6; - * - * @return The count of buildStepOutputs. - */ - int getBuildStepOutputsCount(); - /** - * - * - *
-   * List of build step outputs, produced by builder images, in the order
-   * corresponding to build step indices.
-   * [Cloud Builders](https://cloud.google.com/cloud-build/docs/cloud-builders)
-   * can produce this output by writing to `$BUILDER_OUTPUT/output`.
-   * Only the first 4KB of data is stored.
-   * 
- * - * repeated bytes build_step_outputs = 6; - * - * @param index The index of the element to return. - * @return The buildStepOutputs at the given index. - */ - com.google.protobuf.ByteString getBuildStepOutputs(int index); - - /** - * - * - *
-   * Time to push all non-container artifacts.
-   * 
- * - * .google.devtools.cloudbuild.v1.TimeSpan artifact_timing = 7; - * - * @return Whether the artifactTiming field is set. - */ - boolean hasArtifactTiming(); - /** - * - * - *
-   * Time to push all non-container artifacts.
-   * 
- * - * .google.devtools.cloudbuild.v1.TimeSpan artifact_timing = 7; - * - * @return The artifactTiming. - */ - com.google.cloudbuild.v1.TimeSpan getArtifactTiming(); - /** - * - * - *
-   * Time to push all non-container artifacts.
-   * 
- * - * .google.devtools.cloudbuild.v1.TimeSpan artifact_timing = 7; - */ - com.google.cloudbuild.v1.TimeSpanOrBuilder getArtifactTimingOrBuilder(); -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/RetryBuildRequest.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/RetryBuildRequest.java deleted file mode 100644 index 417e668d..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/RetryBuildRequest.java +++ /dev/null @@ -1,977 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * Specifies a build to retry.
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.RetryBuildRequest} - */ -public final class RetryBuildRequest extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.RetryBuildRequest) - RetryBuildRequestOrBuilder { - private static final long serialVersionUID = 0L; - // Use RetryBuildRequest.newBuilder() to construct. - private RetryBuildRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private RetryBuildRequest() { - name_ = ""; - projectId_ = ""; - id_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new RetryBuildRequest(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_RetryBuildRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_RetryBuildRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.RetryBuildRequest.class, - com.google.cloudbuild.v1.RetryBuildRequest.Builder.class); - } - - public static final int NAME_FIELD_NUMBER = 3; - private volatile java.lang.Object name_; - /** - * - * - *
-   * The name of the `Build` to retry.
-   * Format: `projects/{project}/locations/{location}/builds/{build}`
-   * 
- * - * string name = 3 [(.google.api.resource_reference) = { ... } - * - * @return The name. - */ - @java.lang.Override - public java.lang.String getName() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - name_ = s; - return s; - } - } - /** - * - * - *
-   * The name of the `Build` to retry.
-   * Format: `projects/{project}/locations/{location}/builds/{build}`
-   * 
- * - * string name = 3 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for name. - */ - @java.lang.Override - public com.google.protobuf.ByteString getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int PROJECT_ID_FIELD_NUMBER = 1; - private volatile java.lang.Object projectId_; - /** - * - * - *
-   * Required. ID of the project.
-   * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The projectId. - */ - @java.lang.Override - public java.lang.String getProjectId() { - java.lang.Object ref = projectId_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - projectId_ = s; - return s; - } - } - /** - * - * - *
-   * Required. ID of the project.
-   * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for projectId. - */ - @java.lang.Override - public com.google.protobuf.ByteString getProjectIdBytes() { - java.lang.Object ref = projectId_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - projectId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int ID_FIELD_NUMBER = 2; - private volatile java.lang.Object id_; - /** - * - * - *
-   * Required. Build ID of the original build.
-   * 
- * - * string id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The id. - */ - @java.lang.Override - public java.lang.String getId() { - java.lang.Object ref = id_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - id_ = s; - return s; - } - } - /** - * - * - *
-   * Required. Build ID of the original build.
-   * 
- * - * string id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for id. - */ - @java.lang.Override - public com.google.protobuf.ByteString getIdBytes() { - java.lang.Object ref = id_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - id_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(projectId_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, projectId_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(id_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, id_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 3, name_); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(projectId_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, projectId_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(id_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, id_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, name_); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.RetryBuildRequest)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.RetryBuildRequest other = - (com.google.cloudbuild.v1.RetryBuildRequest) obj; - - if (!getName().equals(other.getName())) return false; - if (!getProjectId().equals(other.getProjectId())) return false; - if (!getId().equals(other.getId())) return false; - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + NAME_FIELD_NUMBER; - hash = (53 * hash) + getName().hashCode(); - hash = (37 * hash) + PROJECT_ID_FIELD_NUMBER; - hash = (53 * hash) + getProjectId().hashCode(); - hash = (37 * hash) + ID_FIELD_NUMBER; - hash = (53 * hash) + getId().hashCode(); - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.RetryBuildRequest parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.RetryBuildRequest parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.RetryBuildRequest parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.RetryBuildRequest parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.RetryBuildRequest parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.RetryBuildRequest parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.RetryBuildRequest parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.RetryBuildRequest parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.RetryBuildRequest parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.RetryBuildRequest parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.RetryBuildRequest parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.RetryBuildRequest parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.RetryBuildRequest prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * Specifies a build to retry.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.RetryBuildRequest} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.RetryBuildRequest) - com.google.cloudbuild.v1.RetryBuildRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_RetryBuildRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_RetryBuildRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.RetryBuildRequest.class, - com.google.cloudbuild.v1.RetryBuildRequest.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.RetryBuildRequest.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - name_ = ""; - - projectId_ = ""; - - id_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_RetryBuildRequest_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.RetryBuildRequest getDefaultInstanceForType() { - return com.google.cloudbuild.v1.RetryBuildRequest.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.RetryBuildRequest build() { - com.google.cloudbuild.v1.RetryBuildRequest result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.RetryBuildRequest buildPartial() { - com.google.cloudbuild.v1.RetryBuildRequest result = - new com.google.cloudbuild.v1.RetryBuildRequest(this); - result.name_ = name_; - result.projectId_ = projectId_; - result.id_ = id_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.RetryBuildRequest) { - return mergeFrom((com.google.cloudbuild.v1.RetryBuildRequest) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.RetryBuildRequest other) { - if (other == com.google.cloudbuild.v1.RetryBuildRequest.getDefaultInstance()) return this; - if (!other.getName().isEmpty()) { - name_ = other.name_; - onChanged(); - } - if (!other.getProjectId().isEmpty()) { - projectId_ = other.projectId_; - onChanged(); - } - if (!other.getId().isEmpty()) { - id_ = other.id_; - onChanged(); - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - projectId_ = input.readStringRequireUtf8(); - - break; - } // case 10 - case 18: - { - id_ = input.readStringRequireUtf8(); - - break; - } // case 18 - case 26: - { - name_ = input.readStringRequireUtf8(); - - break; - } // case 26 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private java.lang.Object name_ = ""; - /** - * - * - *
-     * The name of the `Build` to retry.
-     * Format: `projects/{project}/locations/{location}/builds/{build}`
-     * 
- * - * string name = 3 [(.google.api.resource_reference) = { ... } - * - * @return The name. - */ - public java.lang.String getName() { - java.lang.Object ref = name_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - name_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * The name of the `Build` to retry.
-     * Format: `projects/{project}/locations/{location}/builds/{build}`
-     * 
- * - * string name = 3 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for name. - */ - public com.google.protobuf.ByteString getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * The name of the `Build` to retry.
-     * Format: `projects/{project}/locations/{location}/builds/{build}`
-     * 
- * - * string name = 3 [(.google.api.resource_reference) = { ... } - * - * @param value The name to set. - * @return This builder for chaining. - */ - public Builder setName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - name_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the `Build` to retry.
-     * Format: `projects/{project}/locations/{location}/builds/{build}`
-     * 
- * - * string name = 3 [(.google.api.resource_reference) = { ... } - * - * @return This builder for chaining. - */ - public Builder clearName() { - - name_ = getDefaultInstance().getName(); - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the `Build` to retry.
-     * Format: `projects/{project}/locations/{location}/builds/{build}`
-     * 
- * - * string name = 3 [(.google.api.resource_reference) = { ... } - * - * @param value The bytes for name to set. - * @return This builder for chaining. - */ - public Builder setNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - name_ = value; - onChanged(); - return this; - } - - private java.lang.Object projectId_ = ""; - /** - * - * - *
-     * Required. ID of the project.
-     * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The projectId. - */ - public java.lang.String getProjectId() { - java.lang.Object ref = projectId_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - projectId_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Required. ID of the project.
-     * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for projectId. - */ - public com.google.protobuf.ByteString getProjectIdBytes() { - java.lang.Object ref = projectId_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - projectId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Required. ID of the project.
-     * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @param value The projectId to set. - * @return This builder for chaining. - */ - public Builder setProjectId(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - projectId_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Required. ID of the project.
-     * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return This builder for chaining. - */ - public Builder clearProjectId() { - - projectId_ = getDefaultInstance().getProjectId(); - onChanged(); - return this; - } - /** - * - * - *
-     * Required. ID of the project.
-     * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @param value The bytes for projectId to set. - * @return This builder for chaining. - */ - public Builder setProjectIdBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - projectId_ = value; - onChanged(); - return this; - } - - private java.lang.Object id_ = ""; - /** - * - * - *
-     * Required. Build ID of the original build.
-     * 
- * - * string id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The id. - */ - public java.lang.String getId() { - java.lang.Object ref = id_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - id_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Required. Build ID of the original build.
-     * 
- * - * string id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for id. - */ - public com.google.protobuf.ByteString getIdBytes() { - java.lang.Object ref = id_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - id_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Required. Build ID of the original build.
-     * 
- * - * string id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @param value The id to set. - * @return This builder for chaining. - */ - public Builder setId(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - id_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Required. Build ID of the original build.
-     * 
- * - * string id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @return This builder for chaining. - */ - public Builder clearId() { - - id_ = getDefaultInstance().getId(); - onChanged(); - return this; - } - /** - * - * - *
-     * Required. Build ID of the original build.
-     * 
- * - * string id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @param value The bytes for id to set. - * @return This builder for chaining. - */ - public Builder setIdBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - id_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.RetryBuildRequest) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.RetryBuildRequest) - private static final com.google.cloudbuild.v1.RetryBuildRequest DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.RetryBuildRequest(); - } - - public static com.google.cloudbuild.v1.RetryBuildRequest getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public RetryBuildRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.RetryBuildRequest getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/RetryBuildRequestOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/RetryBuildRequestOrBuilder.java deleted file mode 100644 index eec1e94b..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/RetryBuildRequestOrBuilder.java +++ /dev/null @@ -1,102 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface RetryBuildRequestOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.RetryBuildRequest) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The name of the `Build` to retry.
-   * Format: `projects/{project}/locations/{location}/builds/{build}`
-   * 
- * - * string name = 3 [(.google.api.resource_reference) = { ... } - * - * @return The name. - */ - java.lang.String getName(); - /** - * - * - *
-   * The name of the `Build` to retry.
-   * Format: `projects/{project}/locations/{location}/builds/{build}`
-   * 
- * - * string name = 3 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for name. - */ - com.google.protobuf.ByteString getNameBytes(); - - /** - * - * - *
-   * Required. ID of the project.
-   * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The projectId. - */ - java.lang.String getProjectId(); - /** - * - * - *
-   * Required. ID of the project.
-   * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for projectId. - */ - com.google.protobuf.ByteString getProjectIdBytes(); - - /** - * - * - *
-   * Required. Build ID of the original build.
-   * 
- * - * string id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The id. - */ - java.lang.String getId(); - /** - * - * - *
-   * Required. Build ID of the original build.
-   * 
- * - * string id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for id. - */ - com.google.protobuf.ByteString getIdBytes(); -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/RunBuildTriggerRequest.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/RunBuildTriggerRequest.java deleted file mode 100644 index 2d80a3f1..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/RunBuildTriggerRequest.java +++ /dev/null @@ -1,1239 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * Specifies a build trigger to run and the source to use.
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.RunBuildTriggerRequest} - */ -public final class RunBuildTriggerRequest extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.RunBuildTriggerRequest) - RunBuildTriggerRequestOrBuilder { - private static final long serialVersionUID = 0L; - // Use RunBuildTriggerRequest.newBuilder() to construct. - private RunBuildTriggerRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private RunBuildTriggerRequest() { - name_ = ""; - projectId_ = ""; - triggerId_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new RunBuildTriggerRequest(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_RunBuildTriggerRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_RunBuildTriggerRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.RunBuildTriggerRequest.class, - com.google.cloudbuild.v1.RunBuildTriggerRequest.Builder.class); - } - - public static final int NAME_FIELD_NUMBER = 4; - private volatile java.lang.Object name_; - /** - * - * - *
-   * The name of the `Trigger` to run.
-   * Format: `projects/{project}/locations/{location}/triggers/{trigger}`
-   * 
- * - * string name = 4 [(.google.api.resource_reference) = { ... } - * - * @return The name. - */ - @java.lang.Override - public java.lang.String getName() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - name_ = s; - return s; - } - } - /** - * - * - *
-   * The name of the `Trigger` to run.
-   * Format: `projects/{project}/locations/{location}/triggers/{trigger}`
-   * 
- * - * string name = 4 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for name. - */ - @java.lang.Override - public com.google.protobuf.ByteString getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int PROJECT_ID_FIELD_NUMBER = 1; - private volatile java.lang.Object projectId_; - /** - * - * - *
-   * Required. ID of the project.
-   * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The projectId. - */ - @java.lang.Override - public java.lang.String getProjectId() { - java.lang.Object ref = projectId_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - projectId_ = s; - return s; - } - } - /** - * - * - *
-   * Required. ID of the project.
-   * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for projectId. - */ - @java.lang.Override - public com.google.protobuf.ByteString getProjectIdBytes() { - java.lang.Object ref = projectId_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - projectId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int TRIGGER_ID_FIELD_NUMBER = 2; - private volatile java.lang.Object triggerId_; - /** - * - * - *
-   * Required. ID of the trigger.
-   * 
- * - * string trigger_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The triggerId. - */ - @java.lang.Override - public java.lang.String getTriggerId() { - java.lang.Object ref = triggerId_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - triggerId_ = s; - return s; - } - } - /** - * - * - *
-   * Required. ID of the trigger.
-   * 
- * - * string trigger_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for triggerId. - */ - @java.lang.Override - public com.google.protobuf.ByteString getTriggerIdBytes() { - java.lang.Object ref = triggerId_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - triggerId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int SOURCE_FIELD_NUMBER = 3; - private com.google.cloudbuild.v1.RepoSource source_; - /** - * - * - *
-   * Source to build against this trigger.
-   * 
- * - * .google.devtools.cloudbuild.v1.RepoSource source = 3; - * - * @return Whether the source field is set. - */ - @java.lang.Override - public boolean hasSource() { - return source_ != null; - } - /** - * - * - *
-   * Source to build against this trigger.
-   * 
- * - * .google.devtools.cloudbuild.v1.RepoSource source = 3; - * - * @return The source. - */ - @java.lang.Override - public com.google.cloudbuild.v1.RepoSource getSource() { - return source_ == null ? com.google.cloudbuild.v1.RepoSource.getDefaultInstance() : source_; - } - /** - * - * - *
-   * Source to build against this trigger.
-   * 
- * - * .google.devtools.cloudbuild.v1.RepoSource source = 3; - */ - @java.lang.Override - public com.google.cloudbuild.v1.RepoSourceOrBuilder getSourceOrBuilder() { - return getSource(); - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(projectId_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, projectId_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(triggerId_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, triggerId_); - } - if (source_ != null) { - output.writeMessage(3, getSource()); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 4, name_); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(projectId_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, projectId_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(triggerId_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, triggerId_); - } - if (source_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getSource()); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(4, name_); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.RunBuildTriggerRequest)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.RunBuildTriggerRequest other = - (com.google.cloudbuild.v1.RunBuildTriggerRequest) obj; - - if (!getName().equals(other.getName())) return false; - if (!getProjectId().equals(other.getProjectId())) return false; - if (!getTriggerId().equals(other.getTriggerId())) return false; - if (hasSource() != other.hasSource()) return false; - if (hasSource()) { - if (!getSource().equals(other.getSource())) return false; - } - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + NAME_FIELD_NUMBER; - hash = (53 * hash) + getName().hashCode(); - hash = (37 * hash) + PROJECT_ID_FIELD_NUMBER; - hash = (53 * hash) + getProjectId().hashCode(); - hash = (37 * hash) + TRIGGER_ID_FIELD_NUMBER; - hash = (53 * hash) + getTriggerId().hashCode(); - if (hasSource()) { - hash = (37 * hash) + SOURCE_FIELD_NUMBER; - hash = (53 * hash) + getSource().hashCode(); - } - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.RunBuildTriggerRequest parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.RunBuildTriggerRequest parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.RunBuildTriggerRequest parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.RunBuildTriggerRequest parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.RunBuildTriggerRequest parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.RunBuildTriggerRequest parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.RunBuildTriggerRequest parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.RunBuildTriggerRequest parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.RunBuildTriggerRequest parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.RunBuildTriggerRequest parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.RunBuildTriggerRequest parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.RunBuildTriggerRequest parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.RunBuildTriggerRequest prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * Specifies a build trigger to run and the source to use.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.RunBuildTriggerRequest} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.RunBuildTriggerRequest) - com.google.cloudbuild.v1.RunBuildTriggerRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_RunBuildTriggerRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_RunBuildTriggerRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.RunBuildTriggerRequest.class, - com.google.cloudbuild.v1.RunBuildTriggerRequest.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.RunBuildTriggerRequest.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - name_ = ""; - - projectId_ = ""; - - triggerId_ = ""; - - if (sourceBuilder_ == null) { - source_ = null; - } else { - source_ = null; - sourceBuilder_ = null; - } - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_RunBuildTriggerRequest_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.RunBuildTriggerRequest getDefaultInstanceForType() { - return com.google.cloudbuild.v1.RunBuildTriggerRequest.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.RunBuildTriggerRequest build() { - com.google.cloudbuild.v1.RunBuildTriggerRequest result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.RunBuildTriggerRequest buildPartial() { - com.google.cloudbuild.v1.RunBuildTriggerRequest result = - new com.google.cloudbuild.v1.RunBuildTriggerRequest(this); - result.name_ = name_; - result.projectId_ = projectId_; - result.triggerId_ = triggerId_; - if (sourceBuilder_ == null) { - result.source_ = source_; - } else { - result.source_ = sourceBuilder_.build(); - } - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.RunBuildTriggerRequest) { - return mergeFrom((com.google.cloudbuild.v1.RunBuildTriggerRequest) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.RunBuildTriggerRequest other) { - if (other == com.google.cloudbuild.v1.RunBuildTriggerRequest.getDefaultInstance()) - return this; - if (!other.getName().isEmpty()) { - name_ = other.name_; - onChanged(); - } - if (!other.getProjectId().isEmpty()) { - projectId_ = other.projectId_; - onChanged(); - } - if (!other.getTriggerId().isEmpty()) { - triggerId_ = other.triggerId_; - onChanged(); - } - if (other.hasSource()) { - mergeSource(other.getSource()); - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - projectId_ = input.readStringRequireUtf8(); - - break; - } // case 10 - case 18: - { - triggerId_ = input.readStringRequireUtf8(); - - break; - } // case 18 - case 26: - { - input.readMessage(getSourceFieldBuilder().getBuilder(), extensionRegistry); - - break; - } // case 26 - case 34: - { - name_ = input.readStringRequireUtf8(); - - break; - } // case 34 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private java.lang.Object name_ = ""; - /** - * - * - *
-     * The name of the `Trigger` to run.
-     * Format: `projects/{project}/locations/{location}/triggers/{trigger}`
-     * 
- * - * string name = 4 [(.google.api.resource_reference) = { ... } - * - * @return The name. - */ - public java.lang.String getName() { - java.lang.Object ref = name_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - name_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * The name of the `Trigger` to run.
-     * Format: `projects/{project}/locations/{location}/triggers/{trigger}`
-     * 
- * - * string name = 4 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for name. - */ - public com.google.protobuf.ByteString getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * The name of the `Trigger` to run.
-     * Format: `projects/{project}/locations/{location}/triggers/{trigger}`
-     * 
- * - * string name = 4 [(.google.api.resource_reference) = { ... } - * - * @param value The name to set. - * @return This builder for chaining. - */ - public Builder setName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - name_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the `Trigger` to run.
-     * Format: `projects/{project}/locations/{location}/triggers/{trigger}`
-     * 
- * - * string name = 4 [(.google.api.resource_reference) = { ... } - * - * @return This builder for chaining. - */ - public Builder clearName() { - - name_ = getDefaultInstance().getName(); - onChanged(); - return this; - } - /** - * - * - *
-     * The name of the `Trigger` to run.
-     * Format: `projects/{project}/locations/{location}/triggers/{trigger}`
-     * 
- * - * string name = 4 [(.google.api.resource_reference) = { ... } - * - * @param value The bytes for name to set. - * @return This builder for chaining. - */ - public Builder setNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - name_ = value; - onChanged(); - return this; - } - - private java.lang.Object projectId_ = ""; - /** - * - * - *
-     * Required. ID of the project.
-     * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The projectId. - */ - public java.lang.String getProjectId() { - java.lang.Object ref = projectId_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - projectId_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Required. ID of the project.
-     * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for projectId. - */ - public com.google.protobuf.ByteString getProjectIdBytes() { - java.lang.Object ref = projectId_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - projectId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Required. ID of the project.
-     * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @param value The projectId to set. - * @return This builder for chaining. - */ - public Builder setProjectId(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - projectId_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Required. ID of the project.
-     * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return This builder for chaining. - */ - public Builder clearProjectId() { - - projectId_ = getDefaultInstance().getProjectId(); - onChanged(); - return this; - } - /** - * - * - *
-     * Required. ID of the project.
-     * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @param value The bytes for projectId to set. - * @return This builder for chaining. - */ - public Builder setProjectIdBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - projectId_ = value; - onChanged(); - return this; - } - - private java.lang.Object triggerId_ = ""; - /** - * - * - *
-     * Required. ID of the trigger.
-     * 
- * - * string trigger_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The triggerId. - */ - public java.lang.String getTriggerId() { - java.lang.Object ref = triggerId_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - triggerId_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Required. ID of the trigger.
-     * 
- * - * string trigger_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for triggerId. - */ - public com.google.protobuf.ByteString getTriggerIdBytes() { - java.lang.Object ref = triggerId_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - triggerId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Required. ID of the trigger.
-     * 
- * - * string trigger_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @param value The triggerId to set. - * @return This builder for chaining. - */ - public Builder setTriggerId(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - triggerId_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Required. ID of the trigger.
-     * 
- * - * string trigger_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @return This builder for chaining. - */ - public Builder clearTriggerId() { - - triggerId_ = getDefaultInstance().getTriggerId(); - onChanged(); - return this; - } - /** - * - * - *
-     * Required. ID of the trigger.
-     * 
- * - * string trigger_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @param value The bytes for triggerId to set. - * @return This builder for chaining. - */ - public Builder setTriggerIdBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - triggerId_ = value; - onChanged(); - return this; - } - - private com.google.cloudbuild.v1.RepoSource source_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.RepoSource, - com.google.cloudbuild.v1.RepoSource.Builder, - com.google.cloudbuild.v1.RepoSourceOrBuilder> - sourceBuilder_; - /** - * - * - *
-     * Source to build against this trigger.
-     * 
- * - * .google.devtools.cloudbuild.v1.RepoSource source = 3; - * - * @return Whether the source field is set. - */ - public boolean hasSource() { - return sourceBuilder_ != null || source_ != null; - } - /** - * - * - *
-     * Source to build against this trigger.
-     * 
- * - * .google.devtools.cloudbuild.v1.RepoSource source = 3; - * - * @return The source. - */ - public com.google.cloudbuild.v1.RepoSource getSource() { - if (sourceBuilder_ == null) { - return source_ == null ? com.google.cloudbuild.v1.RepoSource.getDefaultInstance() : source_; - } else { - return sourceBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Source to build against this trigger.
-     * 
- * - * .google.devtools.cloudbuild.v1.RepoSource source = 3; - */ - public Builder setSource(com.google.cloudbuild.v1.RepoSource value) { - if (sourceBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - source_ = value; - onChanged(); - } else { - sourceBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * Source to build against this trigger.
-     * 
- * - * .google.devtools.cloudbuild.v1.RepoSource source = 3; - */ - public Builder setSource(com.google.cloudbuild.v1.RepoSource.Builder builderForValue) { - if (sourceBuilder_ == null) { - source_ = builderForValue.build(); - onChanged(); - } else { - sourceBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Source to build against this trigger.
-     * 
- * - * .google.devtools.cloudbuild.v1.RepoSource source = 3; - */ - public Builder mergeSource(com.google.cloudbuild.v1.RepoSource value) { - if (sourceBuilder_ == null) { - if (source_ != null) { - source_ = - com.google.cloudbuild.v1.RepoSource.newBuilder(source_) - .mergeFrom(value) - .buildPartial(); - } else { - source_ = value; - } - onChanged(); - } else { - sourceBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * Source to build against this trigger.
-     * 
- * - * .google.devtools.cloudbuild.v1.RepoSource source = 3; - */ - public Builder clearSource() { - if (sourceBuilder_ == null) { - source_ = null; - onChanged(); - } else { - source_ = null; - sourceBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Source to build against this trigger.
-     * 
- * - * .google.devtools.cloudbuild.v1.RepoSource source = 3; - */ - public com.google.cloudbuild.v1.RepoSource.Builder getSourceBuilder() { - - onChanged(); - return getSourceFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Source to build against this trigger.
-     * 
- * - * .google.devtools.cloudbuild.v1.RepoSource source = 3; - */ - public com.google.cloudbuild.v1.RepoSourceOrBuilder getSourceOrBuilder() { - if (sourceBuilder_ != null) { - return sourceBuilder_.getMessageOrBuilder(); - } else { - return source_ == null ? com.google.cloudbuild.v1.RepoSource.getDefaultInstance() : source_; - } - } - /** - * - * - *
-     * Source to build against this trigger.
-     * 
- * - * .google.devtools.cloudbuild.v1.RepoSource source = 3; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.RepoSource, - com.google.cloudbuild.v1.RepoSource.Builder, - com.google.cloudbuild.v1.RepoSourceOrBuilder> - getSourceFieldBuilder() { - if (sourceBuilder_ == null) { - sourceBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.RepoSource, - com.google.cloudbuild.v1.RepoSource.Builder, - com.google.cloudbuild.v1.RepoSourceOrBuilder>( - getSource(), getParentForChildren(), isClean()); - source_ = null; - } - return sourceBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.RunBuildTriggerRequest) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.RunBuildTriggerRequest) - private static final com.google.cloudbuild.v1.RunBuildTriggerRequest DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.RunBuildTriggerRequest(); - } - - public static com.google.cloudbuild.v1.RunBuildTriggerRequest getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public RunBuildTriggerRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.RunBuildTriggerRequest getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/RunBuildTriggerRequestOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/RunBuildTriggerRequestOrBuilder.java deleted file mode 100644 index 23ab037c..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/RunBuildTriggerRequestOrBuilder.java +++ /dev/null @@ -1,137 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface RunBuildTriggerRequestOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.RunBuildTriggerRequest) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The name of the `Trigger` to run.
-   * Format: `projects/{project}/locations/{location}/triggers/{trigger}`
-   * 
- * - * string name = 4 [(.google.api.resource_reference) = { ... } - * - * @return The name. - */ - java.lang.String getName(); - /** - * - * - *
-   * The name of the `Trigger` to run.
-   * Format: `projects/{project}/locations/{location}/triggers/{trigger}`
-   * 
- * - * string name = 4 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for name. - */ - com.google.protobuf.ByteString getNameBytes(); - - /** - * - * - *
-   * Required. ID of the project.
-   * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The projectId. - */ - java.lang.String getProjectId(); - /** - * - * - *
-   * Required. ID of the project.
-   * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for projectId. - */ - com.google.protobuf.ByteString getProjectIdBytes(); - - /** - * - * - *
-   * Required. ID of the trigger.
-   * 
- * - * string trigger_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The triggerId. - */ - java.lang.String getTriggerId(); - /** - * - * - *
-   * Required. ID of the trigger.
-   * 
- * - * string trigger_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for triggerId. - */ - com.google.protobuf.ByteString getTriggerIdBytes(); - - /** - * - * - *
-   * Source to build against this trigger.
-   * 
- * - * .google.devtools.cloudbuild.v1.RepoSource source = 3; - * - * @return Whether the source field is set. - */ - boolean hasSource(); - /** - * - * - *
-   * Source to build against this trigger.
-   * 
- * - * .google.devtools.cloudbuild.v1.RepoSource source = 3; - * - * @return The source. - */ - com.google.cloudbuild.v1.RepoSource getSource(); - /** - * - * - *
-   * Source to build against this trigger.
-   * 
- * - * .google.devtools.cloudbuild.v1.RepoSource source = 3; - */ - com.google.cloudbuild.v1.RepoSourceOrBuilder getSourceOrBuilder(); -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Secret.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Secret.java deleted file mode 100644 index eb3e7bc0..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Secret.java +++ /dev/null @@ -1,996 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * Pairs a set of secret environment variables containing encrypted
- * values with the Cloud KMS key to use to decrypt the value.
- * Note: Use `kmsKeyName` with  `available_secrets` instead of using
- * `kmsKeyName` with `secret`. For instructions see:
- * https://cloud.google.com/cloud-build/docs/securing-builds/use-encrypted-credentials.
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.Secret} - */ -public final class Secret extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.Secret) - SecretOrBuilder { - private static final long serialVersionUID = 0L; - // Use Secret.newBuilder() to construct. - private Secret(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private Secret() { - kmsKeyName_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new Secret(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Secret_descriptor; - } - - @SuppressWarnings({"rawtypes"}) - @java.lang.Override - protected com.google.protobuf.MapField internalGetMapField(int number) { - switch (number) { - case 3: - return internalGetSecretEnv(); - default: - throw new RuntimeException("Invalid map field number: " + number); - } - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Secret_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.Secret.class, com.google.cloudbuild.v1.Secret.Builder.class); - } - - public static final int KMS_KEY_NAME_FIELD_NUMBER = 1; - private volatile java.lang.Object kmsKeyName_; - /** - * - * - *
-   * Cloud KMS key name to use to decrypt these envs.
-   * 
- * - * string kms_key_name = 1; - * - * @return The kmsKeyName. - */ - @java.lang.Override - public java.lang.String getKmsKeyName() { - java.lang.Object ref = kmsKeyName_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - kmsKeyName_ = s; - return s; - } - } - /** - * - * - *
-   * Cloud KMS key name to use to decrypt these envs.
-   * 
- * - * string kms_key_name = 1; - * - * @return The bytes for kmsKeyName. - */ - @java.lang.Override - public com.google.protobuf.ByteString getKmsKeyNameBytes() { - java.lang.Object ref = kmsKeyName_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - kmsKeyName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int SECRET_ENV_FIELD_NUMBER = 3; - - private static final class SecretEnvDefaultEntryHolder { - static final com.google.protobuf.MapEntry - defaultEntry = - com.google.protobuf.MapEntry - .newDefaultInstance( - com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Secret_SecretEnvEntry_descriptor, - com.google.protobuf.WireFormat.FieldType.STRING, - "", - com.google.protobuf.WireFormat.FieldType.BYTES, - com.google.protobuf.ByteString.EMPTY); - } - - private com.google.protobuf.MapField secretEnv_; - - private com.google.protobuf.MapField - internalGetSecretEnv() { - if (secretEnv_ == null) { - return com.google.protobuf.MapField.emptyMapField(SecretEnvDefaultEntryHolder.defaultEntry); - } - return secretEnv_; - } - - public int getSecretEnvCount() { - return internalGetSecretEnv().getMap().size(); - } - /** - * - * - *
-   * Map of environment variable name to its encrypted value.
-   * Secret environment variables must be unique across all of a build's
-   * secrets, and must be used by at least one build step. Values can be at most
-   * 64 KB in size. There can be at most 100 secret values across all of a
-   * build's secrets.
-   * 
- * - * map<string, bytes> secret_env = 3; - */ - @java.lang.Override - public boolean containsSecretEnv(java.lang.String key) { - if (key == null) { - throw new NullPointerException("map key"); - } - return internalGetSecretEnv().getMap().containsKey(key); - } - /** Use {@link #getSecretEnvMap()} instead. */ - @java.lang.Override - @java.lang.Deprecated - public java.util.Map getSecretEnv() { - return getSecretEnvMap(); - } - /** - * - * - *
-   * Map of environment variable name to its encrypted value.
-   * Secret environment variables must be unique across all of a build's
-   * secrets, and must be used by at least one build step. Values can be at most
-   * 64 KB in size. There can be at most 100 secret values across all of a
-   * build's secrets.
-   * 
- * - * map<string, bytes> secret_env = 3; - */ - @java.lang.Override - public java.util.Map getSecretEnvMap() { - return internalGetSecretEnv().getMap(); - } - /** - * - * - *
-   * Map of environment variable name to its encrypted value.
-   * Secret environment variables must be unique across all of a build's
-   * secrets, and must be used by at least one build step. Values can be at most
-   * 64 KB in size. There can be at most 100 secret values across all of a
-   * build's secrets.
-   * 
- * - * map<string, bytes> secret_env = 3; - */ - @java.lang.Override - public com.google.protobuf.ByteString getSecretEnvOrDefault( - java.lang.String key, com.google.protobuf.ByteString defaultValue) { - if (key == null) { - throw new NullPointerException("map key"); - } - java.util.Map map = - internalGetSecretEnv().getMap(); - return map.containsKey(key) ? map.get(key) : defaultValue; - } - /** - * - * - *
-   * Map of environment variable name to its encrypted value.
-   * Secret environment variables must be unique across all of a build's
-   * secrets, and must be used by at least one build step. Values can be at most
-   * 64 KB in size. There can be at most 100 secret values across all of a
-   * build's secrets.
-   * 
- * - * map<string, bytes> secret_env = 3; - */ - @java.lang.Override - public com.google.protobuf.ByteString getSecretEnvOrThrow(java.lang.String key) { - if (key == null) { - throw new NullPointerException("map key"); - } - java.util.Map map = - internalGetSecretEnv().getMap(); - if (!map.containsKey(key)) { - throw new java.lang.IllegalArgumentException(); - } - return map.get(key); - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(kmsKeyName_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, kmsKeyName_); - } - com.google.protobuf.GeneratedMessageV3.serializeStringMapTo( - output, internalGetSecretEnv(), SecretEnvDefaultEntryHolder.defaultEntry, 3); - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(kmsKeyName_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, kmsKeyName_); - } - for (java.util.Map.Entry entry : - internalGetSecretEnv().getMap().entrySet()) { - com.google.protobuf.MapEntry secretEnv__ = - SecretEnvDefaultEntryHolder.defaultEntry - .newBuilderForType() - .setKey(entry.getKey()) - .setValue(entry.getValue()) - .build(); - size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, secretEnv__); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.Secret)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.Secret other = (com.google.cloudbuild.v1.Secret) obj; - - if (!getKmsKeyName().equals(other.getKmsKeyName())) return false; - if (!internalGetSecretEnv().equals(other.internalGetSecretEnv())) return false; - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + KMS_KEY_NAME_FIELD_NUMBER; - hash = (53 * hash) + getKmsKeyName().hashCode(); - if (!internalGetSecretEnv().getMap().isEmpty()) { - hash = (37 * hash) + SECRET_ENV_FIELD_NUMBER; - hash = (53 * hash) + internalGetSecretEnv().hashCode(); - } - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.Secret parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.Secret parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.Secret parseFrom(com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.Secret parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.Secret parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.Secret parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.Secret parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.Secret parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.Secret parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.Secret parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.Secret parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.Secret parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.Secret prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * Pairs a set of secret environment variables containing encrypted
-   * values with the Cloud KMS key to use to decrypt the value.
-   * Note: Use `kmsKeyName` with  `available_secrets` instead of using
-   * `kmsKeyName` with `secret`. For instructions see:
-   * https://cloud.google.com/cloud-build/docs/securing-builds/use-encrypted-credentials.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.Secret} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.Secret) - com.google.cloudbuild.v1.SecretOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Secret_descriptor; - } - - @SuppressWarnings({"rawtypes"}) - protected com.google.protobuf.MapField internalGetMapField(int number) { - switch (number) { - case 3: - return internalGetSecretEnv(); - default: - throw new RuntimeException("Invalid map field number: " + number); - } - } - - @SuppressWarnings({"rawtypes"}) - protected com.google.protobuf.MapField internalGetMutableMapField(int number) { - switch (number) { - case 3: - return internalGetMutableSecretEnv(); - default: - throw new RuntimeException("Invalid map field number: " + number); - } - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Secret_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.Secret.class, com.google.cloudbuild.v1.Secret.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.Secret.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - kmsKeyName_ = ""; - - internalGetMutableSecretEnv().clear(); - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Secret_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.Secret getDefaultInstanceForType() { - return com.google.cloudbuild.v1.Secret.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.Secret build() { - com.google.cloudbuild.v1.Secret result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.Secret buildPartial() { - com.google.cloudbuild.v1.Secret result = new com.google.cloudbuild.v1.Secret(this); - int from_bitField0_ = bitField0_; - result.kmsKeyName_ = kmsKeyName_; - result.secretEnv_ = internalGetSecretEnv(); - result.secretEnv_.makeImmutable(); - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.Secret) { - return mergeFrom((com.google.cloudbuild.v1.Secret) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.Secret other) { - if (other == com.google.cloudbuild.v1.Secret.getDefaultInstance()) return this; - if (!other.getKmsKeyName().isEmpty()) { - kmsKeyName_ = other.kmsKeyName_; - onChanged(); - } - internalGetMutableSecretEnv().mergeFrom(other.internalGetSecretEnv()); - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - kmsKeyName_ = input.readStringRequireUtf8(); - - break; - } // case 10 - case 26: - { - com.google.protobuf.MapEntry - secretEnv__ = - input.readMessage( - SecretEnvDefaultEntryHolder.defaultEntry.getParserForType(), - extensionRegistry); - internalGetMutableSecretEnv() - .getMutableMap() - .put(secretEnv__.getKey(), secretEnv__.getValue()); - break; - } // case 26 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private int bitField0_; - - private java.lang.Object kmsKeyName_ = ""; - /** - * - * - *
-     * Cloud KMS key name to use to decrypt these envs.
-     * 
- * - * string kms_key_name = 1; - * - * @return The kmsKeyName. - */ - public java.lang.String getKmsKeyName() { - java.lang.Object ref = kmsKeyName_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - kmsKeyName_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Cloud KMS key name to use to decrypt these envs.
-     * 
- * - * string kms_key_name = 1; - * - * @return The bytes for kmsKeyName. - */ - public com.google.protobuf.ByteString getKmsKeyNameBytes() { - java.lang.Object ref = kmsKeyName_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - kmsKeyName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Cloud KMS key name to use to decrypt these envs.
-     * 
- * - * string kms_key_name = 1; - * - * @param value The kmsKeyName to set. - * @return This builder for chaining. - */ - public Builder setKmsKeyName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - kmsKeyName_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Cloud KMS key name to use to decrypt these envs.
-     * 
- * - * string kms_key_name = 1; - * - * @return This builder for chaining. - */ - public Builder clearKmsKeyName() { - - kmsKeyName_ = getDefaultInstance().getKmsKeyName(); - onChanged(); - return this; - } - /** - * - * - *
-     * Cloud KMS key name to use to decrypt these envs.
-     * 
- * - * string kms_key_name = 1; - * - * @param value The bytes for kmsKeyName to set. - * @return This builder for chaining. - */ - public Builder setKmsKeyNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - kmsKeyName_ = value; - onChanged(); - return this; - } - - private com.google.protobuf.MapField - secretEnv_; - - private com.google.protobuf.MapField - internalGetSecretEnv() { - if (secretEnv_ == null) { - return com.google.protobuf.MapField.emptyMapField(SecretEnvDefaultEntryHolder.defaultEntry); - } - return secretEnv_; - } - - private com.google.protobuf.MapField - internalGetMutableSecretEnv() { - onChanged(); - ; - if (secretEnv_ == null) { - secretEnv_ = - com.google.protobuf.MapField.newMapField(SecretEnvDefaultEntryHolder.defaultEntry); - } - if (!secretEnv_.isMutable()) { - secretEnv_ = secretEnv_.copy(); - } - return secretEnv_; - } - - public int getSecretEnvCount() { - return internalGetSecretEnv().getMap().size(); - } - /** - * - * - *
-     * Map of environment variable name to its encrypted value.
-     * Secret environment variables must be unique across all of a build's
-     * secrets, and must be used by at least one build step. Values can be at most
-     * 64 KB in size. There can be at most 100 secret values across all of a
-     * build's secrets.
-     * 
- * - * map<string, bytes> secret_env = 3; - */ - @java.lang.Override - public boolean containsSecretEnv(java.lang.String key) { - if (key == null) { - throw new NullPointerException("map key"); - } - return internalGetSecretEnv().getMap().containsKey(key); - } - /** Use {@link #getSecretEnvMap()} instead. */ - @java.lang.Override - @java.lang.Deprecated - public java.util.Map getSecretEnv() { - return getSecretEnvMap(); - } - /** - * - * - *
-     * Map of environment variable name to its encrypted value.
-     * Secret environment variables must be unique across all of a build's
-     * secrets, and must be used by at least one build step. Values can be at most
-     * 64 KB in size. There can be at most 100 secret values across all of a
-     * build's secrets.
-     * 
- * - * map<string, bytes> secret_env = 3; - */ - @java.lang.Override - public java.util.Map getSecretEnvMap() { - return internalGetSecretEnv().getMap(); - } - /** - * - * - *
-     * Map of environment variable name to its encrypted value.
-     * Secret environment variables must be unique across all of a build's
-     * secrets, and must be used by at least one build step. Values can be at most
-     * 64 KB in size. There can be at most 100 secret values across all of a
-     * build's secrets.
-     * 
- * - * map<string, bytes> secret_env = 3; - */ - @java.lang.Override - public com.google.protobuf.ByteString getSecretEnvOrDefault( - java.lang.String key, com.google.protobuf.ByteString defaultValue) { - if (key == null) { - throw new NullPointerException("map key"); - } - java.util.Map map = - internalGetSecretEnv().getMap(); - return map.containsKey(key) ? map.get(key) : defaultValue; - } - /** - * - * - *
-     * Map of environment variable name to its encrypted value.
-     * Secret environment variables must be unique across all of a build's
-     * secrets, and must be used by at least one build step. Values can be at most
-     * 64 KB in size. There can be at most 100 secret values across all of a
-     * build's secrets.
-     * 
- * - * map<string, bytes> secret_env = 3; - */ - @java.lang.Override - public com.google.protobuf.ByteString getSecretEnvOrThrow(java.lang.String key) { - if (key == null) { - throw new NullPointerException("map key"); - } - java.util.Map map = - internalGetSecretEnv().getMap(); - if (!map.containsKey(key)) { - throw new java.lang.IllegalArgumentException(); - } - return map.get(key); - } - - public Builder clearSecretEnv() { - internalGetMutableSecretEnv().getMutableMap().clear(); - return this; - } - /** - * - * - *
-     * Map of environment variable name to its encrypted value.
-     * Secret environment variables must be unique across all of a build's
-     * secrets, and must be used by at least one build step. Values can be at most
-     * 64 KB in size. There can be at most 100 secret values across all of a
-     * build's secrets.
-     * 
- * - * map<string, bytes> secret_env = 3; - */ - public Builder removeSecretEnv(java.lang.String key) { - if (key == null) { - throw new NullPointerException("map key"); - } - internalGetMutableSecretEnv().getMutableMap().remove(key); - return this; - } - /** Use alternate mutation accessors instead. */ - @java.lang.Deprecated - public java.util.Map getMutableSecretEnv() { - return internalGetMutableSecretEnv().getMutableMap(); - } - /** - * - * - *
-     * Map of environment variable name to its encrypted value.
-     * Secret environment variables must be unique across all of a build's
-     * secrets, and must be used by at least one build step. Values can be at most
-     * 64 KB in size. There can be at most 100 secret values across all of a
-     * build's secrets.
-     * 
- * - * map<string, bytes> secret_env = 3; - */ - public Builder putSecretEnv(java.lang.String key, com.google.protobuf.ByteString value) { - if (key == null) { - throw new NullPointerException("map key"); - } - if (value == null) { - throw new NullPointerException("map value"); - } - - internalGetMutableSecretEnv().getMutableMap().put(key, value); - return this; - } - /** - * - * - *
-     * Map of environment variable name to its encrypted value.
-     * Secret environment variables must be unique across all of a build's
-     * secrets, and must be used by at least one build step. Values can be at most
-     * 64 KB in size. There can be at most 100 secret values across all of a
-     * build's secrets.
-     * 
- * - * map<string, bytes> secret_env = 3; - */ - public Builder putAllSecretEnv( - java.util.Map values) { - internalGetMutableSecretEnv().getMutableMap().putAll(values); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.Secret) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.Secret) - private static final com.google.cloudbuild.v1.Secret DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.Secret(); - } - - public static com.google.cloudbuild.v1.Secret getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public Secret parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.Secret getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/SecretManagerSecret.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/SecretManagerSecret.java deleted file mode 100644 index c665fee4..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/SecretManagerSecret.java +++ /dev/null @@ -1,813 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * Pairs a secret environment variable with a SecretVersion in Secret Manager.
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.SecretManagerSecret} - */ -public final class SecretManagerSecret extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.SecretManagerSecret) - SecretManagerSecretOrBuilder { - private static final long serialVersionUID = 0L; - // Use SecretManagerSecret.newBuilder() to construct. - private SecretManagerSecret(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private SecretManagerSecret() { - versionName_ = ""; - env_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new SecretManagerSecret(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_SecretManagerSecret_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_SecretManagerSecret_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.SecretManagerSecret.class, - com.google.cloudbuild.v1.SecretManagerSecret.Builder.class); - } - - public static final int VERSION_NAME_FIELD_NUMBER = 1; - private volatile java.lang.Object versionName_; - /** - * - * - *
-   * Resource name of the SecretVersion. In format:
-   * projects/*/secrets/*/versions/*
-   * 
- * - * string version_name = 1 [(.google.api.resource_reference) = { ... } - * - * @return The versionName. - */ - @java.lang.Override - public java.lang.String getVersionName() { - java.lang.Object ref = versionName_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - versionName_ = s; - return s; - } - } - /** - * - * - *
-   * Resource name of the SecretVersion. In format:
-   * projects/*/secrets/*/versions/*
-   * 
- * - * string version_name = 1 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for versionName. - */ - @java.lang.Override - public com.google.protobuf.ByteString getVersionNameBytes() { - java.lang.Object ref = versionName_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - versionName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int ENV_FIELD_NUMBER = 2; - private volatile java.lang.Object env_; - /** - * - * - *
-   * Environment variable name to associate with the secret.
-   * Secret environment variables must be unique across all of a build's
-   * secrets, and must be used by at least one build step.
-   * 
- * - * string env = 2; - * - * @return The env. - */ - @java.lang.Override - public java.lang.String getEnv() { - java.lang.Object ref = env_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - env_ = s; - return s; - } - } - /** - * - * - *
-   * Environment variable name to associate with the secret.
-   * Secret environment variables must be unique across all of a build's
-   * secrets, and must be used by at least one build step.
-   * 
- * - * string env = 2; - * - * @return The bytes for env. - */ - @java.lang.Override - public com.google.protobuf.ByteString getEnvBytes() { - java.lang.Object ref = env_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - env_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(versionName_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, versionName_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(env_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, env_); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(versionName_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, versionName_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(env_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, env_); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.SecretManagerSecret)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.SecretManagerSecret other = - (com.google.cloudbuild.v1.SecretManagerSecret) obj; - - if (!getVersionName().equals(other.getVersionName())) return false; - if (!getEnv().equals(other.getEnv())) return false; - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + VERSION_NAME_FIELD_NUMBER; - hash = (53 * hash) + getVersionName().hashCode(); - hash = (37 * hash) + ENV_FIELD_NUMBER; - hash = (53 * hash) + getEnv().hashCode(); - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.SecretManagerSecret parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.SecretManagerSecret parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.SecretManagerSecret parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.SecretManagerSecret parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.SecretManagerSecret parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.SecretManagerSecret parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.SecretManagerSecret parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.SecretManagerSecret parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.SecretManagerSecret parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.SecretManagerSecret parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.SecretManagerSecret parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.SecretManagerSecret parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.SecretManagerSecret prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * Pairs a secret environment variable with a SecretVersion in Secret Manager.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.SecretManagerSecret} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.SecretManagerSecret) - com.google.cloudbuild.v1.SecretManagerSecretOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_SecretManagerSecret_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_SecretManagerSecret_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.SecretManagerSecret.class, - com.google.cloudbuild.v1.SecretManagerSecret.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.SecretManagerSecret.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - versionName_ = ""; - - env_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_SecretManagerSecret_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.SecretManagerSecret getDefaultInstanceForType() { - return com.google.cloudbuild.v1.SecretManagerSecret.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.SecretManagerSecret build() { - com.google.cloudbuild.v1.SecretManagerSecret result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.SecretManagerSecret buildPartial() { - com.google.cloudbuild.v1.SecretManagerSecret result = - new com.google.cloudbuild.v1.SecretManagerSecret(this); - result.versionName_ = versionName_; - result.env_ = env_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.SecretManagerSecret) { - return mergeFrom((com.google.cloudbuild.v1.SecretManagerSecret) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.SecretManagerSecret other) { - if (other == com.google.cloudbuild.v1.SecretManagerSecret.getDefaultInstance()) return this; - if (!other.getVersionName().isEmpty()) { - versionName_ = other.versionName_; - onChanged(); - } - if (!other.getEnv().isEmpty()) { - env_ = other.env_; - onChanged(); - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - versionName_ = input.readStringRequireUtf8(); - - break; - } // case 10 - case 18: - { - env_ = input.readStringRequireUtf8(); - - break; - } // case 18 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private java.lang.Object versionName_ = ""; - /** - * - * - *
-     * Resource name of the SecretVersion. In format:
-     * projects/*/secrets/*/versions/*
-     * 
- * - * string version_name = 1 [(.google.api.resource_reference) = { ... } - * - * @return The versionName. - */ - public java.lang.String getVersionName() { - java.lang.Object ref = versionName_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - versionName_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Resource name of the SecretVersion. In format:
-     * projects/*/secrets/*/versions/*
-     * 
- * - * string version_name = 1 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for versionName. - */ - public com.google.protobuf.ByteString getVersionNameBytes() { - java.lang.Object ref = versionName_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - versionName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Resource name of the SecretVersion. In format:
-     * projects/*/secrets/*/versions/*
-     * 
- * - * string version_name = 1 [(.google.api.resource_reference) = { ... } - * - * @param value The versionName to set. - * @return This builder for chaining. - */ - public Builder setVersionName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - versionName_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Resource name of the SecretVersion. In format:
-     * projects/*/secrets/*/versions/*
-     * 
- * - * string version_name = 1 [(.google.api.resource_reference) = { ... } - * - * @return This builder for chaining. - */ - public Builder clearVersionName() { - - versionName_ = getDefaultInstance().getVersionName(); - onChanged(); - return this; - } - /** - * - * - *
-     * Resource name of the SecretVersion. In format:
-     * projects/*/secrets/*/versions/*
-     * 
- * - * string version_name = 1 [(.google.api.resource_reference) = { ... } - * - * @param value The bytes for versionName to set. - * @return This builder for chaining. - */ - public Builder setVersionNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - versionName_ = value; - onChanged(); - return this; - } - - private java.lang.Object env_ = ""; - /** - * - * - *
-     * Environment variable name to associate with the secret.
-     * Secret environment variables must be unique across all of a build's
-     * secrets, and must be used by at least one build step.
-     * 
- * - * string env = 2; - * - * @return The env. - */ - public java.lang.String getEnv() { - java.lang.Object ref = env_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - env_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Environment variable name to associate with the secret.
-     * Secret environment variables must be unique across all of a build's
-     * secrets, and must be used by at least one build step.
-     * 
- * - * string env = 2; - * - * @return The bytes for env. - */ - public com.google.protobuf.ByteString getEnvBytes() { - java.lang.Object ref = env_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - env_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Environment variable name to associate with the secret.
-     * Secret environment variables must be unique across all of a build's
-     * secrets, and must be used by at least one build step.
-     * 
- * - * string env = 2; - * - * @param value The env to set. - * @return This builder for chaining. - */ - public Builder setEnv(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - env_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Environment variable name to associate with the secret.
-     * Secret environment variables must be unique across all of a build's
-     * secrets, and must be used by at least one build step.
-     * 
- * - * string env = 2; - * - * @return This builder for chaining. - */ - public Builder clearEnv() { - - env_ = getDefaultInstance().getEnv(); - onChanged(); - return this; - } - /** - * - * - *
-     * Environment variable name to associate with the secret.
-     * Secret environment variables must be unique across all of a build's
-     * secrets, and must be used by at least one build step.
-     * 
- * - * string env = 2; - * - * @param value The bytes for env to set. - * @return This builder for chaining. - */ - public Builder setEnvBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - env_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.SecretManagerSecret) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.SecretManagerSecret) - private static final com.google.cloudbuild.v1.SecretManagerSecret DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.SecretManagerSecret(); - } - - public static com.google.cloudbuild.v1.SecretManagerSecret getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public SecretManagerSecret parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.SecretManagerSecret getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/SecretManagerSecretOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/SecretManagerSecretOrBuilder.java deleted file mode 100644 index 9f221a34..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/SecretManagerSecretOrBuilder.java +++ /dev/null @@ -1,81 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface SecretManagerSecretOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.SecretManagerSecret) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * Resource name of the SecretVersion. In format:
-   * projects/*/secrets/*/versions/*
-   * 
- * - * string version_name = 1 [(.google.api.resource_reference) = { ... } - * - * @return The versionName. - */ - java.lang.String getVersionName(); - /** - * - * - *
-   * Resource name of the SecretVersion. In format:
-   * projects/*/secrets/*/versions/*
-   * 
- * - * string version_name = 1 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for versionName. - */ - com.google.protobuf.ByteString getVersionNameBytes(); - - /** - * - * - *
-   * Environment variable name to associate with the secret.
-   * Secret environment variables must be unique across all of a build's
-   * secrets, and must be used by at least one build step.
-   * 
- * - * string env = 2; - * - * @return The env. - */ - java.lang.String getEnv(); - /** - * - * - *
-   * Environment variable name to associate with the secret.
-   * Secret environment variables must be unique across all of a build's
-   * secrets, and must be used by at least one build step.
-   * 
- * - * string env = 2; - * - * @return The bytes for env. - */ - com.google.protobuf.ByteString getEnvBytes(); -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/SecretOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/SecretOrBuilder.java deleted file mode 100644 index 5bff583c..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/SecretOrBuilder.java +++ /dev/null @@ -1,129 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface SecretOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.Secret) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * Cloud KMS key name to use to decrypt these envs.
-   * 
- * - * string kms_key_name = 1; - * - * @return The kmsKeyName. - */ - java.lang.String getKmsKeyName(); - /** - * - * - *
-   * Cloud KMS key name to use to decrypt these envs.
-   * 
- * - * string kms_key_name = 1; - * - * @return The bytes for kmsKeyName. - */ - com.google.protobuf.ByteString getKmsKeyNameBytes(); - - /** - * - * - *
-   * Map of environment variable name to its encrypted value.
-   * Secret environment variables must be unique across all of a build's
-   * secrets, and must be used by at least one build step. Values can be at most
-   * 64 KB in size. There can be at most 100 secret values across all of a
-   * build's secrets.
-   * 
- * - * map<string, bytes> secret_env = 3; - */ - int getSecretEnvCount(); - /** - * - * - *
-   * Map of environment variable name to its encrypted value.
-   * Secret environment variables must be unique across all of a build's
-   * secrets, and must be used by at least one build step. Values can be at most
-   * 64 KB in size. There can be at most 100 secret values across all of a
-   * build's secrets.
-   * 
- * - * map<string, bytes> secret_env = 3; - */ - boolean containsSecretEnv(java.lang.String key); - /** Use {@link #getSecretEnvMap()} instead. */ - @java.lang.Deprecated - java.util.Map getSecretEnv(); - /** - * - * - *
-   * Map of environment variable name to its encrypted value.
-   * Secret environment variables must be unique across all of a build's
-   * secrets, and must be used by at least one build step. Values can be at most
-   * 64 KB in size. There can be at most 100 secret values across all of a
-   * build's secrets.
-   * 
- * - * map<string, bytes> secret_env = 3; - */ - java.util.Map getSecretEnvMap(); - /** - * - * - *
-   * Map of environment variable name to its encrypted value.
-   * Secret environment variables must be unique across all of a build's
-   * secrets, and must be used by at least one build step. Values can be at most
-   * 64 KB in size. There can be at most 100 secret values across all of a
-   * build's secrets.
-   * 
- * - * map<string, bytes> secret_env = 3; - */ - - /* nullable */ - com.google.protobuf.ByteString getSecretEnvOrDefault( - java.lang.String key, - /* nullable */ - com.google.protobuf.ByteString defaultValue); - /** - * - * - *
-   * Map of environment variable name to its encrypted value.
-   * Secret environment variables must be unique across all of a build's
-   * secrets, and must be used by at least one build step. Values can be at most
-   * 64 KB in size. There can be at most 100 secret values across all of a
-   * build's secrets.
-   * 
- * - * map<string, bytes> secret_env = 3; - */ - com.google.protobuf.ByteString getSecretEnvOrThrow(java.lang.String key); -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Secrets.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Secrets.java deleted file mode 100644 index a9b171f6..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Secrets.java +++ /dev/null @@ -1,1436 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * Secrets and secret environment variables.
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.Secrets} - */ -public final class Secrets extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.Secrets) - SecretsOrBuilder { - private static final long serialVersionUID = 0L; - // Use Secrets.newBuilder() to construct. - private Secrets(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private Secrets() { - secretManager_ = java.util.Collections.emptyList(); - inline_ = java.util.Collections.emptyList(); - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new Secrets(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Secrets_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Secrets_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.Secrets.class, com.google.cloudbuild.v1.Secrets.Builder.class); - } - - public static final int SECRET_MANAGER_FIELD_NUMBER = 1; - private java.util.List secretManager_; - /** - * - * - *
-   * Secrets in Secret Manager and associated secret environment variable.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.SecretManagerSecret secret_manager = 1; - */ - @java.lang.Override - public java.util.List getSecretManagerList() { - return secretManager_; - } - /** - * - * - *
-   * Secrets in Secret Manager and associated secret environment variable.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.SecretManagerSecret secret_manager = 1; - */ - @java.lang.Override - public java.util.List - getSecretManagerOrBuilderList() { - return secretManager_; - } - /** - * - * - *
-   * Secrets in Secret Manager and associated secret environment variable.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.SecretManagerSecret secret_manager = 1; - */ - @java.lang.Override - public int getSecretManagerCount() { - return secretManager_.size(); - } - /** - * - * - *
-   * Secrets in Secret Manager and associated secret environment variable.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.SecretManagerSecret secret_manager = 1; - */ - @java.lang.Override - public com.google.cloudbuild.v1.SecretManagerSecret getSecretManager(int index) { - return secretManager_.get(index); - } - /** - * - * - *
-   * Secrets in Secret Manager and associated secret environment variable.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.SecretManagerSecret secret_manager = 1; - */ - @java.lang.Override - public com.google.cloudbuild.v1.SecretManagerSecretOrBuilder getSecretManagerOrBuilder( - int index) { - return secretManager_.get(index); - } - - public static final int INLINE_FIELD_NUMBER = 2; - private java.util.List inline_; - /** - * - * - *
-   * Secrets encrypted with KMS key and the associated secret environment
-   * variable.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.InlineSecret inline = 2; - */ - @java.lang.Override - public java.util.List getInlineList() { - return inline_; - } - /** - * - * - *
-   * Secrets encrypted with KMS key and the associated secret environment
-   * variable.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.InlineSecret inline = 2; - */ - @java.lang.Override - public java.util.List - getInlineOrBuilderList() { - return inline_; - } - /** - * - * - *
-   * Secrets encrypted with KMS key and the associated secret environment
-   * variable.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.InlineSecret inline = 2; - */ - @java.lang.Override - public int getInlineCount() { - return inline_.size(); - } - /** - * - * - *
-   * Secrets encrypted with KMS key and the associated secret environment
-   * variable.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.InlineSecret inline = 2; - */ - @java.lang.Override - public com.google.cloudbuild.v1.InlineSecret getInline(int index) { - return inline_.get(index); - } - /** - * - * - *
-   * Secrets encrypted with KMS key and the associated secret environment
-   * variable.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.InlineSecret inline = 2; - */ - @java.lang.Override - public com.google.cloudbuild.v1.InlineSecretOrBuilder getInlineOrBuilder(int index) { - return inline_.get(index); - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - for (int i = 0; i < secretManager_.size(); i++) { - output.writeMessage(1, secretManager_.get(i)); - } - for (int i = 0; i < inline_.size(); i++) { - output.writeMessage(2, inline_.get(i)); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - for (int i = 0; i < secretManager_.size(); i++) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, secretManager_.get(i)); - } - for (int i = 0; i < inline_.size(); i++) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, inline_.get(i)); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.Secrets)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.Secrets other = (com.google.cloudbuild.v1.Secrets) obj; - - if (!getSecretManagerList().equals(other.getSecretManagerList())) return false; - if (!getInlineList().equals(other.getInlineList())) return false; - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (getSecretManagerCount() > 0) { - hash = (37 * hash) + SECRET_MANAGER_FIELD_NUMBER; - hash = (53 * hash) + getSecretManagerList().hashCode(); - } - if (getInlineCount() > 0) { - hash = (37 * hash) + INLINE_FIELD_NUMBER; - hash = (53 * hash) + getInlineList().hashCode(); - } - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.Secrets parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.Secrets parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.Secrets parseFrom(com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.Secrets parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.Secrets parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.Secrets parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.Secrets parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.Secrets parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.Secrets parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.Secrets parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.Secrets parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.Secrets parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.Secrets prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * Secrets and secret environment variables.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.Secrets} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.Secrets) - com.google.cloudbuild.v1.SecretsOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Secrets_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Secrets_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.Secrets.class, - com.google.cloudbuild.v1.Secrets.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.Secrets.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - if (secretManagerBuilder_ == null) { - secretManager_ = java.util.Collections.emptyList(); - } else { - secretManager_ = null; - secretManagerBuilder_.clear(); - } - bitField0_ = (bitField0_ & ~0x00000001); - if (inlineBuilder_ == null) { - inline_ = java.util.Collections.emptyList(); - } else { - inline_ = null; - inlineBuilder_.clear(); - } - bitField0_ = (bitField0_ & ~0x00000002); - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Secrets_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.Secrets getDefaultInstanceForType() { - return com.google.cloudbuild.v1.Secrets.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.Secrets build() { - com.google.cloudbuild.v1.Secrets result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.Secrets buildPartial() { - com.google.cloudbuild.v1.Secrets result = new com.google.cloudbuild.v1.Secrets(this); - int from_bitField0_ = bitField0_; - if (secretManagerBuilder_ == null) { - if (((bitField0_ & 0x00000001) != 0)) { - secretManager_ = java.util.Collections.unmodifiableList(secretManager_); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.secretManager_ = secretManager_; - } else { - result.secretManager_ = secretManagerBuilder_.build(); - } - if (inlineBuilder_ == null) { - if (((bitField0_ & 0x00000002) != 0)) { - inline_ = java.util.Collections.unmodifiableList(inline_); - bitField0_ = (bitField0_ & ~0x00000002); - } - result.inline_ = inline_; - } else { - result.inline_ = inlineBuilder_.build(); - } - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.Secrets) { - return mergeFrom((com.google.cloudbuild.v1.Secrets) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.Secrets other) { - if (other == com.google.cloudbuild.v1.Secrets.getDefaultInstance()) return this; - if (secretManagerBuilder_ == null) { - if (!other.secretManager_.isEmpty()) { - if (secretManager_.isEmpty()) { - secretManager_ = other.secretManager_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureSecretManagerIsMutable(); - secretManager_.addAll(other.secretManager_); - } - onChanged(); - } - } else { - if (!other.secretManager_.isEmpty()) { - if (secretManagerBuilder_.isEmpty()) { - secretManagerBuilder_.dispose(); - secretManagerBuilder_ = null; - secretManager_ = other.secretManager_; - bitField0_ = (bitField0_ & ~0x00000001); - secretManagerBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders - ? getSecretManagerFieldBuilder() - : null; - } else { - secretManagerBuilder_.addAllMessages(other.secretManager_); - } - } - } - if (inlineBuilder_ == null) { - if (!other.inline_.isEmpty()) { - if (inline_.isEmpty()) { - inline_ = other.inline_; - bitField0_ = (bitField0_ & ~0x00000002); - } else { - ensureInlineIsMutable(); - inline_.addAll(other.inline_); - } - onChanged(); - } - } else { - if (!other.inline_.isEmpty()) { - if (inlineBuilder_.isEmpty()) { - inlineBuilder_.dispose(); - inlineBuilder_ = null; - inline_ = other.inline_; - bitField0_ = (bitField0_ & ~0x00000002); - inlineBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders - ? getInlineFieldBuilder() - : null; - } else { - inlineBuilder_.addAllMessages(other.inline_); - } - } - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - com.google.cloudbuild.v1.SecretManagerSecret m = - input.readMessage( - com.google.cloudbuild.v1.SecretManagerSecret.parser(), extensionRegistry); - if (secretManagerBuilder_ == null) { - ensureSecretManagerIsMutable(); - secretManager_.add(m); - } else { - secretManagerBuilder_.addMessage(m); - } - break; - } // case 10 - case 18: - { - com.google.cloudbuild.v1.InlineSecret m = - input.readMessage( - com.google.cloudbuild.v1.InlineSecret.parser(), extensionRegistry); - if (inlineBuilder_ == null) { - ensureInlineIsMutable(); - inline_.add(m); - } else { - inlineBuilder_.addMessage(m); - } - break; - } // case 18 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private int bitField0_; - - private java.util.List secretManager_ = - java.util.Collections.emptyList(); - - private void ensureSecretManagerIsMutable() { - if (!((bitField0_ & 0x00000001) != 0)) { - secretManager_ = - new java.util.ArrayList(secretManager_); - bitField0_ |= 0x00000001; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloudbuild.v1.SecretManagerSecret, - com.google.cloudbuild.v1.SecretManagerSecret.Builder, - com.google.cloudbuild.v1.SecretManagerSecretOrBuilder> - secretManagerBuilder_; - - /** - * - * - *
-     * Secrets in Secret Manager and associated secret environment variable.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.SecretManagerSecret secret_manager = 1; - */ - public java.util.List getSecretManagerList() { - if (secretManagerBuilder_ == null) { - return java.util.Collections.unmodifiableList(secretManager_); - } else { - return secretManagerBuilder_.getMessageList(); - } - } - /** - * - * - *
-     * Secrets in Secret Manager and associated secret environment variable.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.SecretManagerSecret secret_manager = 1; - */ - public int getSecretManagerCount() { - if (secretManagerBuilder_ == null) { - return secretManager_.size(); - } else { - return secretManagerBuilder_.getCount(); - } - } - /** - * - * - *
-     * Secrets in Secret Manager and associated secret environment variable.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.SecretManagerSecret secret_manager = 1; - */ - public com.google.cloudbuild.v1.SecretManagerSecret getSecretManager(int index) { - if (secretManagerBuilder_ == null) { - return secretManager_.get(index); - } else { - return secretManagerBuilder_.getMessage(index); - } - } - /** - * - * - *
-     * Secrets in Secret Manager and associated secret environment variable.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.SecretManagerSecret secret_manager = 1; - */ - public Builder setSecretManager(int index, com.google.cloudbuild.v1.SecretManagerSecret value) { - if (secretManagerBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureSecretManagerIsMutable(); - secretManager_.set(index, value); - onChanged(); - } else { - secretManagerBuilder_.setMessage(index, value); - } - return this; - } - /** - * - * - *
-     * Secrets in Secret Manager and associated secret environment variable.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.SecretManagerSecret secret_manager = 1; - */ - public Builder setSecretManager( - int index, com.google.cloudbuild.v1.SecretManagerSecret.Builder builderForValue) { - if (secretManagerBuilder_ == null) { - ensureSecretManagerIsMutable(); - secretManager_.set(index, builderForValue.build()); - onChanged(); - } else { - secretManagerBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * Secrets in Secret Manager and associated secret environment variable.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.SecretManagerSecret secret_manager = 1; - */ - public Builder addSecretManager(com.google.cloudbuild.v1.SecretManagerSecret value) { - if (secretManagerBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureSecretManagerIsMutable(); - secretManager_.add(value); - onChanged(); - } else { - secretManagerBuilder_.addMessage(value); - } - return this; - } - /** - * - * - *
-     * Secrets in Secret Manager and associated secret environment variable.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.SecretManagerSecret secret_manager = 1; - */ - public Builder addSecretManager(int index, com.google.cloudbuild.v1.SecretManagerSecret value) { - if (secretManagerBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureSecretManagerIsMutable(); - secretManager_.add(index, value); - onChanged(); - } else { - secretManagerBuilder_.addMessage(index, value); - } - return this; - } - /** - * - * - *
-     * Secrets in Secret Manager and associated secret environment variable.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.SecretManagerSecret secret_manager = 1; - */ - public Builder addSecretManager( - com.google.cloudbuild.v1.SecretManagerSecret.Builder builderForValue) { - if (secretManagerBuilder_ == null) { - ensureSecretManagerIsMutable(); - secretManager_.add(builderForValue.build()); - onChanged(); - } else { - secretManagerBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * Secrets in Secret Manager and associated secret environment variable.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.SecretManagerSecret secret_manager = 1; - */ - public Builder addSecretManager( - int index, com.google.cloudbuild.v1.SecretManagerSecret.Builder builderForValue) { - if (secretManagerBuilder_ == null) { - ensureSecretManagerIsMutable(); - secretManager_.add(index, builderForValue.build()); - onChanged(); - } else { - secretManagerBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * Secrets in Secret Manager and associated secret environment variable.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.SecretManagerSecret secret_manager = 1; - */ - public Builder addAllSecretManager( - java.lang.Iterable values) { - if (secretManagerBuilder_ == null) { - ensureSecretManagerIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, secretManager_); - onChanged(); - } else { - secretManagerBuilder_.addAllMessages(values); - } - return this; - } - /** - * - * - *
-     * Secrets in Secret Manager and associated secret environment variable.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.SecretManagerSecret secret_manager = 1; - */ - public Builder clearSecretManager() { - if (secretManagerBuilder_ == null) { - secretManager_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - } else { - secretManagerBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * Secrets in Secret Manager and associated secret environment variable.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.SecretManagerSecret secret_manager = 1; - */ - public Builder removeSecretManager(int index) { - if (secretManagerBuilder_ == null) { - ensureSecretManagerIsMutable(); - secretManager_.remove(index); - onChanged(); - } else { - secretManagerBuilder_.remove(index); - } - return this; - } - /** - * - * - *
-     * Secrets in Secret Manager and associated secret environment variable.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.SecretManagerSecret secret_manager = 1; - */ - public com.google.cloudbuild.v1.SecretManagerSecret.Builder getSecretManagerBuilder(int index) { - return getSecretManagerFieldBuilder().getBuilder(index); - } - /** - * - * - *
-     * Secrets in Secret Manager and associated secret environment variable.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.SecretManagerSecret secret_manager = 1; - */ - public com.google.cloudbuild.v1.SecretManagerSecretOrBuilder getSecretManagerOrBuilder( - int index) { - if (secretManagerBuilder_ == null) { - return secretManager_.get(index); - } else { - return secretManagerBuilder_.getMessageOrBuilder(index); - } - } - /** - * - * - *
-     * Secrets in Secret Manager and associated secret environment variable.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.SecretManagerSecret secret_manager = 1; - */ - public java.util.List - getSecretManagerOrBuilderList() { - if (secretManagerBuilder_ != null) { - return secretManagerBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(secretManager_); - } - } - /** - * - * - *
-     * Secrets in Secret Manager and associated secret environment variable.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.SecretManagerSecret secret_manager = 1; - */ - public com.google.cloudbuild.v1.SecretManagerSecret.Builder addSecretManagerBuilder() { - return getSecretManagerFieldBuilder() - .addBuilder(com.google.cloudbuild.v1.SecretManagerSecret.getDefaultInstance()); - } - /** - * - * - *
-     * Secrets in Secret Manager and associated secret environment variable.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.SecretManagerSecret secret_manager = 1; - */ - public com.google.cloudbuild.v1.SecretManagerSecret.Builder addSecretManagerBuilder(int index) { - return getSecretManagerFieldBuilder() - .addBuilder(index, com.google.cloudbuild.v1.SecretManagerSecret.getDefaultInstance()); - } - /** - * - * - *
-     * Secrets in Secret Manager and associated secret environment variable.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.SecretManagerSecret secret_manager = 1; - */ - public java.util.List - getSecretManagerBuilderList() { - return getSecretManagerFieldBuilder().getBuilderList(); - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloudbuild.v1.SecretManagerSecret, - com.google.cloudbuild.v1.SecretManagerSecret.Builder, - com.google.cloudbuild.v1.SecretManagerSecretOrBuilder> - getSecretManagerFieldBuilder() { - if (secretManagerBuilder_ == null) { - secretManagerBuilder_ = - new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloudbuild.v1.SecretManagerSecret, - com.google.cloudbuild.v1.SecretManagerSecret.Builder, - com.google.cloudbuild.v1.SecretManagerSecretOrBuilder>( - secretManager_, - ((bitField0_ & 0x00000001) != 0), - getParentForChildren(), - isClean()); - secretManager_ = null; - } - return secretManagerBuilder_; - } - - private java.util.List inline_ = - java.util.Collections.emptyList(); - - private void ensureInlineIsMutable() { - if (!((bitField0_ & 0x00000002) != 0)) { - inline_ = new java.util.ArrayList(inline_); - bitField0_ |= 0x00000002; - } - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloudbuild.v1.InlineSecret, - com.google.cloudbuild.v1.InlineSecret.Builder, - com.google.cloudbuild.v1.InlineSecretOrBuilder> - inlineBuilder_; - - /** - * - * - *
-     * Secrets encrypted with KMS key and the associated secret environment
-     * variable.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.InlineSecret inline = 2; - */ - public java.util.List getInlineList() { - if (inlineBuilder_ == null) { - return java.util.Collections.unmodifiableList(inline_); - } else { - return inlineBuilder_.getMessageList(); - } - } - /** - * - * - *
-     * Secrets encrypted with KMS key and the associated secret environment
-     * variable.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.InlineSecret inline = 2; - */ - public int getInlineCount() { - if (inlineBuilder_ == null) { - return inline_.size(); - } else { - return inlineBuilder_.getCount(); - } - } - /** - * - * - *
-     * Secrets encrypted with KMS key and the associated secret environment
-     * variable.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.InlineSecret inline = 2; - */ - public com.google.cloudbuild.v1.InlineSecret getInline(int index) { - if (inlineBuilder_ == null) { - return inline_.get(index); - } else { - return inlineBuilder_.getMessage(index); - } - } - /** - * - * - *
-     * Secrets encrypted with KMS key and the associated secret environment
-     * variable.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.InlineSecret inline = 2; - */ - public Builder setInline(int index, com.google.cloudbuild.v1.InlineSecret value) { - if (inlineBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureInlineIsMutable(); - inline_.set(index, value); - onChanged(); - } else { - inlineBuilder_.setMessage(index, value); - } - return this; - } - /** - * - * - *
-     * Secrets encrypted with KMS key and the associated secret environment
-     * variable.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.InlineSecret inline = 2; - */ - public Builder setInline( - int index, com.google.cloudbuild.v1.InlineSecret.Builder builderForValue) { - if (inlineBuilder_ == null) { - ensureInlineIsMutable(); - inline_.set(index, builderForValue.build()); - onChanged(); - } else { - inlineBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * Secrets encrypted with KMS key and the associated secret environment
-     * variable.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.InlineSecret inline = 2; - */ - public Builder addInline(com.google.cloudbuild.v1.InlineSecret value) { - if (inlineBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureInlineIsMutable(); - inline_.add(value); - onChanged(); - } else { - inlineBuilder_.addMessage(value); - } - return this; - } - /** - * - * - *
-     * Secrets encrypted with KMS key and the associated secret environment
-     * variable.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.InlineSecret inline = 2; - */ - public Builder addInline(int index, com.google.cloudbuild.v1.InlineSecret value) { - if (inlineBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureInlineIsMutable(); - inline_.add(index, value); - onChanged(); - } else { - inlineBuilder_.addMessage(index, value); - } - return this; - } - /** - * - * - *
-     * Secrets encrypted with KMS key and the associated secret environment
-     * variable.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.InlineSecret inline = 2; - */ - public Builder addInline(com.google.cloudbuild.v1.InlineSecret.Builder builderForValue) { - if (inlineBuilder_ == null) { - ensureInlineIsMutable(); - inline_.add(builderForValue.build()); - onChanged(); - } else { - inlineBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * Secrets encrypted with KMS key and the associated secret environment
-     * variable.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.InlineSecret inline = 2; - */ - public Builder addInline( - int index, com.google.cloudbuild.v1.InlineSecret.Builder builderForValue) { - if (inlineBuilder_ == null) { - ensureInlineIsMutable(); - inline_.add(index, builderForValue.build()); - onChanged(); - } else { - inlineBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - * - * - *
-     * Secrets encrypted with KMS key and the associated secret environment
-     * variable.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.InlineSecret inline = 2; - */ - public Builder addAllInline( - java.lang.Iterable values) { - if (inlineBuilder_ == null) { - ensureInlineIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll(values, inline_); - onChanged(); - } else { - inlineBuilder_.addAllMessages(values); - } - return this; - } - /** - * - * - *
-     * Secrets encrypted with KMS key and the associated secret environment
-     * variable.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.InlineSecret inline = 2; - */ - public Builder clearInline() { - if (inlineBuilder_ == null) { - inline_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000002); - onChanged(); - } else { - inlineBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * Secrets encrypted with KMS key and the associated secret environment
-     * variable.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.InlineSecret inline = 2; - */ - public Builder removeInline(int index) { - if (inlineBuilder_ == null) { - ensureInlineIsMutable(); - inline_.remove(index); - onChanged(); - } else { - inlineBuilder_.remove(index); - } - return this; - } - /** - * - * - *
-     * Secrets encrypted with KMS key and the associated secret environment
-     * variable.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.InlineSecret inline = 2; - */ - public com.google.cloudbuild.v1.InlineSecret.Builder getInlineBuilder(int index) { - return getInlineFieldBuilder().getBuilder(index); - } - /** - * - * - *
-     * Secrets encrypted with KMS key and the associated secret environment
-     * variable.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.InlineSecret inline = 2; - */ - public com.google.cloudbuild.v1.InlineSecretOrBuilder getInlineOrBuilder(int index) { - if (inlineBuilder_ == null) { - return inline_.get(index); - } else { - return inlineBuilder_.getMessageOrBuilder(index); - } - } - /** - * - * - *
-     * Secrets encrypted with KMS key and the associated secret environment
-     * variable.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.InlineSecret inline = 2; - */ - public java.util.List - getInlineOrBuilderList() { - if (inlineBuilder_ != null) { - return inlineBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(inline_); - } - } - /** - * - * - *
-     * Secrets encrypted with KMS key and the associated secret environment
-     * variable.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.InlineSecret inline = 2; - */ - public com.google.cloudbuild.v1.InlineSecret.Builder addInlineBuilder() { - return getInlineFieldBuilder() - .addBuilder(com.google.cloudbuild.v1.InlineSecret.getDefaultInstance()); - } - /** - * - * - *
-     * Secrets encrypted with KMS key and the associated secret environment
-     * variable.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.InlineSecret inline = 2; - */ - public com.google.cloudbuild.v1.InlineSecret.Builder addInlineBuilder(int index) { - return getInlineFieldBuilder() - .addBuilder(index, com.google.cloudbuild.v1.InlineSecret.getDefaultInstance()); - } - /** - * - * - *
-     * Secrets encrypted with KMS key and the associated secret environment
-     * variable.
-     * 
- * - * repeated .google.devtools.cloudbuild.v1.InlineSecret inline = 2; - */ - public java.util.List getInlineBuilderList() { - return getInlineFieldBuilder().getBuilderList(); - } - - private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloudbuild.v1.InlineSecret, - com.google.cloudbuild.v1.InlineSecret.Builder, - com.google.cloudbuild.v1.InlineSecretOrBuilder> - getInlineFieldBuilder() { - if (inlineBuilder_ == null) { - inlineBuilder_ = - new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.cloudbuild.v1.InlineSecret, - com.google.cloudbuild.v1.InlineSecret.Builder, - com.google.cloudbuild.v1.InlineSecretOrBuilder>( - inline_, ((bitField0_ & 0x00000002) != 0), getParentForChildren(), isClean()); - inline_ = null; - } - return inlineBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.Secrets) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.Secrets) - private static final com.google.cloudbuild.v1.Secrets DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.Secrets(); - } - - public static com.google.cloudbuild.v1.Secrets getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public Secrets parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.Secrets getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/SecretsOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/SecretsOrBuilder.java deleted file mode 100644 index 6bd59c56..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/SecretsOrBuilder.java +++ /dev/null @@ -1,133 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface SecretsOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.Secrets) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * Secrets in Secret Manager and associated secret environment variable.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.SecretManagerSecret secret_manager = 1; - */ - java.util.List getSecretManagerList(); - /** - * - * - *
-   * Secrets in Secret Manager and associated secret environment variable.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.SecretManagerSecret secret_manager = 1; - */ - com.google.cloudbuild.v1.SecretManagerSecret getSecretManager(int index); - /** - * - * - *
-   * Secrets in Secret Manager and associated secret environment variable.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.SecretManagerSecret secret_manager = 1; - */ - int getSecretManagerCount(); - /** - * - * - *
-   * Secrets in Secret Manager and associated secret environment variable.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.SecretManagerSecret secret_manager = 1; - */ - java.util.List - getSecretManagerOrBuilderList(); - /** - * - * - *
-   * Secrets in Secret Manager and associated secret environment variable.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.SecretManagerSecret secret_manager = 1; - */ - com.google.cloudbuild.v1.SecretManagerSecretOrBuilder getSecretManagerOrBuilder(int index); - - /** - * - * - *
-   * Secrets encrypted with KMS key and the associated secret environment
-   * variable.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.InlineSecret inline = 2; - */ - java.util.List getInlineList(); - /** - * - * - *
-   * Secrets encrypted with KMS key and the associated secret environment
-   * variable.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.InlineSecret inline = 2; - */ - com.google.cloudbuild.v1.InlineSecret getInline(int index); - /** - * - * - *
-   * Secrets encrypted with KMS key and the associated secret environment
-   * variable.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.InlineSecret inline = 2; - */ - int getInlineCount(); - /** - * - * - *
-   * Secrets encrypted with KMS key and the associated secret environment
-   * variable.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.InlineSecret inline = 2; - */ - java.util.List getInlineOrBuilderList(); - /** - * - * - *
-   * Secrets encrypted with KMS key and the associated secret environment
-   * variable.
-   * 
- * - * repeated .google.devtools.cloudbuild.v1.InlineSecret inline = 2; - */ - com.google.cloudbuild.v1.InlineSecretOrBuilder getInlineOrBuilder(int index); -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Source.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Source.java deleted file mode 100644 index 4d34efcd..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Source.java +++ /dev/null @@ -1,1450 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * Location of the source in a supported storage service.
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.Source} - */ -public final class Source extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.Source) - SourceOrBuilder { - private static final long serialVersionUID = 0L; - // Use Source.newBuilder() to construct. - private Source(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private Source() {} - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new Source(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Source_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Source_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.Source.class, com.google.cloudbuild.v1.Source.Builder.class); - } - - private int sourceCase_ = 0; - private java.lang.Object source_; - - public enum SourceCase - implements - com.google.protobuf.Internal.EnumLite, - com.google.protobuf.AbstractMessage.InternalOneOfEnum { - STORAGE_SOURCE(2), - REPO_SOURCE(3), - STORAGE_SOURCE_MANIFEST(8), - SOURCE_NOT_SET(0); - private final int value; - - private SourceCase(int value) { - this.value = value; - } - /** - * @param value The number of the enum to look for. - * @return The enum associated with the given number. - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static SourceCase valueOf(int value) { - return forNumber(value); - } - - public static SourceCase forNumber(int value) { - switch (value) { - case 2: - return STORAGE_SOURCE; - case 3: - return REPO_SOURCE; - case 8: - return STORAGE_SOURCE_MANIFEST; - case 0: - return SOURCE_NOT_SET; - default: - return null; - } - } - - public int getNumber() { - return this.value; - } - }; - - public SourceCase getSourceCase() { - return SourceCase.forNumber(sourceCase_); - } - - public static final int STORAGE_SOURCE_FIELD_NUMBER = 2; - /** - * - * - *
-   * If provided, get the source from this location in Google Cloud Storage.
-   * 
- * - * .google.devtools.cloudbuild.v1.StorageSource storage_source = 2; - * - * @return Whether the storageSource field is set. - */ - @java.lang.Override - public boolean hasStorageSource() { - return sourceCase_ == 2; - } - /** - * - * - *
-   * If provided, get the source from this location in Google Cloud Storage.
-   * 
- * - * .google.devtools.cloudbuild.v1.StorageSource storage_source = 2; - * - * @return The storageSource. - */ - @java.lang.Override - public com.google.cloudbuild.v1.StorageSource getStorageSource() { - if (sourceCase_ == 2) { - return (com.google.cloudbuild.v1.StorageSource) source_; - } - return com.google.cloudbuild.v1.StorageSource.getDefaultInstance(); - } - /** - * - * - *
-   * If provided, get the source from this location in Google Cloud Storage.
-   * 
- * - * .google.devtools.cloudbuild.v1.StorageSource storage_source = 2; - */ - @java.lang.Override - public com.google.cloudbuild.v1.StorageSourceOrBuilder getStorageSourceOrBuilder() { - if (sourceCase_ == 2) { - return (com.google.cloudbuild.v1.StorageSource) source_; - } - return com.google.cloudbuild.v1.StorageSource.getDefaultInstance(); - } - - public static final int REPO_SOURCE_FIELD_NUMBER = 3; - /** - * - * - *
-   * If provided, get the source from this location in a Cloud Source
-   * Repository.
-   * 
- * - * .google.devtools.cloudbuild.v1.RepoSource repo_source = 3; - * - * @return Whether the repoSource field is set. - */ - @java.lang.Override - public boolean hasRepoSource() { - return sourceCase_ == 3; - } - /** - * - * - *
-   * If provided, get the source from this location in a Cloud Source
-   * Repository.
-   * 
- * - * .google.devtools.cloudbuild.v1.RepoSource repo_source = 3; - * - * @return The repoSource. - */ - @java.lang.Override - public com.google.cloudbuild.v1.RepoSource getRepoSource() { - if (sourceCase_ == 3) { - return (com.google.cloudbuild.v1.RepoSource) source_; - } - return com.google.cloudbuild.v1.RepoSource.getDefaultInstance(); - } - /** - * - * - *
-   * If provided, get the source from this location in a Cloud Source
-   * Repository.
-   * 
- * - * .google.devtools.cloudbuild.v1.RepoSource repo_source = 3; - */ - @java.lang.Override - public com.google.cloudbuild.v1.RepoSourceOrBuilder getRepoSourceOrBuilder() { - if (sourceCase_ == 3) { - return (com.google.cloudbuild.v1.RepoSource) source_; - } - return com.google.cloudbuild.v1.RepoSource.getDefaultInstance(); - } - - public static final int STORAGE_SOURCE_MANIFEST_FIELD_NUMBER = 8; - /** - * - * - *
-   * If provided, get the source from this manifest in Google Cloud Storage.
-   * This feature is in Preview; see description
-   * [here](https://github.com/GoogleCloudPlatform/cloud-builders/tree/master/gcs-fetcher).
-   * 
- * - * .google.devtools.cloudbuild.v1.StorageSourceManifest storage_source_manifest = 8; - * - * @return Whether the storageSourceManifest field is set. - */ - @java.lang.Override - public boolean hasStorageSourceManifest() { - return sourceCase_ == 8; - } - /** - * - * - *
-   * If provided, get the source from this manifest in Google Cloud Storage.
-   * This feature is in Preview; see description
-   * [here](https://github.com/GoogleCloudPlatform/cloud-builders/tree/master/gcs-fetcher).
-   * 
- * - * .google.devtools.cloudbuild.v1.StorageSourceManifest storage_source_manifest = 8; - * - * @return The storageSourceManifest. - */ - @java.lang.Override - public com.google.cloudbuild.v1.StorageSourceManifest getStorageSourceManifest() { - if (sourceCase_ == 8) { - return (com.google.cloudbuild.v1.StorageSourceManifest) source_; - } - return com.google.cloudbuild.v1.StorageSourceManifest.getDefaultInstance(); - } - /** - * - * - *
-   * If provided, get the source from this manifest in Google Cloud Storage.
-   * This feature is in Preview; see description
-   * [here](https://github.com/GoogleCloudPlatform/cloud-builders/tree/master/gcs-fetcher).
-   * 
- * - * .google.devtools.cloudbuild.v1.StorageSourceManifest storage_source_manifest = 8; - */ - @java.lang.Override - public com.google.cloudbuild.v1.StorageSourceManifestOrBuilder - getStorageSourceManifestOrBuilder() { - if (sourceCase_ == 8) { - return (com.google.cloudbuild.v1.StorageSourceManifest) source_; - } - return com.google.cloudbuild.v1.StorageSourceManifest.getDefaultInstance(); - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (sourceCase_ == 2) { - output.writeMessage(2, (com.google.cloudbuild.v1.StorageSource) source_); - } - if (sourceCase_ == 3) { - output.writeMessage(3, (com.google.cloudbuild.v1.RepoSource) source_); - } - if (sourceCase_ == 8) { - output.writeMessage(8, (com.google.cloudbuild.v1.StorageSourceManifest) source_); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (sourceCase_ == 2) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 2, (com.google.cloudbuild.v1.StorageSource) source_); - } - if (sourceCase_ == 3) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 3, (com.google.cloudbuild.v1.RepoSource) source_); - } - if (sourceCase_ == 8) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 8, (com.google.cloudbuild.v1.StorageSourceManifest) source_); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.Source)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.Source other = (com.google.cloudbuild.v1.Source) obj; - - if (!getSourceCase().equals(other.getSourceCase())) return false; - switch (sourceCase_) { - case 2: - if (!getStorageSource().equals(other.getStorageSource())) return false; - break; - case 3: - if (!getRepoSource().equals(other.getRepoSource())) return false; - break; - case 8: - if (!getStorageSourceManifest().equals(other.getStorageSourceManifest())) return false; - break; - case 0: - default: - } - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - switch (sourceCase_) { - case 2: - hash = (37 * hash) + STORAGE_SOURCE_FIELD_NUMBER; - hash = (53 * hash) + getStorageSource().hashCode(); - break; - case 3: - hash = (37 * hash) + REPO_SOURCE_FIELD_NUMBER; - hash = (53 * hash) + getRepoSource().hashCode(); - break; - case 8: - hash = (37 * hash) + STORAGE_SOURCE_MANIFEST_FIELD_NUMBER; - hash = (53 * hash) + getStorageSourceManifest().hashCode(); - break; - case 0: - default: - } - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.Source parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.Source parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.Source parseFrom(com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.Source parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.Source parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.Source parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.Source parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.Source parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.Source parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.Source parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.Source parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.Source parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.Source prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * Location of the source in a supported storage service.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.Source} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.Source) - com.google.cloudbuild.v1.SourceOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Source_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Source_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.Source.class, com.google.cloudbuild.v1.Source.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.Source.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - if (storageSourceBuilder_ != null) { - storageSourceBuilder_.clear(); - } - if (repoSourceBuilder_ != null) { - repoSourceBuilder_.clear(); - } - if (storageSourceManifestBuilder_ != null) { - storageSourceManifestBuilder_.clear(); - } - sourceCase_ = 0; - source_ = null; - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Source_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.Source getDefaultInstanceForType() { - return com.google.cloudbuild.v1.Source.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.Source build() { - com.google.cloudbuild.v1.Source result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.Source buildPartial() { - com.google.cloudbuild.v1.Source result = new com.google.cloudbuild.v1.Source(this); - if (sourceCase_ == 2) { - if (storageSourceBuilder_ == null) { - result.source_ = source_; - } else { - result.source_ = storageSourceBuilder_.build(); - } - } - if (sourceCase_ == 3) { - if (repoSourceBuilder_ == null) { - result.source_ = source_; - } else { - result.source_ = repoSourceBuilder_.build(); - } - } - if (sourceCase_ == 8) { - if (storageSourceManifestBuilder_ == null) { - result.source_ = source_; - } else { - result.source_ = storageSourceManifestBuilder_.build(); - } - } - result.sourceCase_ = sourceCase_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.Source) { - return mergeFrom((com.google.cloudbuild.v1.Source) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.Source other) { - if (other == com.google.cloudbuild.v1.Source.getDefaultInstance()) return this; - switch (other.getSourceCase()) { - case STORAGE_SOURCE: - { - mergeStorageSource(other.getStorageSource()); - break; - } - case REPO_SOURCE: - { - mergeRepoSource(other.getRepoSource()); - break; - } - case STORAGE_SOURCE_MANIFEST: - { - mergeStorageSourceManifest(other.getStorageSourceManifest()); - break; - } - case SOURCE_NOT_SET: - { - break; - } - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 18: - { - input.readMessage(getStorageSourceFieldBuilder().getBuilder(), extensionRegistry); - sourceCase_ = 2; - break; - } // case 18 - case 26: - { - input.readMessage(getRepoSourceFieldBuilder().getBuilder(), extensionRegistry); - sourceCase_ = 3; - break; - } // case 26 - case 66: - { - input.readMessage( - getStorageSourceManifestFieldBuilder().getBuilder(), extensionRegistry); - sourceCase_ = 8; - break; - } // case 66 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private int sourceCase_ = 0; - private java.lang.Object source_; - - public SourceCase getSourceCase() { - return SourceCase.forNumber(sourceCase_); - } - - public Builder clearSource() { - sourceCase_ = 0; - source_ = null; - onChanged(); - return this; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.StorageSource, - com.google.cloudbuild.v1.StorageSource.Builder, - com.google.cloudbuild.v1.StorageSourceOrBuilder> - storageSourceBuilder_; - /** - * - * - *
-     * If provided, get the source from this location in Google Cloud Storage.
-     * 
- * - * .google.devtools.cloudbuild.v1.StorageSource storage_source = 2; - * - * @return Whether the storageSource field is set. - */ - @java.lang.Override - public boolean hasStorageSource() { - return sourceCase_ == 2; - } - /** - * - * - *
-     * If provided, get the source from this location in Google Cloud Storage.
-     * 
- * - * .google.devtools.cloudbuild.v1.StorageSource storage_source = 2; - * - * @return The storageSource. - */ - @java.lang.Override - public com.google.cloudbuild.v1.StorageSource getStorageSource() { - if (storageSourceBuilder_ == null) { - if (sourceCase_ == 2) { - return (com.google.cloudbuild.v1.StorageSource) source_; - } - return com.google.cloudbuild.v1.StorageSource.getDefaultInstance(); - } else { - if (sourceCase_ == 2) { - return storageSourceBuilder_.getMessage(); - } - return com.google.cloudbuild.v1.StorageSource.getDefaultInstance(); - } - } - /** - * - * - *
-     * If provided, get the source from this location in Google Cloud Storage.
-     * 
- * - * .google.devtools.cloudbuild.v1.StorageSource storage_source = 2; - */ - public Builder setStorageSource(com.google.cloudbuild.v1.StorageSource value) { - if (storageSourceBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - source_ = value; - onChanged(); - } else { - storageSourceBuilder_.setMessage(value); - } - sourceCase_ = 2; - return this; - } - /** - * - * - *
-     * If provided, get the source from this location in Google Cloud Storage.
-     * 
- * - * .google.devtools.cloudbuild.v1.StorageSource storage_source = 2; - */ - public Builder setStorageSource( - com.google.cloudbuild.v1.StorageSource.Builder builderForValue) { - if (storageSourceBuilder_ == null) { - source_ = builderForValue.build(); - onChanged(); - } else { - storageSourceBuilder_.setMessage(builderForValue.build()); - } - sourceCase_ = 2; - return this; - } - /** - * - * - *
-     * If provided, get the source from this location in Google Cloud Storage.
-     * 
- * - * .google.devtools.cloudbuild.v1.StorageSource storage_source = 2; - */ - public Builder mergeStorageSource(com.google.cloudbuild.v1.StorageSource value) { - if (storageSourceBuilder_ == null) { - if (sourceCase_ == 2 - && source_ != com.google.cloudbuild.v1.StorageSource.getDefaultInstance()) { - source_ = - com.google.cloudbuild.v1.StorageSource.newBuilder( - (com.google.cloudbuild.v1.StorageSource) source_) - .mergeFrom(value) - .buildPartial(); - } else { - source_ = value; - } - onChanged(); - } else { - if (sourceCase_ == 2) { - storageSourceBuilder_.mergeFrom(value); - } else { - storageSourceBuilder_.setMessage(value); - } - } - sourceCase_ = 2; - return this; - } - /** - * - * - *
-     * If provided, get the source from this location in Google Cloud Storage.
-     * 
- * - * .google.devtools.cloudbuild.v1.StorageSource storage_source = 2; - */ - public Builder clearStorageSource() { - if (storageSourceBuilder_ == null) { - if (sourceCase_ == 2) { - sourceCase_ = 0; - source_ = null; - onChanged(); - } - } else { - if (sourceCase_ == 2) { - sourceCase_ = 0; - source_ = null; - } - storageSourceBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * If provided, get the source from this location in Google Cloud Storage.
-     * 
- * - * .google.devtools.cloudbuild.v1.StorageSource storage_source = 2; - */ - public com.google.cloudbuild.v1.StorageSource.Builder getStorageSourceBuilder() { - return getStorageSourceFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * If provided, get the source from this location in Google Cloud Storage.
-     * 
- * - * .google.devtools.cloudbuild.v1.StorageSource storage_source = 2; - */ - @java.lang.Override - public com.google.cloudbuild.v1.StorageSourceOrBuilder getStorageSourceOrBuilder() { - if ((sourceCase_ == 2) && (storageSourceBuilder_ != null)) { - return storageSourceBuilder_.getMessageOrBuilder(); - } else { - if (sourceCase_ == 2) { - return (com.google.cloudbuild.v1.StorageSource) source_; - } - return com.google.cloudbuild.v1.StorageSource.getDefaultInstance(); - } - } - /** - * - * - *
-     * If provided, get the source from this location in Google Cloud Storage.
-     * 
- * - * .google.devtools.cloudbuild.v1.StorageSource storage_source = 2; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.StorageSource, - com.google.cloudbuild.v1.StorageSource.Builder, - com.google.cloudbuild.v1.StorageSourceOrBuilder> - getStorageSourceFieldBuilder() { - if (storageSourceBuilder_ == null) { - if (!(sourceCase_ == 2)) { - source_ = com.google.cloudbuild.v1.StorageSource.getDefaultInstance(); - } - storageSourceBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.StorageSource, - com.google.cloudbuild.v1.StorageSource.Builder, - com.google.cloudbuild.v1.StorageSourceOrBuilder>( - (com.google.cloudbuild.v1.StorageSource) source_, - getParentForChildren(), - isClean()); - source_ = null; - } - sourceCase_ = 2; - onChanged(); - ; - return storageSourceBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.RepoSource, - com.google.cloudbuild.v1.RepoSource.Builder, - com.google.cloudbuild.v1.RepoSourceOrBuilder> - repoSourceBuilder_; - /** - * - * - *
-     * If provided, get the source from this location in a Cloud Source
-     * Repository.
-     * 
- * - * .google.devtools.cloudbuild.v1.RepoSource repo_source = 3; - * - * @return Whether the repoSource field is set. - */ - @java.lang.Override - public boolean hasRepoSource() { - return sourceCase_ == 3; - } - /** - * - * - *
-     * If provided, get the source from this location in a Cloud Source
-     * Repository.
-     * 
- * - * .google.devtools.cloudbuild.v1.RepoSource repo_source = 3; - * - * @return The repoSource. - */ - @java.lang.Override - public com.google.cloudbuild.v1.RepoSource getRepoSource() { - if (repoSourceBuilder_ == null) { - if (sourceCase_ == 3) { - return (com.google.cloudbuild.v1.RepoSource) source_; - } - return com.google.cloudbuild.v1.RepoSource.getDefaultInstance(); - } else { - if (sourceCase_ == 3) { - return repoSourceBuilder_.getMessage(); - } - return com.google.cloudbuild.v1.RepoSource.getDefaultInstance(); - } - } - /** - * - * - *
-     * If provided, get the source from this location in a Cloud Source
-     * Repository.
-     * 
- * - * .google.devtools.cloudbuild.v1.RepoSource repo_source = 3; - */ - public Builder setRepoSource(com.google.cloudbuild.v1.RepoSource value) { - if (repoSourceBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - source_ = value; - onChanged(); - } else { - repoSourceBuilder_.setMessage(value); - } - sourceCase_ = 3; - return this; - } - /** - * - * - *
-     * If provided, get the source from this location in a Cloud Source
-     * Repository.
-     * 
- * - * .google.devtools.cloudbuild.v1.RepoSource repo_source = 3; - */ - public Builder setRepoSource(com.google.cloudbuild.v1.RepoSource.Builder builderForValue) { - if (repoSourceBuilder_ == null) { - source_ = builderForValue.build(); - onChanged(); - } else { - repoSourceBuilder_.setMessage(builderForValue.build()); - } - sourceCase_ = 3; - return this; - } - /** - * - * - *
-     * If provided, get the source from this location in a Cloud Source
-     * Repository.
-     * 
- * - * .google.devtools.cloudbuild.v1.RepoSource repo_source = 3; - */ - public Builder mergeRepoSource(com.google.cloudbuild.v1.RepoSource value) { - if (repoSourceBuilder_ == null) { - if (sourceCase_ == 3 - && source_ != com.google.cloudbuild.v1.RepoSource.getDefaultInstance()) { - source_ = - com.google.cloudbuild.v1.RepoSource.newBuilder( - (com.google.cloudbuild.v1.RepoSource) source_) - .mergeFrom(value) - .buildPartial(); - } else { - source_ = value; - } - onChanged(); - } else { - if (sourceCase_ == 3) { - repoSourceBuilder_.mergeFrom(value); - } else { - repoSourceBuilder_.setMessage(value); - } - } - sourceCase_ = 3; - return this; - } - /** - * - * - *
-     * If provided, get the source from this location in a Cloud Source
-     * Repository.
-     * 
- * - * .google.devtools.cloudbuild.v1.RepoSource repo_source = 3; - */ - public Builder clearRepoSource() { - if (repoSourceBuilder_ == null) { - if (sourceCase_ == 3) { - sourceCase_ = 0; - source_ = null; - onChanged(); - } - } else { - if (sourceCase_ == 3) { - sourceCase_ = 0; - source_ = null; - } - repoSourceBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * If provided, get the source from this location in a Cloud Source
-     * Repository.
-     * 
- * - * .google.devtools.cloudbuild.v1.RepoSource repo_source = 3; - */ - public com.google.cloudbuild.v1.RepoSource.Builder getRepoSourceBuilder() { - return getRepoSourceFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * If provided, get the source from this location in a Cloud Source
-     * Repository.
-     * 
- * - * .google.devtools.cloudbuild.v1.RepoSource repo_source = 3; - */ - @java.lang.Override - public com.google.cloudbuild.v1.RepoSourceOrBuilder getRepoSourceOrBuilder() { - if ((sourceCase_ == 3) && (repoSourceBuilder_ != null)) { - return repoSourceBuilder_.getMessageOrBuilder(); - } else { - if (sourceCase_ == 3) { - return (com.google.cloudbuild.v1.RepoSource) source_; - } - return com.google.cloudbuild.v1.RepoSource.getDefaultInstance(); - } - } - /** - * - * - *
-     * If provided, get the source from this location in a Cloud Source
-     * Repository.
-     * 
- * - * .google.devtools.cloudbuild.v1.RepoSource repo_source = 3; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.RepoSource, - com.google.cloudbuild.v1.RepoSource.Builder, - com.google.cloudbuild.v1.RepoSourceOrBuilder> - getRepoSourceFieldBuilder() { - if (repoSourceBuilder_ == null) { - if (!(sourceCase_ == 3)) { - source_ = com.google.cloudbuild.v1.RepoSource.getDefaultInstance(); - } - repoSourceBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.RepoSource, - com.google.cloudbuild.v1.RepoSource.Builder, - com.google.cloudbuild.v1.RepoSourceOrBuilder>( - (com.google.cloudbuild.v1.RepoSource) source_, getParentForChildren(), isClean()); - source_ = null; - } - sourceCase_ = 3; - onChanged(); - ; - return repoSourceBuilder_; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.StorageSourceManifest, - com.google.cloudbuild.v1.StorageSourceManifest.Builder, - com.google.cloudbuild.v1.StorageSourceManifestOrBuilder> - storageSourceManifestBuilder_; - /** - * - * - *
-     * If provided, get the source from this manifest in Google Cloud Storage.
-     * This feature is in Preview; see description
-     * [here](https://github.com/GoogleCloudPlatform/cloud-builders/tree/master/gcs-fetcher).
-     * 
- * - * .google.devtools.cloudbuild.v1.StorageSourceManifest storage_source_manifest = 8; - * - * - * @return Whether the storageSourceManifest field is set. - */ - @java.lang.Override - public boolean hasStorageSourceManifest() { - return sourceCase_ == 8; - } - /** - * - * - *
-     * If provided, get the source from this manifest in Google Cloud Storage.
-     * This feature is in Preview; see description
-     * [here](https://github.com/GoogleCloudPlatform/cloud-builders/tree/master/gcs-fetcher).
-     * 
- * - * .google.devtools.cloudbuild.v1.StorageSourceManifest storage_source_manifest = 8; - * - * - * @return The storageSourceManifest. - */ - @java.lang.Override - public com.google.cloudbuild.v1.StorageSourceManifest getStorageSourceManifest() { - if (storageSourceManifestBuilder_ == null) { - if (sourceCase_ == 8) { - return (com.google.cloudbuild.v1.StorageSourceManifest) source_; - } - return com.google.cloudbuild.v1.StorageSourceManifest.getDefaultInstance(); - } else { - if (sourceCase_ == 8) { - return storageSourceManifestBuilder_.getMessage(); - } - return com.google.cloudbuild.v1.StorageSourceManifest.getDefaultInstance(); - } - } - /** - * - * - *
-     * If provided, get the source from this manifest in Google Cloud Storage.
-     * This feature is in Preview; see description
-     * [here](https://github.com/GoogleCloudPlatform/cloud-builders/tree/master/gcs-fetcher).
-     * 
- * - * .google.devtools.cloudbuild.v1.StorageSourceManifest storage_source_manifest = 8; - * - */ - public Builder setStorageSourceManifest(com.google.cloudbuild.v1.StorageSourceManifest value) { - if (storageSourceManifestBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - source_ = value; - onChanged(); - } else { - storageSourceManifestBuilder_.setMessage(value); - } - sourceCase_ = 8; - return this; - } - /** - * - * - *
-     * If provided, get the source from this manifest in Google Cloud Storage.
-     * This feature is in Preview; see description
-     * [here](https://github.com/GoogleCloudPlatform/cloud-builders/tree/master/gcs-fetcher).
-     * 
- * - * .google.devtools.cloudbuild.v1.StorageSourceManifest storage_source_manifest = 8; - * - */ - public Builder setStorageSourceManifest( - com.google.cloudbuild.v1.StorageSourceManifest.Builder builderForValue) { - if (storageSourceManifestBuilder_ == null) { - source_ = builderForValue.build(); - onChanged(); - } else { - storageSourceManifestBuilder_.setMessage(builderForValue.build()); - } - sourceCase_ = 8; - return this; - } - /** - * - * - *
-     * If provided, get the source from this manifest in Google Cloud Storage.
-     * This feature is in Preview; see description
-     * [here](https://github.com/GoogleCloudPlatform/cloud-builders/tree/master/gcs-fetcher).
-     * 
- * - * .google.devtools.cloudbuild.v1.StorageSourceManifest storage_source_manifest = 8; - * - */ - public Builder mergeStorageSourceManifest( - com.google.cloudbuild.v1.StorageSourceManifest value) { - if (storageSourceManifestBuilder_ == null) { - if (sourceCase_ == 8 - && source_ != com.google.cloudbuild.v1.StorageSourceManifest.getDefaultInstance()) { - source_ = - com.google.cloudbuild.v1.StorageSourceManifest.newBuilder( - (com.google.cloudbuild.v1.StorageSourceManifest) source_) - .mergeFrom(value) - .buildPartial(); - } else { - source_ = value; - } - onChanged(); - } else { - if (sourceCase_ == 8) { - storageSourceManifestBuilder_.mergeFrom(value); - } else { - storageSourceManifestBuilder_.setMessage(value); - } - } - sourceCase_ = 8; - return this; - } - /** - * - * - *
-     * If provided, get the source from this manifest in Google Cloud Storage.
-     * This feature is in Preview; see description
-     * [here](https://github.com/GoogleCloudPlatform/cloud-builders/tree/master/gcs-fetcher).
-     * 
- * - * .google.devtools.cloudbuild.v1.StorageSourceManifest storage_source_manifest = 8; - * - */ - public Builder clearStorageSourceManifest() { - if (storageSourceManifestBuilder_ == null) { - if (sourceCase_ == 8) { - sourceCase_ = 0; - source_ = null; - onChanged(); - } - } else { - if (sourceCase_ == 8) { - sourceCase_ = 0; - source_ = null; - } - storageSourceManifestBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * If provided, get the source from this manifest in Google Cloud Storage.
-     * This feature is in Preview; see description
-     * [here](https://github.com/GoogleCloudPlatform/cloud-builders/tree/master/gcs-fetcher).
-     * 
- * - * .google.devtools.cloudbuild.v1.StorageSourceManifest storage_source_manifest = 8; - * - */ - public com.google.cloudbuild.v1.StorageSourceManifest.Builder - getStorageSourceManifestBuilder() { - return getStorageSourceManifestFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * If provided, get the source from this manifest in Google Cloud Storage.
-     * This feature is in Preview; see description
-     * [here](https://github.com/GoogleCloudPlatform/cloud-builders/tree/master/gcs-fetcher).
-     * 
- * - * .google.devtools.cloudbuild.v1.StorageSourceManifest storage_source_manifest = 8; - * - */ - @java.lang.Override - public com.google.cloudbuild.v1.StorageSourceManifestOrBuilder - getStorageSourceManifestOrBuilder() { - if ((sourceCase_ == 8) && (storageSourceManifestBuilder_ != null)) { - return storageSourceManifestBuilder_.getMessageOrBuilder(); - } else { - if (sourceCase_ == 8) { - return (com.google.cloudbuild.v1.StorageSourceManifest) source_; - } - return com.google.cloudbuild.v1.StorageSourceManifest.getDefaultInstance(); - } - } - /** - * - * - *
-     * If provided, get the source from this manifest in Google Cloud Storage.
-     * This feature is in Preview; see description
-     * [here](https://github.com/GoogleCloudPlatform/cloud-builders/tree/master/gcs-fetcher).
-     * 
- * - * .google.devtools.cloudbuild.v1.StorageSourceManifest storage_source_manifest = 8; - * - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.StorageSourceManifest, - com.google.cloudbuild.v1.StorageSourceManifest.Builder, - com.google.cloudbuild.v1.StorageSourceManifestOrBuilder> - getStorageSourceManifestFieldBuilder() { - if (storageSourceManifestBuilder_ == null) { - if (!(sourceCase_ == 8)) { - source_ = com.google.cloudbuild.v1.StorageSourceManifest.getDefaultInstance(); - } - storageSourceManifestBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.StorageSourceManifest, - com.google.cloudbuild.v1.StorageSourceManifest.Builder, - com.google.cloudbuild.v1.StorageSourceManifestOrBuilder>( - (com.google.cloudbuild.v1.StorageSourceManifest) source_, - getParentForChildren(), - isClean()); - source_ = null; - } - sourceCase_ = 8; - onChanged(); - ; - return storageSourceManifestBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.Source) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.Source) - private static final com.google.cloudbuild.v1.Source DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.Source(); - } - - public static com.google.cloudbuild.v1.Source getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public Source parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.Source getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/SourceOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/SourceOrBuilder.java deleted file mode 100644 index e5273e28..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/SourceOrBuilder.java +++ /dev/null @@ -1,141 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface SourceOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.Source) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * If provided, get the source from this location in Google Cloud Storage.
-   * 
- * - * .google.devtools.cloudbuild.v1.StorageSource storage_source = 2; - * - * @return Whether the storageSource field is set. - */ - boolean hasStorageSource(); - /** - * - * - *
-   * If provided, get the source from this location in Google Cloud Storage.
-   * 
- * - * .google.devtools.cloudbuild.v1.StorageSource storage_source = 2; - * - * @return The storageSource. - */ - com.google.cloudbuild.v1.StorageSource getStorageSource(); - /** - * - * - *
-   * If provided, get the source from this location in Google Cloud Storage.
-   * 
- * - * .google.devtools.cloudbuild.v1.StorageSource storage_source = 2; - */ - com.google.cloudbuild.v1.StorageSourceOrBuilder getStorageSourceOrBuilder(); - - /** - * - * - *
-   * If provided, get the source from this location in a Cloud Source
-   * Repository.
-   * 
- * - * .google.devtools.cloudbuild.v1.RepoSource repo_source = 3; - * - * @return Whether the repoSource field is set. - */ - boolean hasRepoSource(); - /** - * - * - *
-   * If provided, get the source from this location in a Cloud Source
-   * Repository.
-   * 
- * - * .google.devtools.cloudbuild.v1.RepoSource repo_source = 3; - * - * @return The repoSource. - */ - com.google.cloudbuild.v1.RepoSource getRepoSource(); - /** - * - * - *
-   * If provided, get the source from this location in a Cloud Source
-   * Repository.
-   * 
- * - * .google.devtools.cloudbuild.v1.RepoSource repo_source = 3; - */ - com.google.cloudbuild.v1.RepoSourceOrBuilder getRepoSourceOrBuilder(); - - /** - * - * - *
-   * If provided, get the source from this manifest in Google Cloud Storage.
-   * This feature is in Preview; see description
-   * [here](https://github.com/GoogleCloudPlatform/cloud-builders/tree/master/gcs-fetcher).
-   * 
- * - * .google.devtools.cloudbuild.v1.StorageSourceManifest storage_source_manifest = 8; - * - * @return Whether the storageSourceManifest field is set. - */ - boolean hasStorageSourceManifest(); - /** - * - * - *
-   * If provided, get the source from this manifest in Google Cloud Storage.
-   * This feature is in Preview; see description
-   * [here](https://github.com/GoogleCloudPlatform/cloud-builders/tree/master/gcs-fetcher).
-   * 
- * - * .google.devtools.cloudbuild.v1.StorageSourceManifest storage_source_manifest = 8; - * - * @return The storageSourceManifest. - */ - com.google.cloudbuild.v1.StorageSourceManifest getStorageSourceManifest(); - /** - * - * - *
-   * If provided, get the source from this manifest in Google Cloud Storage.
-   * This feature is in Preview; see description
-   * [here](https://github.com/GoogleCloudPlatform/cloud-builders/tree/master/gcs-fetcher).
-   * 
- * - * .google.devtools.cloudbuild.v1.StorageSourceManifest storage_source_manifest = 8; - */ - com.google.cloudbuild.v1.StorageSourceManifestOrBuilder getStorageSourceManifestOrBuilder(); - - public com.google.cloudbuild.v1.Source.SourceCase getSourceCase(); -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/SourceProvenance.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/SourceProvenance.java deleted file mode 100644 index 4acc6d33..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/SourceProvenance.java +++ /dev/null @@ -1,1766 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * Provenance of the source. Ways to find the original source, or verify that
- * some source was used for this build.
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.SourceProvenance} - */ -public final class SourceProvenance extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.SourceProvenance) - SourceProvenanceOrBuilder { - private static final long serialVersionUID = 0L; - // Use SourceProvenance.newBuilder() to construct. - private SourceProvenance(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private SourceProvenance() {} - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new SourceProvenance(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_SourceProvenance_descriptor; - } - - @SuppressWarnings({"rawtypes"}) - @java.lang.Override - protected com.google.protobuf.MapField internalGetMapField(int number) { - switch (number) { - case 4: - return internalGetFileHashes(); - default: - throw new RuntimeException("Invalid map field number: " + number); - } - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_SourceProvenance_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.SourceProvenance.class, - com.google.cloudbuild.v1.SourceProvenance.Builder.class); - } - - public static final int RESOLVED_STORAGE_SOURCE_FIELD_NUMBER = 3; - private com.google.cloudbuild.v1.StorageSource resolvedStorageSource_; - /** - * - * - *
-   * A copy of the build's `source.storage_source`, if exists, with any
-   * generations resolved.
-   * 
- * - * .google.devtools.cloudbuild.v1.StorageSource resolved_storage_source = 3; - * - * @return Whether the resolvedStorageSource field is set. - */ - @java.lang.Override - public boolean hasResolvedStorageSource() { - return resolvedStorageSource_ != null; - } - /** - * - * - *
-   * A copy of the build's `source.storage_source`, if exists, with any
-   * generations resolved.
-   * 
- * - * .google.devtools.cloudbuild.v1.StorageSource resolved_storage_source = 3; - * - * @return The resolvedStorageSource. - */ - @java.lang.Override - public com.google.cloudbuild.v1.StorageSource getResolvedStorageSource() { - return resolvedStorageSource_ == null - ? com.google.cloudbuild.v1.StorageSource.getDefaultInstance() - : resolvedStorageSource_; - } - /** - * - * - *
-   * A copy of the build's `source.storage_source`, if exists, with any
-   * generations resolved.
-   * 
- * - * .google.devtools.cloudbuild.v1.StorageSource resolved_storage_source = 3; - */ - @java.lang.Override - public com.google.cloudbuild.v1.StorageSourceOrBuilder getResolvedStorageSourceOrBuilder() { - return getResolvedStorageSource(); - } - - public static final int RESOLVED_REPO_SOURCE_FIELD_NUMBER = 6; - private com.google.cloudbuild.v1.RepoSource resolvedRepoSource_; - /** - * - * - *
-   * A copy of the build's `source.repo_source`, if exists, with any
-   * revisions resolved.
-   * 
- * - * .google.devtools.cloudbuild.v1.RepoSource resolved_repo_source = 6; - * - * @return Whether the resolvedRepoSource field is set. - */ - @java.lang.Override - public boolean hasResolvedRepoSource() { - return resolvedRepoSource_ != null; - } - /** - * - * - *
-   * A copy of the build's `source.repo_source`, if exists, with any
-   * revisions resolved.
-   * 
- * - * .google.devtools.cloudbuild.v1.RepoSource resolved_repo_source = 6; - * - * @return The resolvedRepoSource. - */ - @java.lang.Override - public com.google.cloudbuild.v1.RepoSource getResolvedRepoSource() { - return resolvedRepoSource_ == null - ? com.google.cloudbuild.v1.RepoSource.getDefaultInstance() - : resolvedRepoSource_; - } - /** - * - * - *
-   * A copy of the build's `source.repo_source`, if exists, with any
-   * revisions resolved.
-   * 
- * - * .google.devtools.cloudbuild.v1.RepoSource resolved_repo_source = 6; - */ - @java.lang.Override - public com.google.cloudbuild.v1.RepoSourceOrBuilder getResolvedRepoSourceOrBuilder() { - return getResolvedRepoSource(); - } - - public static final int RESOLVED_STORAGE_SOURCE_MANIFEST_FIELD_NUMBER = 9; - private com.google.cloudbuild.v1.StorageSourceManifest resolvedStorageSourceManifest_; - /** - * - * - *
-   * A copy of the build's `source.storage_source_manifest`, if exists, with any
-   * revisions resolved.
-   * This feature is in Preview.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.StorageSourceManifest resolved_storage_source_manifest = 9; - * - * - * @return Whether the resolvedStorageSourceManifest field is set. - */ - @java.lang.Override - public boolean hasResolvedStorageSourceManifest() { - return resolvedStorageSourceManifest_ != null; - } - /** - * - * - *
-   * A copy of the build's `source.storage_source_manifest`, if exists, with any
-   * revisions resolved.
-   * This feature is in Preview.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.StorageSourceManifest resolved_storage_source_manifest = 9; - * - * - * @return The resolvedStorageSourceManifest. - */ - @java.lang.Override - public com.google.cloudbuild.v1.StorageSourceManifest getResolvedStorageSourceManifest() { - return resolvedStorageSourceManifest_ == null - ? com.google.cloudbuild.v1.StorageSourceManifest.getDefaultInstance() - : resolvedStorageSourceManifest_; - } - /** - * - * - *
-   * A copy of the build's `source.storage_source_manifest`, if exists, with any
-   * revisions resolved.
-   * This feature is in Preview.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.StorageSourceManifest resolved_storage_source_manifest = 9; - * - */ - @java.lang.Override - public com.google.cloudbuild.v1.StorageSourceManifestOrBuilder - getResolvedStorageSourceManifestOrBuilder() { - return getResolvedStorageSourceManifest(); - } - - public static final int FILE_HASHES_FIELD_NUMBER = 4; - - private static final class FileHashesDefaultEntryHolder { - static final com.google.protobuf.MapEntry - defaultEntry = - com.google.protobuf.MapEntry - .newDefaultInstance( - com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_SourceProvenance_FileHashesEntry_descriptor, - com.google.protobuf.WireFormat.FieldType.STRING, - "", - com.google.protobuf.WireFormat.FieldType.MESSAGE, - com.google.cloudbuild.v1.FileHashes.getDefaultInstance()); - } - - private com.google.protobuf.MapField - fileHashes_; - - private com.google.protobuf.MapField - internalGetFileHashes() { - if (fileHashes_ == null) { - return com.google.protobuf.MapField.emptyMapField(FileHashesDefaultEntryHolder.defaultEntry); - } - return fileHashes_; - } - - public int getFileHashesCount() { - return internalGetFileHashes().getMap().size(); - } - /** - * - * - *
-   * Output only. Hash(es) of the build source, which can be used to verify that
-   * the original source integrity was maintained in the build. Note that
-   * `FileHashes` will only be populated if `BuildOptions` has requested a
-   * `SourceProvenanceHash`.
-   * The keys to this map are file paths used as build source and the values
-   * contain the hash values for those files.
-   * If the build source came in a single package such as a gzipped tarfile
-   * (`.tar.gz`), the `FileHash` will be for the single path to that file.
-   * 
- * - * - * map<string, .google.devtools.cloudbuild.v1.FileHashes> file_hashes = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - @java.lang.Override - public boolean containsFileHashes(java.lang.String key) { - if (key == null) { - throw new NullPointerException("map key"); - } - return internalGetFileHashes().getMap().containsKey(key); - } - /** Use {@link #getFileHashesMap()} instead. */ - @java.lang.Override - @java.lang.Deprecated - public java.util.Map getFileHashes() { - return getFileHashesMap(); - } - /** - * - * - *
-   * Output only. Hash(es) of the build source, which can be used to verify that
-   * the original source integrity was maintained in the build. Note that
-   * `FileHashes` will only be populated if `BuildOptions` has requested a
-   * `SourceProvenanceHash`.
-   * The keys to this map are file paths used as build source and the values
-   * contain the hash values for those files.
-   * If the build source came in a single package such as a gzipped tarfile
-   * (`.tar.gz`), the `FileHash` will be for the single path to that file.
-   * 
- * - * - * map<string, .google.devtools.cloudbuild.v1.FileHashes> file_hashes = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - @java.lang.Override - public java.util.Map getFileHashesMap() { - return internalGetFileHashes().getMap(); - } - /** - * - * - *
-   * Output only. Hash(es) of the build source, which can be used to verify that
-   * the original source integrity was maintained in the build. Note that
-   * `FileHashes` will only be populated if `BuildOptions` has requested a
-   * `SourceProvenanceHash`.
-   * The keys to this map are file paths used as build source and the values
-   * contain the hash values for those files.
-   * If the build source came in a single package such as a gzipped tarfile
-   * (`.tar.gz`), the `FileHash` will be for the single path to that file.
-   * 
- * - * - * map<string, .google.devtools.cloudbuild.v1.FileHashes> file_hashes = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - @java.lang.Override - public com.google.cloudbuild.v1.FileHashes getFileHashesOrDefault( - java.lang.String key, com.google.cloudbuild.v1.FileHashes defaultValue) { - if (key == null) { - throw new NullPointerException("map key"); - } - java.util.Map map = - internalGetFileHashes().getMap(); - return map.containsKey(key) ? map.get(key) : defaultValue; - } - /** - * - * - *
-   * Output only. Hash(es) of the build source, which can be used to verify that
-   * the original source integrity was maintained in the build. Note that
-   * `FileHashes` will only be populated if `BuildOptions` has requested a
-   * `SourceProvenanceHash`.
-   * The keys to this map are file paths used as build source and the values
-   * contain the hash values for those files.
-   * If the build source came in a single package such as a gzipped tarfile
-   * (`.tar.gz`), the `FileHash` will be for the single path to that file.
-   * 
- * - * - * map<string, .google.devtools.cloudbuild.v1.FileHashes> file_hashes = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - @java.lang.Override - public com.google.cloudbuild.v1.FileHashes getFileHashesOrThrow(java.lang.String key) { - if (key == null) { - throw new NullPointerException("map key"); - } - java.util.Map map = - internalGetFileHashes().getMap(); - if (!map.containsKey(key)) { - throw new java.lang.IllegalArgumentException(); - } - return map.get(key); - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (resolvedStorageSource_ != null) { - output.writeMessage(3, getResolvedStorageSource()); - } - com.google.protobuf.GeneratedMessageV3.serializeStringMapTo( - output, internalGetFileHashes(), FileHashesDefaultEntryHolder.defaultEntry, 4); - if (resolvedRepoSource_ != null) { - output.writeMessage(6, getResolvedRepoSource()); - } - if (resolvedStorageSourceManifest_ != null) { - output.writeMessage(9, getResolvedStorageSourceManifest()); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (resolvedStorageSource_ != null) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize(3, getResolvedStorageSource()); - } - for (java.util.Map.Entry entry : - internalGetFileHashes().getMap().entrySet()) { - com.google.protobuf.MapEntry - fileHashes__ = - FileHashesDefaultEntryHolder.defaultEntry - .newBuilderForType() - .setKey(entry.getKey()) - .setValue(entry.getValue()) - .build(); - size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, fileHashes__); - } - if (resolvedRepoSource_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(6, getResolvedRepoSource()); - } - if (resolvedStorageSourceManifest_ != null) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 9, getResolvedStorageSourceManifest()); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.SourceProvenance)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.SourceProvenance other = - (com.google.cloudbuild.v1.SourceProvenance) obj; - - if (hasResolvedStorageSource() != other.hasResolvedStorageSource()) return false; - if (hasResolvedStorageSource()) { - if (!getResolvedStorageSource().equals(other.getResolvedStorageSource())) return false; - } - if (hasResolvedRepoSource() != other.hasResolvedRepoSource()) return false; - if (hasResolvedRepoSource()) { - if (!getResolvedRepoSource().equals(other.getResolvedRepoSource())) return false; - } - if (hasResolvedStorageSourceManifest() != other.hasResolvedStorageSourceManifest()) - return false; - if (hasResolvedStorageSourceManifest()) { - if (!getResolvedStorageSourceManifest().equals(other.getResolvedStorageSourceManifest())) - return false; - } - if (!internalGetFileHashes().equals(other.internalGetFileHashes())) return false; - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasResolvedStorageSource()) { - hash = (37 * hash) + RESOLVED_STORAGE_SOURCE_FIELD_NUMBER; - hash = (53 * hash) + getResolvedStorageSource().hashCode(); - } - if (hasResolvedRepoSource()) { - hash = (37 * hash) + RESOLVED_REPO_SOURCE_FIELD_NUMBER; - hash = (53 * hash) + getResolvedRepoSource().hashCode(); - } - if (hasResolvedStorageSourceManifest()) { - hash = (37 * hash) + RESOLVED_STORAGE_SOURCE_MANIFEST_FIELD_NUMBER; - hash = (53 * hash) + getResolvedStorageSourceManifest().hashCode(); - } - if (!internalGetFileHashes().getMap().isEmpty()) { - hash = (37 * hash) + FILE_HASHES_FIELD_NUMBER; - hash = (53 * hash) + internalGetFileHashes().hashCode(); - } - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.SourceProvenance parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.SourceProvenance parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.SourceProvenance parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.SourceProvenance parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.SourceProvenance parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.SourceProvenance parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.SourceProvenance parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.SourceProvenance parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.SourceProvenance parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.SourceProvenance parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.SourceProvenance parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.SourceProvenance parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.SourceProvenance prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * Provenance of the source. Ways to find the original source, or verify that
-   * some source was used for this build.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.SourceProvenance} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.SourceProvenance) - com.google.cloudbuild.v1.SourceProvenanceOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_SourceProvenance_descriptor; - } - - @SuppressWarnings({"rawtypes"}) - protected com.google.protobuf.MapField internalGetMapField(int number) { - switch (number) { - case 4: - return internalGetFileHashes(); - default: - throw new RuntimeException("Invalid map field number: " + number); - } - } - - @SuppressWarnings({"rawtypes"}) - protected com.google.protobuf.MapField internalGetMutableMapField(int number) { - switch (number) { - case 4: - return internalGetMutableFileHashes(); - default: - throw new RuntimeException("Invalid map field number: " + number); - } - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_SourceProvenance_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.SourceProvenance.class, - com.google.cloudbuild.v1.SourceProvenance.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.SourceProvenance.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - if (resolvedStorageSourceBuilder_ == null) { - resolvedStorageSource_ = null; - } else { - resolvedStorageSource_ = null; - resolvedStorageSourceBuilder_ = null; - } - if (resolvedRepoSourceBuilder_ == null) { - resolvedRepoSource_ = null; - } else { - resolvedRepoSource_ = null; - resolvedRepoSourceBuilder_ = null; - } - if (resolvedStorageSourceManifestBuilder_ == null) { - resolvedStorageSourceManifest_ = null; - } else { - resolvedStorageSourceManifest_ = null; - resolvedStorageSourceManifestBuilder_ = null; - } - internalGetMutableFileHashes().clear(); - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_SourceProvenance_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.SourceProvenance getDefaultInstanceForType() { - return com.google.cloudbuild.v1.SourceProvenance.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.SourceProvenance build() { - com.google.cloudbuild.v1.SourceProvenance result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.SourceProvenance buildPartial() { - com.google.cloudbuild.v1.SourceProvenance result = - new com.google.cloudbuild.v1.SourceProvenance(this); - int from_bitField0_ = bitField0_; - if (resolvedStorageSourceBuilder_ == null) { - result.resolvedStorageSource_ = resolvedStorageSource_; - } else { - result.resolvedStorageSource_ = resolvedStorageSourceBuilder_.build(); - } - if (resolvedRepoSourceBuilder_ == null) { - result.resolvedRepoSource_ = resolvedRepoSource_; - } else { - result.resolvedRepoSource_ = resolvedRepoSourceBuilder_.build(); - } - if (resolvedStorageSourceManifestBuilder_ == null) { - result.resolvedStorageSourceManifest_ = resolvedStorageSourceManifest_; - } else { - result.resolvedStorageSourceManifest_ = resolvedStorageSourceManifestBuilder_.build(); - } - result.fileHashes_ = internalGetFileHashes(); - result.fileHashes_.makeImmutable(); - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.SourceProvenance) { - return mergeFrom((com.google.cloudbuild.v1.SourceProvenance) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.SourceProvenance other) { - if (other == com.google.cloudbuild.v1.SourceProvenance.getDefaultInstance()) return this; - if (other.hasResolvedStorageSource()) { - mergeResolvedStorageSource(other.getResolvedStorageSource()); - } - if (other.hasResolvedRepoSource()) { - mergeResolvedRepoSource(other.getResolvedRepoSource()); - } - if (other.hasResolvedStorageSourceManifest()) { - mergeResolvedStorageSourceManifest(other.getResolvedStorageSourceManifest()); - } - internalGetMutableFileHashes().mergeFrom(other.internalGetFileHashes()); - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 26: - { - input.readMessage( - getResolvedStorageSourceFieldBuilder().getBuilder(), extensionRegistry); - - break; - } // case 26 - case 34: - { - com.google.protobuf.MapEntry - fileHashes__ = - input.readMessage( - FileHashesDefaultEntryHolder.defaultEntry.getParserForType(), - extensionRegistry); - internalGetMutableFileHashes() - .getMutableMap() - .put(fileHashes__.getKey(), fileHashes__.getValue()); - break; - } // case 34 - case 50: - { - input.readMessage( - getResolvedRepoSourceFieldBuilder().getBuilder(), extensionRegistry); - - break; - } // case 50 - case 74: - { - input.readMessage( - getResolvedStorageSourceManifestFieldBuilder().getBuilder(), extensionRegistry); - - break; - } // case 74 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private int bitField0_; - - private com.google.cloudbuild.v1.StorageSource resolvedStorageSource_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.StorageSource, - com.google.cloudbuild.v1.StorageSource.Builder, - com.google.cloudbuild.v1.StorageSourceOrBuilder> - resolvedStorageSourceBuilder_; - /** - * - * - *
-     * A copy of the build's `source.storage_source`, if exists, with any
-     * generations resolved.
-     * 
- * - * .google.devtools.cloudbuild.v1.StorageSource resolved_storage_source = 3; - * - * @return Whether the resolvedStorageSource field is set. - */ - public boolean hasResolvedStorageSource() { - return resolvedStorageSourceBuilder_ != null || resolvedStorageSource_ != null; - } - /** - * - * - *
-     * A copy of the build's `source.storage_source`, if exists, with any
-     * generations resolved.
-     * 
- * - * .google.devtools.cloudbuild.v1.StorageSource resolved_storage_source = 3; - * - * @return The resolvedStorageSource. - */ - public com.google.cloudbuild.v1.StorageSource getResolvedStorageSource() { - if (resolvedStorageSourceBuilder_ == null) { - return resolvedStorageSource_ == null - ? com.google.cloudbuild.v1.StorageSource.getDefaultInstance() - : resolvedStorageSource_; - } else { - return resolvedStorageSourceBuilder_.getMessage(); - } - } - /** - * - * - *
-     * A copy of the build's `source.storage_source`, if exists, with any
-     * generations resolved.
-     * 
- * - * .google.devtools.cloudbuild.v1.StorageSource resolved_storage_source = 3; - */ - public Builder setResolvedStorageSource(com.google.cloudbuild.v1.StorageSource value) { - if (resolvedStorageSourceBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - resolvedStorageSource_ = value; - onChanged(); - } else { - resolvedStorageSourceBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * A copy of the build's `source.storage_source`, if exists, with any
-     * generations resolved.
-     * 
- * - * .google.devtools.cloudbuild.v1.StorageSource resolved_storage_source = 3; - */ - public Builder setResolvedStorageSource( - com.google.cloudbuild.v1.StorageSource.Builder builderForValue) { - if (resolvedStorageSourceBuilder_ == null) { - resolvedStorageSource_ = builderForValue.build(); - onChanged(); - } else { - resolvedStorageSourceBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * A copy of the build's `source.storage_source`, if exists, with any
-     * generations resolved.
-     * 
- * - * .google.devtools.cloudbuild.v1.StorageSource resolved_storage_source = 3; - */ - public Builder mergeResolvedStorageSource(com.google.cloudbuild.v1.StorageSource value) { - if (resolvedStorageSourceBuilder_ == null) { - if (resolvedStorageSource_ != null) { - resolvedStorageSource_ = - com.google.cloudbuild.v1.StorageSource.newBuilder(resolvedStorageSource_) - .mergeFrom(value) - .buildPartial(); - } else { - resolvedStorageSource_ = value; - } - onChanged(); - } else { - resolvedStorageSourceBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * A copy of the build's `source.storage_source`, if exists, with any
-     * generations resolved.
-     * 
- * - * .google.devtools.cloudbuild.v1.StorageSource resolved_storage_source = 3; - */ - public Builder clearResolvedStorageSource() { - if (resolvedStorageSourceBuilder_ == null) { - resolvedStorageSource_ = null; - onChanged(); - } else { - resolvedStorageSource_ = null; - resolvedStorageSourceBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * A copy of the build's `source.storage_source`, if exists, with any
-     * generations resolved.
-     * 
- * - * .google.devtools.cloudbuild.v1.StorageSource resolved_storage_source = 3; - */ - public com.google.cloudbuild.v1.StorageSource.Builder getResolvedStorageSourceBuilder() { - - onChanged(); - return getResolvedStorageSourceFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * A copy of the build's `source.storage_source`, if exists, with any
-     * generations resolved.
-     * 
- * - * .google.devtools.cloudbuild.v1.StorageSource resolved_storage_source = 3; - */ - public com.google.cloudbuild.v1.StorageSourceOrBuilder getResolvedStorageSourceOrBuilder() { - if (resolvedStorageSourceBuilder_ != null) { - return resolvedStorageSourceBuilder_.getMessageOrBuilder(); - } else { - return resolvedStorageSource_ == null - ? com.google.cloudbuild.v1.StorageSource.getDefaultInstance() - : resolvedStorageSource_; - } - } - /** - * - * - *
-     * A copy of the build's `source.storage_source`, if exists, with any
-     * generations resolved.
-     * 
- * - * .google.devtools.cloudbuild.v1.StorageSource resolved_storage_source = 3; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.StorageSource, - com.google.cloudbuild.v1.StorageSource.Builder, - com.google.cloudbuild.v1.StorageSourceOrBuilder> - getResolvedStorageSourceFieldBuilder() { - if (resolvedStorageSourceBuilder_ == null) { - resolvedStorageSourceBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.StorageSource, - com.google.cloudbuild.v1.StorageSource.Builder, - com.google.cloudbuild.v1.StorageSourceOrBuilder>( - getResolvedStorageSource(), getParentForChildren(), isClean()); - resolvedStorageSource_ = null; - } - return resolvedStorageSourceBuilder_; - } - - private com.google.cloudbuild.v1.RepoSource resolvedRepoSource_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.RepoSource, - com.google.cloudbuild.v1.RepoSource.Builder, - com.google.cloudbuild.v1.RepoSourceOrBuilder> - resolvedRepoSourceBuilder_; - /** - * - * - *
-     * A copy of the build's `source.repo_source`, if exists, with any
-     * revisions resolved.
-     * 
- * - * .google.devtools.cloudbuild.v1.RepoSource resolved_repo_source = 6; - * - * @return Whether the resolvedRepoSource field is set. - */ - public boolean hasResolvedRepoSource() { - return resolvedRepoSourceBuilder_ != null || resolvedRepoSource_ != null; - } - /** - * - * - *
-     * A copy of the build's `source.repo_source`, if exists, with any
-     * revisions resolved.
-     * 
- * - * .google.devtools.cloudbuild.v1.RepoSource resolved_repo_source = 6; - * - * @return The resolvedRepoSource. - */ - public com.google.cloudbuild.v1.RepoSource getResolvedRepoSource() { - if (resolvedRepoSourceBuilder_ == null) { - return resolvedRepoSource_ == null - ? com.google.cloudbuild.v1.RepoSource.getDefaultInstance() - : resolvedRepoSource_; - } else { - return resolvedRepoSourceBuilder_.getMessage(); - } - } - /** - * - * - *
-     * A copy of the build's `source.repo_source`, if exists, with any
-     * revisions resolved.
-     * 
- * - * .google.devtools.cloudbuild.v1.RepoSource resolved_repo_source = 6; - */ - public Builder setResolvedRepoSource(com.google.cloudbuild.v1.RepoSource value) { - if (resolvedRepoSourceBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - resolvedRepoSource_ = value; - onChanged(); - } else { - resolvedRepoSourceBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * A copy of the build's `source.repo_source`, if exists, with any
-     * revisions resolved.
-     * 
- * - * .google.devtools.cloudbuild.v1.RepoSource resolved_repo_source = 6; - */ - public Builder setResolvedRepoSource( - com.google.cloudbuild.v1.RepoSource.Builder builderForValue) { - if (resolvedRepoSourceBuilder_ == null) { - resolvedRepoSource_ = builderForValue.build(); - onChanged(); - } else { - resolvedRepoSourceBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * A copy of the build's `source.repo_source`, if exists, with any
-     * revisions resolved.
-     * 
- * - * .google.devtools.cloudbuild.v1.RepoSource resolved_repo_source = 6; - */ - public Builder mergeResolvedRepoSource(com.google.cloudbuild.v1.RepoSource value) { - if (resolvedRepoSourceBuilder_ == null) { - if (resolvedRepoSource_ != null) { - resolvedRepoSource_ = - com.google.cloudbuild.v1.RepoSource.newBuilder(resolvedRepoSource_) - .mergeFrom(value) - .buildPartial(); - } else { - resolvedRepoSource_ = value; - } - onChanged(); - } else { - resolvedRepoSourceBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * A copy of the build's `source.repo_source`, if exists, with any
-     * revisions resolved.
-     * 
- * - * .google.devtools.cloudbuild.v1.RepoSource resolved_repo_source = 6; - */ - public Builder clearResolvedRepoSource() { - if (resolvedRepoSourceBuilder_ == null) { - resolvedRepoSource_ = null; - onChanged(); - } else { - resolvedRepoSource_ = null; - resolvedRepoSourceBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * A copy of the build's `source.repo_source`, if exists, with any
-     * revisions resolved.
-     * 
- * - * .google.devtools.cloudbuild.v1.RepoSource resolved_repo_source = 6; - */ - public com.google.cloudbuild.v1.RepoSource.Builder getResolvedRepoSourceBuilder() { - - onChanged(); - return getResolvedRepoSourceFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * A copy of the build's `source.repo_source`, if exists, with any
-     * revisions resolved.
-     * 
- * - * .google.devtools.cloudbuild.v1.RepoSource resolved_repo_source = 6; - */ - public com.google.cloudbuild.v1.RepoSourceOrBuilder getResolvedRepoSourceOrBuilder() { - if (resolvedRepoSourceBuilder_ != null) { - return resolvedRepoSourceBuilder_.getMessageOrBuilder(); - } else { - return resolvedRepoSource_ == null - ? com.google.cloudbuild.v1.RepoSource.getDefaultInstance() - : resolvedRepoSource_; - } - } - /** - * - * - *
-     * A copy of the build's `source.repo_source`, if exists, with any
-     * revisions resolved.
-     * 
- * - * .google.devtools.cloudbuild.v1.RepoSource resolved_repo_source = 6; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.RepoSource, - com.google.cloudbuild.v1.RepoSource.Builder, - com.google.cloudbuild.v1.RepoSourceOrBuilder> - getResolvedRepoSourceFieldBuilder() { - if (resolvedRepoSourceBuilder_ == null) { - resolvedRepoSourceBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.RepoSource, - com.google.cloudbuild.v1.RepoSource.Builder, - com.google.cloudbuild.v1.RepoSourceOrBuilder>( - getResolvedRepoSource(), getParentForChildren(), isClean()); - resolvedRepoSource_ = null; - } - return resolvedRepoSourceBuilder_; - } - - private com.google.cloudbuild.v1.StorageSourceManifest resolvedStorageSourceManifest_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.StorageSourceManifest, - com.google.cloudbuild.v1.StorageSourceManifest.Builder, - com.google.cloudbuild.v1.StorageSourceManifestOrBuilder> - resolvedStorageSourceManifestBuilder_; - /** - * - * - *
-     * A copy of the build's `source.storage_source_manifest`, if exists, with any
-     * revisions resolved.
-     * This feature is in Preview.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.StorageSourceManifest resolved_storage_source_manifest = 9; - * - * - * @return Whether the resolvedStorageSourceManifest field is set. - */ - public boolean hasResolvedStorageSourceManifest() { - return resolvedStorageSourceManifestBuilder_ != null - || resolvedStorageSourceManifest_ != null; - } - /** - * - * - *
-     * A copy of the build's `source.storage_source_manifest`, if exists, with any
-     * revisions resolved.
-     * This feature is in Preview.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.StorageSourceManifest resolved_storage_source_manifest = 9; - * - * - * @return The resolvedStorageSourceManifest. - */ - public com.google.cloudbuild.v1.StorageSourceManifest getResolvedStorageSourceManifest() { - if (resolvedStorageSourceManifestBuilder_ == null) { - return resolvedStorageSourceManifest_ == null - ? com.google.cloudbuild.v1.StorageSourceManifest.getDefaultInstance() - : resolvedStorageSourceManifest_; - } else { - return resolvedStorageSourceManifestBuilder_.getMessage(); - } - } - /** - * - * - *
-     * A copy of the build's `source.storage_source_manifest`, if exists, with any
-     * revisions resolved.
-     * This feature is in Preview.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.StorageSourceManifest resolved_storage_source_manifest = 9; - * - */ - public Builder setResolvedStorageSourceManifest( - com.google.cloudbuild.v1.StorageSourceManifest value) { - if (resolvedStorageSourceManifestBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - resolvedStorageSourceManifest_ = value; - onChanged(); - } else { - resolvedStorageSourceManifestBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * A copy of the build's `source.storage_source_manifest`, if exists, with any
-     * revisions resolved.
-     * This feature is in Preview.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.StorageSourceManifest resolved_storage_source_manifest = 9; - * - */ - public Builder setResolvedStorageSourceManifest( - com.google.cloudbuild.v1.StorageSourceManifest.Builder builderForValue) { - if (resolvedStorageSourceManifestBuilder_ == null) { - resolvedStorageSourceManifest_ = builderForValue.build(); - onChanged(); - } else { - resolvedStorageSourceManifestBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * A copy of the build's `source.storage_source_manifest`, if exists, with any
-     * revisions resolved.
-     * This feature is in Preview.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.StorageSourceManifest resolved_storage_source_manifest = 9; - * - */ - public Builder mergeResolvedStorageSourceManifest( - com.google.cloudbuild.v1.StorageSourceManifest value) { - if (resolvedStorageSourceManifestBuilder_ == null) { - if (resolvedStorageSourceManifest_ != null) { - resolvedStorageSourceManifest_ = - com.google.cloudbuild.v1.StorageSourceManifest.newBuilder( - resolvedStorageSourceManifest_) - .mergeFrom(value) - .buildPartial(); - } else { - resolvedStorageSourceManifest_ = value; - } - onChanged(); - } else { - resolvedStorageSourceManifestBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * A copy of the build's `source.storage_source_manifest`, if exists, with any
-     * revisions resolved.
-     * This feature is in Preview.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.StorageSourceManifest resolved_storage_source_manifest = 9; - * - */ - public Builder clearResolvedStorageSourceManifest() { - if (resolvedStorageSourceManifestBuilder_ == null) { - resolvedStorageSourceManifest_ = null; - onChanged(); - } else { - resolvedStorageSourceManifest_ = null; - resolvedStorageSourceManifestBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * A copy of the build's `source.storage_source_manifest`, if exists, with any
-     * revisions resolved.
-     * This feature is in Preview.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.StorageSourceManifest resolved_storage_source_manifest = 9; - * - */ - public com.google.cloudbuild.v1.StorageSourceManifest.Builder - getResolvedStorageSourceManifestBuilder() { - - onChanged(); - return getResolvedStorageSourceManifestFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * A copy of the build's `source.storage_source_manifest`, if exists, with any
-     * revisions resolved.
-     * This feature is in Preview.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.StorageSourceManifest resolved_storage_source_manifest = 9; - * - */ - public com.google.cloudbuild.v1.StorageSourceManifestOrBuilder - getResolvedStorageSourceManifestOrBuilder() { - if (resolvedStorageSourceManifestBuilder_ != null) { - return resolvedStorageSourceManifestBuilder_.getMessageOrBuilder(); - } else { - return resolvedStorageSourceManifest_ == null - ? com.google.cloudbuild.v1.StorageSourceManifest.getDefaultInstance() - : resolvedStorageSourceManifest_; - } - } - /** - * - * - *
-     * A copy of the build's `source.storage_source_manifest`, if exists, with any
-     * revisions resolved.
-     * This feature is in Preview.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.StorageSourceManifest resolved_storage_source_manifest = 9; - * - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.StorageSourceManifest, - com.google.cloudbuild.v1.StorageSourceManifest.Builder, - com.google.cloudbuild.v1.StorageSourceManifestOrBuilder> - getResolvedStorageSourceManifestFieldBuilder() { - if (resolvedStorageSourceManifestBuilder_ == null) { - resolvedStorageSourceManifestBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.StorageSourceManifest, - com.google.cloudbuild.v1.StorageSourceManifest.Builder, - com.google.cloudbuild.v1.StorageSourceManifestOrBuilder>( - getResolvedStorageSourceManifest(), getParentForChildren(), isClean()); - resolvedStorageSourceManifest_ = null; - } - return resolvedStorageSourceManifestBuilder_; - } - - private com.google.protobuf.MapField - fileHashes_; - - private com.google.protobuf.MapField - internalGetFileHashes() { - if (fileHashes_ == null) { - return com.google.protobuf.MapField.emptyMapField( - FileHashesDefaultEntryHolder.defaultEntry); - } - return fileHashes_; - } - - private com.google.protobuf.MapField - internalGetMutableFileHashes() { - onChanged(); - ; - if (fileHashes_ == null) { - fileHashes_ = - com.google.protobuf.MapField.newMapField(FileHashesDefaultEntryHolder.defaultEntry); - } - if (!fileHashes_.isMutable()) { - fileHashes_ = fileHashes_.copy(); - } - return fileHashes_; - } - - public int getFileHashesCount() { - return internalGetFileHashes().getMap().size(); - } - /** - * - * - *
-     * Output only. Hash(es) of the build source, which can be used to verify that
-     * the original source integrity was maintained in the build. Note that
-     * `FileHashes` will only be populated if `BuildOptions` has requested a
-     * `SourceProvenanceHash`.
-     * The keys to this map are file paths used as build source and the values
-     * contain the hash values for those files.
-     * If the build source came in a single package such as a gzipped tarfile
-     * (`.tar.gz`), the `FileHash` will be for the single path to that file.
-     * 
- * - * - * map<string, .google.devtools.cloudbuild.v1.FileHashes> file_hashes = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - @java.lang.Override - public boolean containsFileHashes(java.lang.String key) { - if (key == null) { - throw new NullPointerException("map key"); - } - return internalGetFileHashes().getMap().containsKey(key); - } - /** Use {@link #getFileHashesMap()} instead. */ - @java.lang.Override - @java.lang.Deprecated - public java.util.Map getFileHashes() { - return getFileHashesMap(); - } - /** - * - * - *
-     * Output only. Hash(es) of the build source, which can be used to verify that
-     * the original source integrity was maintained in the build. Note that
-     * `FileHashes` will only be populated if `BuildOptions` has requested a
-     * `SourceProvenanceHash`.
-     * The keys to this map are file paths used as build source and the values
-     * contain the hash values for those files.
-     * If the build source came in a single package such as a gzipped tarfile
-     * (`.tar.gz`), the `FileHash` will be for the single path to that file.
-     * 
- * - * - * map<string, .google.devtools.cloudbuild.v1.FileHashes> file_hashes = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - @java.lang.Override - public java.util.Map getFileHashesMap() { - return internalGetFileHashes().getMap(); - } - /** - * - * - *
-     * Output only. Hash(es) of the build source, which can be used to verify that
-     * the original source integrity was maintained in the build. Note that
-     * `FileHashes` will only be populated if `BuildOptions` has requested a
-     * `SourceProvenanceHash`.
-     * The keys to this map are file paths used as build source and the values
-     * contain the hash values for those files.
-     * If the build source came in a single package such as a gzipped tarfile
-     * (`.tar.gz`), the `FileHash` will be for the single path to that file.
-     * 
- * - * - * map<string, .google.devtools.cloudbuild.v1.FileHashes> file_hashes = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - @java.lang.Override - public com.google.cloudbuild.v1.FileHashes getFileHashesOrDefault( - java.lang.String key, com.google.cloudbuild.v1.FileHashes defaultValue) { - if (key == null) { - throw new NullPointerException("map key"); - } - java.util.Map map = - internalGetFileHashes().getMap(); - return map.containsKey(key) ? map.get(key) : defaultValue; - } - /** - * - * - *
-     * Output only. Hash(es) of the build source, which can be used to verify that
-     * the original source integrity was maintained in the build. Note that
-     * `FileHashes` will only be populated if `BuildOptions` has requested a
-     * `SourceProvenanceHash`.
-     * The keys to this map are file paths used as build source and the values
-     * contain the hash values for those files.
-     * If the build source came in a single package such as a gzipped tarfile
-     * (`.tar.gz`), the `FileHash` will be for the single path to that file.
-     * 
- * - * - * map<string, .google.devtools.cloudbuild.v1.FileHashes> file_hashes = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - @java.lang.Override - public com.google.cloudbuild.v1.FileHashes getFileHashesOrThrow(java.lang.String key) { - if (key == null) { - throw new NullPointerException("map key"); - } - java.util.Map map = - internalGetFileHashes().getMap(); - if (!map.containsKey(key)) { - throw new java.lang.IllegalArgumentException(); - } - return map.get(key); - } - - public Builder clearFileHashes() { - internalGetMutableFileHashes().getMutableMap().clear(); - return this; - } - /** - * - * - *
-     * Output only. Hash(es) of the build source, which can be used to verify that
-     * the original source integrity was maintained in the build. Note that
-     * `FileHashes` will only be populated if `BuildOptions` has requested a
-     * `SourceProvenanceHash`.
-     * The keys to this map are file paths used as build source and the values
-     * contain the hash values for those files.
-     * If the build source came in a single package such as a gzipped tarfile
-     * (`.tar.gz`), the `FileHash` will be for the single path to that file.
-     * 
- * - * - * map<string, .google.devtools.cloudbuild.v1.FileHashes> file_hashes = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder removeFileHashes(java.lang.String key) { - if (key == null) { - throw new NullPointerException("map key"); - } - internalGetMutableFileHashes().getMutableMap().remove(key); - return this; - } - /** Use alternate mutation accessors instead. */ - @java.lang.Deprecated - public java.util.Map - getMutableFileHashes() { - return internalGetMutableFileHashes().getMutableMap(); - } - /** - * - * - *
-     * Output only. Hash(es) of the build source, which can be used to verify that
-     * the original source integrity was maintained in the build. Note that
-     * `FileHashes` will only be populated if `BuildOptions` has requested a
-     * `SourceProvenanceHash`.
-     * The keys to this map are file paths used as build source and the values
-     * contain the hash values for those files.
-     * If the build source came in a single package such as a gzipped tarfile
-     * (`.tar.gz`), the `FileHash` will be for the single path to that file.
-     * 
- * - * - * map<string, .google.devtools.cloudbuild.v1.FileHashes> file_hashes = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder putFileHashes(java.lang.String key, com.google.cloudbuild.v1.FileHashes value) { - if (key == null) { - throw new NullPointerException("map key"); - } - if (value == null) { - throw new NullPointerException("map value"); - } - - internalGetMutableFileHashes().getMutableMap().put(key, value); - return this; - } - /** - * - * - *
-     * Output only. Hash(es) of the build source, which can be used to verify that
-     * the original source integrity was maintained in the build. Note that
-     * `FileHashes` will only be populated if `BuildOptions` has requested a
-     * `SourceProvenanceHash`.
-     * The keys to this map are file paths used as build source and the values
-     * contain the hash values for those files.
-     * If the build source came in a single package such as a gzipped tarfile
-     * (`.tar.gz`), the `FileHash` will be for the single path to that file.
-     * 
- * - * - * map<string, .google.devtools.cloudbuild.v1.FileHashes> file_hashes = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder putAllFileHashes( - java.util.Map values) { - internalGetMutableFileHashes().getMutableMap().putAll(values); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.SourceProvenance) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.SourceProvenance) - private static final com.google.cloudbuild.v1.SourceProvenance DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.SourceProvenance(); - } - - public static com.google.cloudbuild.v1.SourceProvenance getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public SourceProvenance parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.SourceProvenance getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/SourceProvenanceOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/SourceProvenanceOrBuilder.java deleted file mode 100644 index 940a6141..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/SourceProvenanceOrBuilder.java +++ /dev/null @@ -1,253 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface SourceProvenanceOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.SourceProvenance) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * A copy of the build's `source.storage_source`, if exists, with any
-   * generations resolved.
-   * 
- * - * .google.devtools.cloudbuild.v1.StorageSource resolved_storage_source = 3; - * - * @return Whether the resolvedStorageSource field is set. - */ - boolean hasResolvedStorageSource(); - /** - * - * - *
-   * A copy of the build's `source.storage_source`, if exists, with any
-   * generations resolved.
-   * 
- * - * .google.devtools.cloudbuild.v1.StorageSource resolved_storage_source = 3; - * - * @return The resolvedStorageSource. - */ - com.google.cloudbuild.v1.StorageSource getResolvedStorageSource(); - /** - * - * - *
-   * A copy of the build's `source.storage_source`, if exists, with any
-   * generations resolved.
-   * 
- * - * .google.devtools.cloudbuild.v1.StorageSource resolved_storage_source = 3; - */ - com.google.cloudbuild.v1.StorageSourceOrBuilder getResolvedStorageSourceOrBuilder(); - - /** - * - * - *
-   * A copy of the build's `source.repo_source`, if exists, with any
-   * revisions resolved.
-   * 
- * - * .google.devtools.cloudbuild.v1.RepoSource resolved_repo_source = 6; - * - * @return Whether the resolvedRepoSource field is set. - */ - boolean hasResolvedRepoSource(); - /** - * - * - *
-   * A copy of the build's `source.repo_source`, if exists, with any
-   * revisions resolved.
-   * 
- * - * .google.devtools.cloudbuild.v1.RepoSource resolved_repo_source = 6; - * - * @return The resolvedRepoSource. - */ - com.google.cloudbuild.v1.RepoSource getResolvedRepoSource(); - /** - * - * - *
-   * A copy of the build's `source.repo_source`, if exists, with any
-   * revisions resolved.
-   * 
- * - * .google.devtools.cloudbuild.v1.RepoSource resolved_repo_source = 6; - */ - com.google.cloudbuild.v1.RepoSourceOrBuilder getResolvedRepoSourceOrBuilder(); - - /** - * - * - *
-   * A copy of the build's `source.storage_source_manifest`, if exists, with any
-   * revisions resolved.
-   * This feature is in Preview.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.StorageSourceManifest resolved_storage_source_manifest = 9; - * - * - * @return Whether the resolvedStorageSourceManifest field is set. - */ - boolean hasResolvedStorageSourceManifest(); - /** - * - * - *
-   * A copy of the build's `source.storage_source_manifest`, if exists, with any
-   * revisions resolved.
-   * This feature is in Preview.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.StorageSourceManifest resolved_storage_source_manifest = 9; - * - * - * @return The resolvedStorageSourceManifest. - */ - com.google.cloudbuild.v1.StorageSourceManifest getResolvedStorageSourceManifest(); - /** - * - * - *
-   * A copy of the build's `source.storage_source_manifest`, if exists, with any
-   * revisions resolved.
-   * This feature is in Preview.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.StorageSourceManifest resolved_storage_source_manifest = 9; - * - */ - com.google.cloudbuild.v1.StorageSourceManifestOrBuilder - getResolvedStorageSourceManifestOrBuilder(); - - /** - * - * - *
-   * Output only. Hash(es) of the build source, which can be used to verify that
-   * the original source integrity was maintained in the build. Note that
-   * `FileHashes` will only be populated if `BuildOptions` has requested a
-   * `SourceProvenanceHash`.
-   * The keys to this map are file paths used as build source and the values
-   * contain the hash values for those files.
-   * If the build source came in a single package such as a gzipped tarfile
-   * (`.tar.gz`), the `FileHash` will be for the single path to that file.
-   * 
- * - * - * map<string, .google.devtools.cloudbuild.v1.FileHashes> file_hashes = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - int getFileHashesCount(); - /** - * - * - *
-   * Output only. Hash(es) of the build source, which can be used to verify that
-   * the original source integrity was maintained in the build. Note that
-   * `FileHashes` will only be populated if `BuildOptions` has requested a
-   * `SourceProvenanceHash`.
-   * The keys to this map are file paths used as build source and the values
-   * contain the hash values for those files.
-   * If the build source came in a single package such as a gzipped tarfile
-   * (`.tar.gz`), the `FileHash` will be for the single path to that file.
-   * 
- * - * - * map<string, .google.devtools.cloudbuild.v1.FileHashes> file_hashes = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - boolean containsFileHashes(java.lang.String key); - /** Use {@link #getFileHashesMap()} instead. */ - @java.lang.Deprecated - java.util.Map getFileHashes(); - /** - * - * - *
-   * Output only. Hash(es) of the build source, which can be used to verify that
-   * the original source integrity was maintained in the build. Note that
-   * `FileHashes` will only be populated if `BuildOptions` has requested a
-   * `SourceProvenanceHash`.
-   * The keys to this map are file paths used as build source and the values
-   * contain the hash values for those files.
-   * If the build source came in a single package such as a gzipped tarfile
-   * (`.tar.gz`), the `FileHash` will be for the single path to that file.
-   * 
- * - * - * map<string, .google.devtools.cloudbuild.v1.FileHashes> file_hashes = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - java.util.Map getFileHashesMap(); - /** - * - * - *
-   * Output only. Hash(es) of the build source, which can be used to verify that
-   * the original source integrity was maintained in the build. Note that
-   * `FileHashes` will only be populated if `BuildOptions` has requested a
-   * `SourceProvenanceHash`.
-   * The keys to this map are file paths used as build source and the values
-   * contain the hash values for those files.
-   * If the build source came in a single package such as a gzipped tarfile
-   * (`.tar.gz`), the `FileHash` will be for the single path to that file.
-   * 
- * - * - * map<string, .google.devtools.cloudbuild.v1.FileHashes> file_hashes = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - - /* nullable */ - com.google.cloudbuild.v1.FileHashes getFileHashesOrDefault( - java.lang.String key, - /* nullable */ - com.google.cloudbuild.v1.FileHashes defaultValue); - /** - * - * - *
-   * Output only. Hash(es) of the build source, which can be used to verify that
-   * the original source integrity was maintained in the build. Note that
-   * `FileHashes` will only be populated if `BuildOptions` has requested a
-   * `SourceProvenanceHash`.
-   * The keys to this map are file paths used as build source and the values
-   * contain the hash values for those files.
-   * If the build source came in a single package such as a gzipped tarfile
-   * (`.tar.gz`), the `FileHash` will be for the single path to that file.
-   * 
- * - * - * map<string, .google.devtools.cloudbuild.v1.FileHashes> file_hashes = 4 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - com.google.cloudbuild.v1.FileHashes getFileHashesOrThrow(java.lang.String key); -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/StorageSource.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/StorageSource.java deleted file mode 100644 index 10190454..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/StorageSource.java +++ /dev/null @@ -1,914 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * Location of the source in an archive file in Google Cloud Storage.
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.StorageSource} - */ -public final class StorageSource extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.StorageSource) - StorageSourceOrBuilder { - private static final long serialVersionUID = 0L; - // Use StorageSource.newBuilder() to construct. - private StorageSource(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private StorageSource() { - bucket_ = ""; - object_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new StorageSource(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_StorageSource_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_StorageSource_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.StorageSource.class, - com.google.cloudbuild.v1.StorageSource.Builder.class); - } - - public static final int BUCKET_FIELD_NUMBER = 1; - private volatile java.lang.Object bucket_; - /** - * - * - *
-   * Google Cloud Storage bucket containing the source (see
-   * [Bucket Name
-   * Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)).
-   * 
- * - * string bucket = 1; - * - * @return The bucket. - */ - @java.lang.Override - public java.lang.String getBucket() { - java.lang.Object ref = bucket_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - bucket_ = s; - return s; - } - } - /** - * - * - *
-   * Google Cloud Storage bucket containing the source (see
-   * [Bucket Name
-   * Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)).
-   * 
- * - * string bucket = 1; - * - * @return The bytes for bucket. - */ - @java.lang.Override - public com.google.protobuf.ByteString getBucketBytes() { - java.lang.Object ref = bucket_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - bucket_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int OBJECT_FIELD_NUMBER = 2; - private volatile java.lang.Object object_; - /** - * - * - *
-   * Google Cloud Storage object containing the source.
-   * This object must be a gzipped archive file (`.tar.gz`) containing source to
-   * build.
-   * 
- * - * string object = 2; - * - * @return The object. - */ - @java.lang.Override - public java.lang.String getObject() { - java.lang.Object ref = object_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - object_ = s; - return s; - } - } - /** - * - * - *
-   * Google Cloud Storage object containing the source.
-   * This object must be a gzipped archive file (`.tar.gz`) containing source to
-   * build.
-   * 
- * - * string object = 2; - * - * @return The bytes for object. - */ - @java.lang.Override - public com.google.protobuf.ByteString getObjectBytes() { - java.lang.Object ref = object_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - object_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int GENERATION_FIELD_NUMBER = 3; - private long generation_; - /** - * - * - *
-   * Google Cloud Storage generation for the object. If the generation is
-   * omitted, the latest generation will be used.
-   * 
- * - * int64 generation = 3; - * - * @return The generation. - */ - @java.lang.Override - public long getGeneration() { - return generation_; - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(bucket_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, bucket_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(object_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, object_); - } - if (generation_ != 0L) { - output.writeInt64(3, generation_); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(bucket_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, bucket_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(object_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, object_); - } - if (generation_ != 0L) { - size += com.google.protobuf.CodedOutputStream.computeInt64Size(3, generation_); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.StorageSource)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.StorageSource other = (com.google.cloudbuild.v1.StorageSource) obj; - - if (!getBucket().equals(other.getBucket())) return false; - if (!getObject().equals(other.getObject())) return false; - if (getGeneration() != other.getGeneration()) return false; - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + BUCKET_FIELD_NUMBER; - hash = (53 * hash) + getBucket().hashCode(); - hash = (37 * hash) + OBJECT_FIELD_NUMBER; - hash = (53 * hash) + getObject().hashCode(); - hash = (37 * hash) + GENERATION_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getGeneration()); - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.StorageSource parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.StorageSource parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.StorageSource parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.StorageSource parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.StorageSource parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.StorageSource parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.StorageSource parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.StorageSource parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.StorageSource parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.StorageSource parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.StorageSource parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.StorageSource parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.StorageSource prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * Location of the source in an archive file in Google Cloud Storage.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.StorageSource} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.StorageSource) - com.google.cloudbuild.v1.StorageSourceOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_StorageSource_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_StorageSource_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.StorageSource.class, - com.google.cloudbuild.v1.StorageSource.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.StorageSource.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - bucket_ = ""; - - object_ = ""; - - generation_ = 0L; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_StorageSource_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.StorageSource getDefaultInstanceForType() { - return com.google.cloudbuild.v1.StorageSource.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.StorageSource build() { - com.google.cloudbuild.v1.StorageSource result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.StorageSource buildPartial() { - com.google.cloudbuild.v1.StorageSource result = - new com.google.cloudbuild.v1.StorageSource(this); - result.bucket_ = bucket_; - result.object_ = object_; - result.generation_ = generation_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.StorageSource) { - return mergeFrom((com.google.cloudbuild.v1.StorageSource) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.StorageSource other) { - if (other == com.google.cloudbuild.v1.StorageSource.getDefaultInstance()) return this; - if (!other.getBucket().isEmpty()) { - bucket_ = other.bucket_; - onChanged(); - } - if (!other.getObject().isEmpty()) { - object_ = other.object_; - onChanged(); - } - if (other.getGeneration() != 0L) { - setGeneration(other.getGeneration()); - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - bucket_ = input.readStringRequireUtf8(); - - break; - } // case 10 - case 18: - { - object_ = input.readStringRequireUtf8(); - - break; - } // case 18 - case 24: - { - generation_ = input.readInt64(); - - break; - } // case 24 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private java.lang.Object bucket_ = ""; - /** - * - * - *
-     * Google Cloud Storage bucket containing the source (see
-     * [Bucket Name
-     * Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)).
-     * 
- * - * string bucket = 1; - * - * @return The bucket. - */ - public java.lang.String getBucket() { - java.lang.Object ref = bucket_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - bucket_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Google Cloud Storage bucket containing the source (see
-     * [Bucket Name
-     * Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)).
-     * 
- * - * string bucket = 1; - * - * @return The bytes for bucket. - */ - public com.google.protobuf.ByteString getBucketBytes() { - java.lang.Object ref = bucket_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - bucket_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Google Cloud Storage bucket containing the source (see
-     * [Bucket Name
-     * Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)).
-     * 
- * - * string bucket = 1; - * - * @param value The bucket to set. - * @return This builder for chaining. - */ - public Builder setBucket(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - bucket_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Google Cloud Storage bucket containing the source (see
-     * [Bucket Name
-     * Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)).
-     * 
- * - * string bucket = 1; - * - * @return This builder for chaining. - */ - public Builder clearBucket() { - - bucket_ = getDefaultInstance().getBucket(); - onChanged(); - return this; - } - /** - * - * - *
-     * Google Cloud Storage bucket containing the source (see
-     * [Bucket Name
-     * Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)).
-     * 
- * - * string bucket = 1; - * - * @param value The bytes for bucket to set. - * @return This builder for chaining. - */ - public Builder setBucketBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - bucket_ = value; - onChanged(); - return this; - } - - private java.lang.Object object_ = ""; - /** - * - * - *
-     * Google Cloud Storage object containing the source.
-     * This object must be a gzipped archive file (`.tar.gz`) containing source to
-     * build.
-     * 
- * - * string object = 2; - * - * @return The object. - */ - public java.lang.String getObject() { - java.lang.Object ref = object_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - object_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Google Cloud Storage object containing the source.
-     * This object must be a gzipped archive file (`.tar.gz`) containing source to
-     * build.
-     * 
- * - * string object = 2; - * - * @return The bytes for object. - */ - public com.google.protobuf.ByteString getObjectBytes() { - java.lang.Object ref = object_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - object_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Google Cloud Storage object containing the source.
-     * This object must be a gzipped archive file (`.tar.gz`) containing source to
-     * build.
-     * 
- * - * string object = 2; - * - * @param value The object to set. - * @return This builder for chaining. - */ - public Builder setObject(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - object_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Google Cloud Storage object containing the source.
-     * This object must be a gzipped archive file (`.tar.gz`) containing source to
-     * build.
-     * 
- * - * string object = 2; - * - * @return This builder for chaining. - */ - public Builder clearObject() { - - object_ = getDefaultInstance().getObject(); - onChanged(); - return this; - } - /** - * - * - *
-     * Google Cloud Storage object containing the source.
-     * This object must be a gzipped archive file (`.tar.gz`) containing source to
-     * build.
-     * 
- * - * string object = 2; - * - * @param value The bytes for object to set. - * @return This builder for chaining. - */ - public Builder setObjectBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - object_ = value; - onChanged(); - return this; - } - - private long generation_; - /** - * - * - *
-     * Google Cloud Storage generation for the object. If the generation is
-     * omitted, the latest generation will be used.
-     * 
- * - * int64 generation = 3; - * - * @return The generation. - */ - @java.lang.Override - public long getGeneration() { - return generation_; - } - /** - * - * - *
-     * Google Cloud Storage generation for the object. If the generation is
-     * omitted, the latest generation will be used.
-     * 
- * - * int64 generation = 3; - * - * @param value The generation to set. - * @return This builder for chaining. - */ - public Builder setGeneration(long value) { - - generation_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Google Cloud Storage generation for the object. If the generation is
-     * omitted, the latest generation will be used.
-     * 
- * - * int64 generation = 3; - * - * @return This builder for chaining. - */ - public Builder clearGeneration() { - - generation_ = 0L; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.StorageSource) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.StorageSource) - private static final com.google.cloudbuild.v1.StorageSource DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.StorageSource(); - } - - public static com.google.cloudbuild.v1.StorageSource getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public StorageSource parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.StorageSource getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/StorageSourceManifest.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/StorageSourceManifest.java deleted file mode 100644 index 759ecdf3..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/StorageSourceManifest.java +++ /dev/null @@ -1,912 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * Location of the source manifest in Google Cloud Storage.
- * This feature is in Preview; see description
- * [here](https://github.com/GoogleCloudPlatform/cloud-builders/tree/master/gcs-fetcher).
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.StorageSourceManifest} - */ -public final class StorageSourceManifest extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.StorageSourceManifest) - StorageSourceManifestOrBuilder { - private static final long serialVersionUID = 0L; - // Use StorageSourceManifest.newBuilder() to construct. - private StorageSourceManifest(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private StorageSourceManifest() { - bucket_ = ""; - object_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new StorageSourceManifest(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_StorageSourceManifest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_StorageSourceManifest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.StorageSourceManifest.class, - com.google.cloudbuild.v1.StorageSourceManifest.Builder.class); - } - - public static final int BUCKET_FIELD_NUMBER = 1; - private volatile java.lang.Object bucket_; - /** - * - * - *
-   * Google Cloud Storage bucket containing the source manifest (see [Bucket
-   * Name
-   * Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)).
-   * 
- * - * string bucket = 1; - * - * @return The bucket. - */ - @java.lang.Override - public java.lang.String getBucket() { - java.lang.Object ref = bucket_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - bucket_ = s; - return s; - } - } - /** - * - * - *
-   * Google Cloud Storage bucket containing the source manifest (see [Bucket
-   * Name
-   * Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)).
-   * 
- * - * string bucket = 1; - * - * @return The bytes for bucket. - */ - @java.lang.Override - public com.google.protobuf.ByteString getBucketBytes() { - java.lang.Object ref = bucket_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - bucket_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int OBJECT_FIELD_NUMBER = 2; - private volatile java.lang.Object object_; - /** - * - * - *
-   * Google Cloud Storage object containing the source manifest.
-   * This object must be a JSON file.
-   * 
- * - * string object = 2; - * - * @return The object. - */ - @java.lang.Override - public java.lang.String getObject() { - java.lang.Object ref = object_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - object_ = s; - return s; - } - } - /** - * - * - *
-   * Google Cloud Storage object containing the source manifest.
-   * This object must be a JSON file.
-   * 
- * - * string object = 2; - * - * @return The bytes for object. - */ - @java.lang.Override - public com.google.protobuf.ByteString getObjectBytes() { - java.lang.Object ref = object_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - object_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int GENERATION_FIELD_NUMBER = 3; - private long generation_; - /** - * - * - *
-   * Google Cloud Storage generation for the object. If the generation is
-   * omitted, the latest generation will be used.
-   * 
- * - * int64 generation = 3; - * - * @return The generation. - */ - @java.lang.Override - public long getGeneration() { - return generation_; - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(bucket_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, bucket_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(object_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, object_); - } - if (generation_ != 0L) { - output.writeInt64(3, generation_); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(bucket_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, bucket_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(object_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, object_); - } - if (generation_ != 0L) { - size += com.google.protobuf.CodedOutputStream.computeInt64Size(3, generation_); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.StorageSourceManifest)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.StorageSourceManifest other = - (com.google.cloudbuild.v1.StorageSourceManifest) obj; - - if (!getBucket().equals(other.getBucket())) return false; - if (!getObject().equals(other.getObject())) return false; - if (getGeneration() != other.getGeneration()) return false; - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + BUCKET_FIELD_NUMBER; - hash = (53 * hash) + getBucket().hashCode(); - hash = (37 * hash) + OBJECT_FIELD_NUMBER; - hash = (53 * hash) + getObject().hashCode(); - hash = (37 * hash) + GENERATION_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashLong(getGeneration()); - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.StorageSourceManifest parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.StorageSourceManifest parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.StorageSourceManifest parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.StorageSourceManifest parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.StorageSourceManifest parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.StorageSourceManifest parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.StorageSourceManifest parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.StorageSourceManifest parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.StorageSourceManifest parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.StorageSourceManifest parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.StorageSourceManifest parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.StorageSourceManifest parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.StorageSourceManifest prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * Location of the source manifest in Google Cloud Storage.
-   * This feature is in Preview; see description
-   * [here](https://github.com/GoogleCloudPlatform/cloud-builders/tree/master/gcs-fetcher).
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.StorageSourceManifest} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.StorageSourceManifest) - com.google.cloudbuild.v1.StorageSourceManifestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_StorageSourceManifest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_StorageSourceManifest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.StorageSourceManifest.class, - com.google.cloudbuild.v1.StorageSourceManifest.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.StorageSourceManifest.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - bucket_ = ""; - - object_ = ""; - - generation_ = 0L; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_StorageSourceManifest_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.StorageSourceManifest getDefaultInstanceForType() { - return com.google.cloudbuild.v1.StorageSourceManifest.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.StorageSourceManifest build() { - com.google.cloudbuild.v1.StorageSourceManifest result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.StorageSourceManifest buildPartial() { - com.google.cloudbuild.v1.StorageSourceManifest result = - new com.google.cloudbuild.v1.StorageSourceManifest(this); - result.bucket_ = bucket_; - result.object_ = object_; - result.generation_ = generation_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.StorageSourceManifest) { - return mergeFrom((com.google.cloudbuild.v1.StorageSourceManifest) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.StorageSourceManifest other) { - if (other == com.google.cloudbuild.v1.StorageSourceManifest.getDefaultInstance()) return this; - if (!other.getBucket().isEmpty()) { - bucket_ = other.bucket_; - onChanged(); - } - if (!other.getObject().isEmpty()) { - object_ = other.object_; - onChanged(); - } - if (other.getGeneration() != 0L) { - setGeneration(other.getGeneration()); - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - bucket_ = input.readStringRequireUtf8(); - - break; - } // case 10 - case 18: - { - object_ = input.readStringRequireUtf8(); - - break; - } // case 18 - case 24: - { - generation_ = input.readInt64(); - - break; - } // case 24 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private java.lang.Object bucket_ = ""; - /** - * - * - *
-     * Google Cloud Storage bucket containing the source manifest (see [Bucket
-     * Name
-     * Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)).
-     * 
- * - * string bucket = 1; - * - * @return The bucket. - */ - public java.lang.String getBucket() { - java.lang.Object ref = bucket_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - bucket_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Google Cloud Storage bucket containing the source manifest (see [Bucket
-     * Name
-     * Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)).
-     * 
- * - * string bucket = 1; - * - * @return The bytes for bucket. - */ - public com.google.protobuf.ByteString getBucketBytes() { - java.lang.Object ref = bucket_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - bucket_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Google Cloud Storage bucket containing the source manifest (see [Bucket
-     * Name
-     * Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)).
-     * 
- * - * string bucket = 1; - * - * @param value The bucket to set. - * @return This builder for chaining. - */ - public Builder setBucket(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - bucket_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Google Cloud Storage bucket containing the source manifest (see [Bucket
-     * Name
-     * Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)).
-     * 
- * - * string bucket = 1; - * - * @return This builder for chaining. - */ - public Builder clearBucket() { - - bucket_ = getDefaultInstance().getBucket(); - onChanged(); - return this; - } - /** - * - * - *
-     * Google Cloud Storage bucket containing the source manifest (see [Bucket
-     * Name
-     * Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)).
-     * 
- * - * string bucket = 1; - * - * @param value The bytes for bucket to set. - * @return This builder for chaining. - */ - public Builder setBucketBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - bucket_ = value; - onChanged(); - return this; - } - - private java.lang.Object object_ = ""; - /** - * - * - *
-     * Google Cloud Storage object containing the source manifest.
-     * This object must be a JSON file.
-     * 
- * - * string object = 2; - * - * @return The object. - */ - public java.lang.String getObject() { - java.lang.Object ref = object_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - object_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Google Cloud Storage object containing the source manifest.
-     * This object must be a JSON file.
-     * 
- * - * string object = 2; - * - * @return The bytes for object. - */ - public com.google.protobuf.ByteString getObjectBytes() { - java.lang.Object ref = object_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - object_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Google Cloud Storage object containing the source manifest.
-     * This object must be a JSON file.
-     * 
- * - * string object = 2; - * - * @param value The object to set. - * @return This builder for chaining. - */ - public Builder setObject(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - object_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Google Cloud Storage object containing the source manifest.
-     * This object must be a JSON file.
-     * 
- * - * string object = 2; - * - * @return This builder for chaining. - */ - public Builder clearObject() { - - object_ = getDefaultInstance().getObject(); - onChanged(); - return this; - } - /** - * - * - *
-     * Google Cloud Storage object containing the source manifest.
-     * This object must be a JSON file.
-     * 
- * - * string object = 2; - * - * @param value The bytes for object to set. - * @return This builder for chaining. - */ - public Builder setObjectBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - object_ = value; - onChanged(); - return this; - } - - private long generation_; - /** - * - * - *
-     * Google Cloud Storage generation for the object. If the generation is
-     * omitted, the latest generation will be used.
-     * 
- * - * int64 generation = 3; - * - * @return The generation. - */ - @java.lang.Override - public long getGeneration() { - return generation_; - } - /** - * - * - *
-     * Google Cloud Storage generation for the object. If the generation is
-     * omitted, the latest generation will be used.
-     * 
- * - * int64 generation = 3; - * - * @param value The generation to set. - * @return This builder for chaining. - */ - public Builder setGeneration(long value) { - - generation_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Google Cloud Storage generation for the object. If the generation is
-     * omitted, the latest generation will be used.
-     * 
- * - * int64 generation = 3; - * - * @return This builder for chaining. - */ - public Builder clearGeneration() { - - generation_ = 0L; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.StorageSourceManifest) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.StorageSourceManifest) - private static final com.google.cloudbuild.v1.StorageSourceManifest DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.StorageSourceManifest(); - } - - public static com.google.cloudbuild.v1.StorageSourceManifest getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public StorageSourceManifest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.StorageSourceManifest getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/StorageSourceManifestOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/StorageSourceManifestOrBuilder.java deleted file mode 100644 index 888b554e..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/StorageSourceManifestOrBuilder.java +++ /dev/null @@ -1,95 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface StorageSourceManifestOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.StorageSourceManifest) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * Google Cloud Storage bucket containing the source manifest (see [Bucket
-   * Name
-   * Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)).
-   * 
- * - * string bucket = 1; - * - * @return The bucket. - */ - java.lang.String getBucket(); - /** - * - * - *
-   * Google Cloud Storage bucket containing the source manifest (see [Bucket
-   * Name
-   * Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)).
-   * 
- * - * string bucket = 1; - * - * @return The bytes for bucket. - */ - com.google.protobuf.ByteString getBucketBytes(); - - /** - * - * - *
-   * Google Cloud Storage object containing the source manifest.
-   * This object must be a JSON file.
-   * 
- * - * string object = 2; - * - * @return The object. - */ - java.lang.String getObject(); - /** - * - * - *
-   * Google Cloud Storage object containing the source manifest.
-   * This object must be a JSON file.
-   * 
- * - * string object = 2; - * - * @return The bytes for object. - */ - com.google.protobuf.ByteString getObjectBytes(); - - /** - * - * - *
-   * Google Cloud Storage generation for the object. If the generation is
-   * omitted, the latest generation will be used.
-   * 
- * - * int64 generation = 3; - * - * @return The generation. - */ - long getGeneration(); -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/StorageSourceOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/StorageSourceOrBuilder.java deleted file mode 100644 index 1b0a93c5..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/StorageSourceOrBuilder.java +++ /dev/null @@ -1,97 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface StorageSourceOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.StorageSource) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * Google Cloud Storage bucket containing the source (see
-   * [Bucket Name
-   * Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)).
-   * 
- * - * string bucket = 1; - * - * @return The bucket. - */ - java.lang.String getBucket(); - /** - * - * - *
-   * Google Cloud Storage bucket containing the source (see
-   * [Bucket Name
-   * Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)).
-   * 
- * - * string bucket = 1; - * - * @return The bytes for bucket. - */ - com.google.protobuf.ByteString getBucketBytes(); - - /** - * - * - *
-   * Google Cloud Storage object containing the source.
-   * This object must be a gzipped archive file (`.tar.gz`) containing source to
-   * build.
-   * 
- * - * string object = 2; - * - * @return The object. - */ - java.lang.String getObject(); - /** - * - * - *
-   * Google Cloud Storage object containing the source.
-   * This object must be a gzipped archive file (`.tar.gz`) containing source to
-   * build.
-   * 
- * - * string object = 2; - * - * @return The bytes for object. - */ - com.google.protobuf.ByteString getObjectBytes(); - - /** - * - * - *
-   * Google Cloud Storage generation for the object. If the generation is
-   * omitted, the latest generation will be used.
-   * 
- * - * int64 generation = 3; - * - * @return The generation. - */ - long getGeneration(); -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/TimeSpan.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/TimeSpan.java deleted file mode 100644 index 6cb27f99..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/TimeSpan.java +++ /dev/null @@ -1,950 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * Start and end times for a build execution phase.
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.TimeSpan} - */ -public final class TimeSpan extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.TimeSpan) - TimeSpanOrBuilder { - private static final long serialVersionUID = 0L; - // Use TimeSpan.newBuilder() to construct. - private TimeSpan(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private TimeSpan() {} - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new TimeSpan(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_TimeSpan_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_TimeSpan_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.TimeSpan.class, - com.google.cloudbuild.v1.TimeSpan.Builder.class); - } - - public static final int START_TIME_FIELD_NUMBER = 1; - private com.google.protobuf.Timestamp startTime_; - /** - * - * - *
-   * Start of time span.
-   * 
- * - * .google.protobuf.Timestamp start_time = 1; - * - * @return Whether the startTime field is set. - */ - @java.lang.Override - public boolean hasStartTime() { - return startTime_ != null; - } - /** - * - * - *
-   * Start of time span.
-   * 
- * - * .google.protobuf.Timestamp start_time = 1; - * - * @return The startTime. - */ - @java.lang.Override - public com.google.protobuf.Timestamp getStartTime() { - return startTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : startTime_; - } - /** - * - * - *
-   * Start of time span.
-   * 
- * - * .google.protobuf.Timestamp start_time = 1; - */ - @java.lang.Override - public com.google.protobuf.TimestampOrBuilder getStartTimeOrBuilder() { - return getStartTime(); - } - - public static final int END_TIME_FIELD_NUMBER = 2; - private com.google.protobuf.Timestamp endTime_; - /** - * - * - *
-   * End of time span.
-   * 
- * - * .google.protobuf.Timestamp end_time = 2; - * - * @return Whether the endTime field is set. - */ - @java.lang.Override - public boolean hasEndTime() { - return endTime_ != null; - } - /** - * - * - *
-   * End of time span.
-   * 
- * - * .google.protobuf.Timestamp end_time = 2; - * - * @return The endTime. - */ - @java.lang.Override - public com.google.protobuf.Timestamp getEndTime() { - return endTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : endTime_; - } - /** - * - * - *
-   * End of time span.
-   * 
- * - * .google.protobuf.Timestamp end_time = 2; - */ - @java.lang.Override - public com.google.protobuf.TimestampOrBuilder getEndTimeOrBuilder() { - return getEndTime(); - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (startTime_ != null) { - output.writeMessage(1, getStartTime()); - } - if (endTime_ != null) { - output.writeMessage(2, getEndTime()); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (startTime_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getStartTime()); - } - if (endTime_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getEndTime()); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.TimeSpan)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.TimeSpan other = (com.google.cloudbuild.v1.TimeSpan) obj; - - if (hasStartTime() != other.hasStartTime()) return false; - if (hasStartTime()) { - if (!getStartTime().equals(other.getStartTime())) return false; - } - if (hasEndTime() != other.hasEndTime()) return false; - if (hasEndTime()) { - if (!getEndTime().equals(other.getEndTime())) return false; - } - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasStartTime()) { - hash = (37 * hash) + START_TIME_FIELD_NUMBER; - hash = (53 * hash) + getStartTime().hashCode(); - } - if (hasEndTime()) { - hash = (37 * hash) + END_TIME_FIELD_NUMBER; - hash = (53 * hash) + getEndTime().hashCode(); - } - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.TimeSpan parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.TimeSpan parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.TimeSpan parseFrom(com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.TimeSpan parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.TimeSpan parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.TimeSpan parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.TimeSpan parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.TimeSpan parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.TimeSpan parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.TimeSpan parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.TimeSpan parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.TimeSpan parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.TimeSpan prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * Start and end times for a build execution phase.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.TimeSpan} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.TimeSpan) - com.google.cloudbuild.v1.TimeSpanOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_TimeSpan_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_TimeSpan_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.TimeSpan.class, - com.google.cloudbuild.v1.TimeSpan.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.TimeSpan.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - if (startTimeBuilder_ == null) { - startTime_ = null; - } else { - startTime_ = null; - startTimeBuilder_ = null; - } - if (endTimeBuilder_ == null) { - endTime_ = null; - } else { - endTime_ = null; - endTimeBuilder_ = null; - } - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_TimeSpan_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.TimeSpan getDefaultInstanceForType() { - return com.google.cloudbuild.v1.TimeSpan.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.TimeSpan build() { - com.google.cloudbuild.v1.TimeSpan result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.TimeSpan buildPartial() { - com.google.cloudbuild.v1.TimeSpan result = new com.google.cloudbuild.v1.TimeSpan(this); - if (startTimeBuilder_ == null) { - result.startTime_ = startTime_; - } else { - result.startTime_ = startTimeBuilder_.build(); - } - if (endTimeBuilder_ == null) { - result.endTime_ = endTime_; - } else { - result.endTime_ = endTimeBuilder_.build(); - } - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.TimeSpan) { - return mergeFrom((com.google.cloudbuild.v1.TimeSpan) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.TimeSpan other) { - if (other == com.google.cloudbuild.v1.TimeSpan.getDefaultInstance()) return this; - if (other.hasStartTime()) { - mergeStartTime(other.getStartTime()); - } - if (other.hasEndTime()) { - mergeEndTime(other.getEndTime()); - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - input.readMessage(getStartTimeFieldBuilder().getBuilder(), extensionRegistry); - - break; - } // case 10 - case 18: - { - input.readMessage(getEndTimeFieldBuilder().getBuilder(), extensionRegistry); - - break; - } // case 18 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private com.google.protobuf.Timestamp startTime_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - startTimeBuilder_; - /** - * - * - *
-     * Start of time span.
-     * 
- * - * .google.protobuf.Timestamp start_time = 1; - * - * @return Whether the startTime field is set. - */ - public boolean hasStartTime() { - return startTimeBuilder_ != null || startTime_ != null; - } - /** - * - * - *
-     * Start of time span.
-     * 
- * - * .google.protobuf.Timestamp start_time = 1; - * - * @return The startTime. - */ - public com.google.protobuf.Timestamp getStartTime() { - if (startTimeBuilder_ == null) { - return startTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : startTime_; - } else { - return startTimeBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Start of time span.
-     * 
- * - * .google.protobuf.Timestamp start_time = 1; - */ - public Builder setStartTime(com.google.protobuf.Timestamp value) { - if (startTimeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - startTime_ = value; - onChanged(); - } else { - startTimeBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * Start of time span.
-     * 
- * - * .google.protobuf.Timestamp start_time = 1; - */ - public Builder setStartTime(com.google.protobuf.Timestamp.Builder builderForValue) { - if (startTimeBuilder_ == null) { - startTime_ = builderForValue.build(); - onChanged(); - } else { - startTimeBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Start of time span.
-     * 
- * - * .google.protobuf.Timestamp start_time = 1; - */ - public Builder mergeStartTime(com.google.protobuf.Timestamp value) { - if (startTimeBuilder_ == null) { - if (startTime_ != null) { - startTime_ = - com.google.protobuf.Timestamp.newBuilder(startTime_).mergeFrom(value).buildPartial(); - } else { - startTime_ = value; - } - onChanged(); - } else { - startTimeBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * Start of time span.
-     * 
- * - * .google.protobuf.Timestamp start_time = 1; - */ - public Builder clearStartTime() { - if (startTimeBuilder_ == null) { - startTime_ = null; - onChanged(); - } else { - startTime_ = null; - startTimeBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Start of time span.
-     * 
- * - * .google.protobuf.Timestamp start_time = 1; - */ - public com.google.protobuf.Timestamp.Builder getStartTimeBuilder() { - - onChanged(); - return getStartTimeFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Start of time span.
-     * 
- * - * .google.protobuf.Timestamp start_time = 1; - */ - public com.google.protobuf.TimestampOrBuilder getStartTimeOrBuilder() { - if (startTimeBuilder_ != null) { - return startTimeBuilder_.getMessageOrBuilder(); - } else { - return startTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : startTime_; - } - } - /** - * - * - *
-     * Start of time span.
-     * 
- * - * .google.protobuf.Timestamp start_time = 1; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - getStartTimeFieldBuilder() { - if (startTimeBuilder_ == null) { - startTimeBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder>( - getStartTime(), getParentForChildren(), isClean()); - startTime_ = null; - } - return startTimeBuilder_; - } - - private com.google.protobuf.Timestamp endTime_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - endTimeBuilder_; - /** - * - * - *
-     * End of time span.
-     * 
- * - * .google.protobuf.Timestamp end_time = 2; - * - * @return Whether the endTime field is set. - */ - public boolean hasEndTime() { - return endTimeBuilder_ != null || endTime_ != null; - } - /** - * - * - *
-     * End of time span.
-     * 
- * - * .google.protobuf.Timestamp end_time = 2; - * - * @return The endTime. - */ - public com.google.protobuf.Timestamp getEndTime() { - if (endTimeBuilder_ == null) { - return endTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : endTime_; - } else { - return endTimeBuilder_.getMessage(); - } - } - /** - * - * - *
-     * End of time span.
-     * 
- * - * .google.protobuf.Timestamp end_time = 2; - */ - public Builder setEndTime(com.google.protobuf.Timestamp value) { - if (endTimeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - endTime_ = value; - onChanged(); - } else { - endTimeBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * End of time span.
-     * 
- * - * .google.protobuf.Timestamp end_time = 2; - */ - public Builder setEndTime(com.google.protobuf.Timestamp.Builder builderForValue) { - if (endTimeBuilder_ == null) { - endTime_ = builderForValue.build(); - onChanged(); - } else { - endTimeBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * End of time span.
-     * 
- * - * .google.protobuf.Timestamp end_time = 2; - */ - public Builder mergeEndTime(com.google.protobuf.Timestamp value) { - if (endTimeBuilder_ == null) { - if (endTime_ != null) { - endTime_ = - com.google.protobuf.Timestamp.newBuilder(endTime_).mergeFrom(value).buildPartial(); - } else { - endTime_ = value; - } - onChanged(); - } else { - endTimeBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * End of time span.
-     * 
- * - * .google.protobuf.Timestamp end_time = 2; - */ - public Builder clearEndTime() { - if (endTimeBuilder_ == null) { - endTime_ = null; - onChanged(); - } else { - endTime_ = null; - endTimeBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * End of time span.
-     * 
- * - * .google.protobuf.Timestamp end_time = 2; - */ - public com.google.protobuf.Timestamp.Builder getEndTimeBuilder() { - - onChanged(); - return getEndTimeFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * End of time span.
-     * 
- * - * .google.protobuf.Timestamp end_time = 2; - */ - public com.google.protobuf.TimestampOrBuilder getEndTimeOrBuilder() { - if (endTimeBuilder_ != null) { - return endTimeBuilder_.getMessageOrBuilder(); - } else { - return endTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : endTime_; - } - } - /** - * - * - *
-     * End of time span.
-     * 
- * - * .google.protobuf.Timestamp end_time = 2; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - getEndTimeFieldBuilder() { - if (endTimeBuilder_ == null) { - endTimeBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder>( - getEndTime(), getParentForChildren(), isClean()); - endTime_ = null; - } - return endTimeBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.TimeSpan) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.TimeSpan) - private static final com.google.cloudbuild.v1.TimeSpan DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.TimeSpan(); - } - - public static com.google.cloudbuild.v1.TimeSpan getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public TimeSpan parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.TimeSpan getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/TimeSpanOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/TimeSpanOrBuilder.java deleted file mode 100644 index b061a74d..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/TimeSpanOrBuilder.java +++ /dev/null @@ -1,95 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface TimeSpanOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.TimeSpan) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * Start of time span.
-   * 
- * - * .google.protobuf.Timestamp start_time = 1; - * - * @return Whether the startTime field is set. - */ - boolean hasStartTime(); - /** - * - * - *
-   * Start of time span.
-   * 
- * - * .google.protobuf.Timestamp start_time = 1; - * - * @return The startTime. - */ - com.google.protobuf.Timestamp getStartTime(); - /** - * - * - *
-   * Start of time span.
-   * 
- * - * .google.protobuf.Timestamp start_time = 1; - */ - com.google.protobuf.TimestampOrBuilder getStartTimeOrBuilder(); - - /** - * - * - *
-   * End of time span.
-   * 
- * - * .google.protobuf.Timestamp end_time = 2; - * - * @return Whether the endTime field is set. - */ - boolean hasEndTime(); - /** - * - * - *
-   * End of time span.
-   * 
- * - * .google.protobuf.Timestamp end_time = 2; - * - * @return The endTime. - */ - com.google.protobuf.Timestamp getEndTime(); - /** - * - * - *
-   * End of time span.
-   * 
- * - * .google.protobuf.Timestamp end_time = 2; - */ - com.google.protobuf.TimestampOrBuilder getEndTimeOrBuilder(); -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/UpdateBuildTriggerRequest.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/UpdateBuildTriggerRequest.java deleted file mode 100644 index cb3c6155..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/UpdateBuildTriggerRequest.java +++ /dev/null @@ -1,1082 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * Request to update an existing `BuildTrigger`.
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.UpdateBuildTriggerRequest} - */ -public final class UpdateBuildTriggerRequest extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.UpdateBuildTriggerRequest) - UpdateBuildTriggerRequestOrBuilder { - private static final long serialVersionUID = 0L; - // Use UpdateBuildTriggerRequest.newBuilder() to construct. - private UpdateBuildTriggerRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private UpdateBuildTriggerRequest() { - projectId_ = ""; - triggerId_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new UpdateBuildTriggerRequest(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_UpdateBuildTriggerRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_UpdateBuildTriggerRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.UpdateBuildTriggerRequest.class, - com.google.cloudbuild.v1.UpdateBuildTriggerRequest.Builder.class); - } - - public static final int PROJECT_ID_FIELD_NUMBER = 1; - private volatile java.lang.Object projectId_; - /** - * - * - *
-   * Required. ID of the project that owns the trigger.
-   * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The projectId. - */ - @java.lang.Override - public java.lang.String getProjectId() { - java.lang.Object ref = projectId_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - projectId_ = s; - return s; - } - } - /** - * - * - *
-   * Required. ID of the project that owns the trigger.
-   * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for projectId. - */ - @java.lang.Override - public com.google.protobuf.ByteString getProjectIdBytes() { - java.lang.Object ref = projectId_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - projectId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int TRIGGER_ID_FIELD_NUMBER = 2; - private volatile java.lang.Object triggerId_; - /** - * - * - *
-   * Required. ID of the `BuildTrigger` to update.
-   * 
- * - * string trigger_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The triggerId. - */ - @java.lang.Override - public java.lang.String getTriggerId() { - java.lang.Object ref = triggerId_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - triggerId_ = s; - return s; - } - } - /** - * - * - *
-   * Required. ID of the `BuildTrigger` to update.
-   * 
- * - * string trigger_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for triggerId. - */ - @java.lang.Override - public com.google.protobuf.ByteString getTriggerIdBytes() { - java.lang.Object ref = triggerId_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - triggerId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int TRIGGER_FIELD_NUMBER = 3; - private com.google.cloudbuild.v1.BuildTrigger trigger_; - /** - * - * - *
-   * Required. `BuildTrigger` to update.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.BuildTrigger trigger = 3 [(.google.api.field_behavior) = REQUIRED]; - * - * - * @return Whether the trigger field is set. - */ - @java.lang.Override - public boolean hasTrigger() { - return trigger_ != null; - } - /** - * - * - *
-   * Required. `BuildTrigger` to update.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.BuildTrigger trigger = 3 [(.google.api.field_behavior) = REQUIRED]; - * - * - * @return The trigger. - */ - @java.lang.Override - public com.google.cloudbuild.v1.BuildTrigger getTrigger() { - return trigger_ == null ? com.google.cloudbuild.v1.BuildTrigger.getDefaultInstance() : trigger_; - } - /** - * - * - *
-   * Required. `BuildTrigger` to update.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.BuildTrigger trigger = 3 [(.google.api.field_behavior) = REQUIRED]; - * - */ - @java.lang.Override - public com.google.cloudbuild.v1.BuildTriggerOrBuilder getTriggerOrBuilder() { - return getTrigger(); - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(projectId_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, projectId_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(triggerId_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, triggerId_); - } - if (trigger_ != null) { - output.writeMessage(3, getTrigger()); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(projectId_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, projectId_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(triggerId_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, triggerId_); - } - if (trigger_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getTrigger()); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.UpdateBuildTriggerRequest)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.UpdateBuildTriggerRequest other = - (com.google.cloudbuild.v1.UpdateBuildTriggerRequest) obj; - - if (!getProjectId().equals(other.getProjectId())) return false; - if (!getTriggerId().equals(other.getTriggerId())) return false; - if (hasTrigger() != other.hasTrigger()) return false; - if (hasTrigger()) { - if (!getTrigger().equals(other.getTrigger())) return false; - } - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + PROJECT_ID_FIELD_NUMBER; - hash = (53 * hash) + getProjectId().hashCode(); - hash = (37 * hash) + TRIGGER_ID_FIELD_NUMBER; - hash = (53 * hash) + getTriggerId().hashCode(); - if (hasTrigger()) { - hash = (37 * hash) + TRIGGER_FIELD_NUMBER; - hash = (53 * hash) + getTrigger().hashCode(); - } - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.UpdateBuildTriggerRequest parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.UpdateBuildTriggerRequest parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.UpdateBuildTriggerRequest parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.UpdateBuildTriggerRequest parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.UpdateBuildTriggerRequest parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.UpdateBuildTriggerRequest parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.UpdateBuildTriggerRequest parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.UpdateBuildTriggerRequest parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.UpdateBuildTriggerRequest parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.UpdateBuildTriggerRequest parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.UpdateBuildTriggerRequest parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.UpdateBuildTriggerRequest parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.UpdateBuildTriggerRequest prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * Request to update an existing `BuildTrigger`.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.UpdateBuildTriggerRequest} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.UpdateBuildTriggerRequest) - com.google.cloudbuild.v1.UpdateBuildTriggerRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_UpdateBuildTriggerRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_UpdateBuildTriggerRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.UpdateBuildTriggerRequest.class, - com.google.cloudbuild.v1.UpdateBuildTriggerRequest.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.UpdateBuildTriggerRequest.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - projectId_ = ""; - - triggerId_ = ""; - - if (triggerBuilder_ == null) { - trigger_ = null; - } else { - trigger_ = null; - triggerBuilder_ = null; - } - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_UpdateBuildTriggerRequest_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.UpdateBuildTriggerRequest getDefaultInstanceForType() { - return com.google.cloudbuild.v1.UpdateBuildTriggerRequest.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.UpdateBuildTriggerRequest build() { - com.google.cloudbuild.v1.UpdateBuildTriggerRequest result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.UpdateBuildTriggerRequest buildPartial() { - com.google.cloudbuild.v1.UpdateBuildTriggerRequest result = - new com.google.cloudbuild.v1.UpdateBuildTriggerRequest(this); - result.projectId_ = projectId_; - result.triggerId_ = triggerId_; - if (triggerBuilder_ == null) { - result.trigger_ = trigger_; - } else { - result.trigger_ = triggerBuilder_.build(); - } - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.UpdateBuildTriggerRequest) { - return mergeFrom((com.google.cloudbuild.v1.UpdateBuildTriggerRequest) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.UpdateBuildTriggerRequest other) { - if (other == com.google.cloudbuild.v1.UpdateBuildTriggerRequest.getDefaultInstance()) - return this; - if (!other.getProjectId().isEmpty()) { - projectId_ = other.projectId_; - onChanged(); - } - if (!other.getTriggerId().isEmpty()) { - triggerId_ = other.triggerId_; - onChanged(); - } - if (other.hasTrigger()) { - mergeTrigger(other.getTrigger()); - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - projectId_ = input.readStringRequireUtf8(); - - break; - } // case 10 - case 18: - { - triggerId_ = input.readStringRequireUtf8(); - - break; - } // case 18 - case 26: - { - input.readMessage(getTriggerFieldBuilder().getBuilder(), extensionRegistry); - - break; - } // case 26 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private java.lang.Object projectId_ = ""; - /** - * - * - *
-     * Required. ID of the project that owns the trigger.
-     * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The projectId. - */ - public java.lang.String getProjectId() { - java.lang.Object ref = projectId_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - projectId_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Required. ID of the project that owns the trigger.
-     * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for projectId. - */ - public com.google.protobuf.ByteString getProjectIdBytes() { - java.lang.Object ref = projectId_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - projectId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Required. ID of the project that owns the trigger.
-     * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @param value The projectId to set. - * @return This builder for chaining. - */ - public Builder setProjectId(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - projectId_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Required. ID of the project that owns the trigger.
-     * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return This builder for chaining. - */ - public Builder clearProjectId() { - - projectId_ = getDefaultInstance().getProjectId(); - onChanged(); - return this; - } - /** - * - * - *
-     * Required. ID of the project that owns the trigger.
-     * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @param value The bytes for projectId to set. - * @return This builder for chaining. - */ - public Builder setProjectIdBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - projectId_ = value; - onChanged(); - return this; - } - - private java.lang.Object triggerId_ = ""; - /** - * - * - *
-     * Required. ID of the `BuildTrigger` to update.
-     * 
- * - * string trigger_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The triggerId. - */ - public java.lang.String getTriggerId() { - java.lang.Object ref = triggerId_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - triggerId_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Required. ID of the `BuildTrigger` to update.
-     * 
- * - * string trigger_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for triggerId. - */ - public com.google.protobuf.ByteString getTriggerIdBytes() { - java.lang.Object ref = triggerId_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - triggerId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Required. ID of the `BuildTrigger` to update.
-     * 
- * - * string trigger_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @param value The triggerId to set. - * @return This builder for chaining. - */ - public Builder setTriggerId(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - triggerId_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Required. ID of the `BuildTrigger` to update.
-     * 
- * - * string trigger_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @return This builder for chaining. - */ - public Builder clearTriggerId() { - - triggerId_ = getDefaultInstance().getTriggerId(); - onChanged(); - return this; - } - /** - * - * - *
-     * Required. ID of the `BuildTrigger` to update.
-     * 
- * - * string trigger_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @param value The bytes for triggerId to set. - * @return This builder for chaining. - */ - public Builder setTriggerIdBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - triggerId_ = value; - onChanged(); - return this; - } - - private com.google.cloudbuild.v1.BuildTrigger trigger_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.BuildTrigger, - com.google.cloudbuild.v1.BuildTrigger.Builder, - com.google.cloudbuild.v1.BuildTriggerOrBuilder> - triggerBuilder_; - /** - * - * - *
-     * Required. `BuildTrigger` to update.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.BuildTrigger trigger = 3 [(.google.api.field_behavior) = REQUIRED]; - * - * - * @return Whether the trigger field is set. - */ - public boolean hasTrigger() { - return triggerBuilder_ != null || trigger_ != null; - } - /** - * - * - *
-     * Required. `BuildTrigger` to update.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.BuildTrigger trigger = 3 [(.google.api.field_behavior) = REQUIRED]; - * - * - * @return The trigger. - */ - public com.google.cloudbuild.v1.BuildTrigger getTrigger() { - if (triggerBuilder_ == null) { - return trigger_ == null - ? com.google.cloudbuild.v1.BuildTrigger.getDefaultInstance() - : trigger_; - } else { - return triggerBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Required. `BuildTrigger` to update.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.BuildTrigger trigger = 3 [(.google.api.field_behavior) = REQUIRED]; - * - */ - public Builder setTrigger(com.google.cloudbuild.v1.BuildTrigger value) { - if (triggerBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - trigger_ = value; - onChanged(); - } else { - triggerBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * Required. `BuildTrigger` to update.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.BuildTrigger trigger = 3 [(.google.api.field_behavior) = REQUIRED]; - * - */ - public Builder setTrigger(com.google.cloudbuild.v1.BuildTrigger.Builder builderForValue) { - if (triggerBuilder_ == null) { - trigger_ = builderForValue.build(); - onChanged(); - } else { - triggerBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Required. `BuildTrigger` to update.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.BuildTrigger trigger = 3 [(.google.api.field_behavior) = REQUIRED]; - * - */ - public Builder mergeTrigger(com.google.cloudbuild.v1.BuildTrigger value) { - if (triggerBuilder_ == null) { - if (trigger_ != null) { - trigger_ = - com.google.cloudbuild.v1.BuildTrigger.newBuilder(trigger_) - .mergeFrom(value) - .buildPartial(); - } else { - trigger_ = value; - } - onChanged(); - } else { - triggerBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * Required. `BuildTrigger` to update.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.BuildTrigger trigger = 3 [(.google.api.field_behavior) = REQUIRED]; - * - */ - public Builder clearTrigger() { - if (triggerBuilder_ == null) { - trigger_ = null; - onChanged(); - } else { - trigger_ = null; - triggerBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Required. `BuildTrigger` to update.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.BuildTrigger trigger = 3 [(.google.api.field_behavior) = REQUIRED]; - * - */ - public com.google.cloudbuild.v1.BuildTrigger.Builder getTriggerBuilder() { - - onChanged(); - return getTriggerFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Required. `BuildTrigger` to update.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.BuildTrigger trigger = 3 [(.google.api.field_behavior) = REQUIRED]; - * - */ - public com.google.cloudbuild.v1.BuildTriggerOrBuilder getTriggerOrBuilder() { - if (triggerBuilder_ != null) { - return triggerBuilder_.getMessageOrBuilder(); - } else { - return trigger_ == null - ? com.google.cloudbuild.v1.BuildTrigger.getDefaultInstance() - : trigger_; - } - } - /** - * - * - *
-     * Required. `BuildTrigger` to update.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.BuildTrigger trigger = 3 [(.google.api.field_behavior) = REQUIRED]; - * - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.BuildTrigger, - com.google.cloudbuild.v1.BuildTrigger.Builder, - com.google.cloudbuild.v1.BuildTriggerOrBuilder> - getTriggerFieldBuilder() { - if (triggerBuilder_ == null) { - triggerBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.BuildTrigger, - com.google.cloudbuild.v1.BuildTrigger.Builder, - com.google.cloudbuild.v1.BuildTriggerOrBuilder>( - getTrigger(), getParentForChildren(), isClean()); - trigger_ = null; - } - return triggerBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.UpdateBuildTriggerRequest) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.UpdateBuildTriggerRequest) - private static final com.google.cloudbuild.v1.UpdateBuildTriggerRequest DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.UpdateBuildTriggerRequest(); - } - - public static com.google.cloudbuild.v1.UpdateBuildTriggerRequest getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public UpdateBuildTriggerRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.UpdateBuildTriggerRequest getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/UpdateBuildTriggerRequestOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/UpdateBuildTriggerRequestOrBuilder.java deleted file mode 100644 index e63f9e57..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/UpdateBuildTriggerRequestOrBuilder.java +++ /dev/null @@ -1,116 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface UpdateBuildTriggerRequestOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.UpdateBuildTriggerRequest) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * Required. ID of the project that owns the trigger.
-   * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The projectId. - */ - java.lang.String getProjectId(); - /** - * - * - *
-   * Required. ID of the project that owns the trigger.
-   * 
- * - * string project_id = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for projectId. - */ - com.google.protobuf.ByteString getProjectIdBytes(); - - /** - * - * - *
-   * Required. ID of the `BuildTrigger` to update.
-   * 
- * - * string trigger_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The triggerId. - */ - java.lang.String getTriggerId(); - /** - * - * - *
-   * Required. ID of the `BuildTrigger` to update.
-   * 
- * - * string trigger_id = 2 [(.google.api.field_behavior) = REQUIRED]; - * - * @return The bytes for triggerId. - */ - com.google.protobuf.ByteString getTriggerIdBytes(); - - /** - * - * - *
-   * Required. `BuildTrigger` to update.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.BuildTrigger trigger = 3 [(.google.api.field_behavior) = REQUIRED]; - * - * - * @return Whether the trigger field is set. - */ - boolean hasTrigger(); - /** - * - * - *
-   * Required. `BuildTrigger` to update.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.BuildTrigger trigger = 3 [(.google.api.field_behavior) = REQUIRED]; - * - * - * @return The trigger. - */ - com.google.cloudbuild.v1.BuildTrigger getTrigger(); - /** - * - * - *
-   * Required. `BuildTrigger` to update.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.BuildTrigger trigger = 3 [(.google.api.field_behavior) = REQUIRED]; - * - */ - com.google.cloudbuild.v1.BuildTriggerOrBuilder getTriggerOrBuilder(); -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/UpdateWorkerPoolOperationMetadata.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/UpdateWorkerPoolOperationMetadata.java deleted file mode 100644 index 0fe35ae1..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/UpdateWorkerPoolOperationMetadata.java +++ /dev/null @@ -1,1161 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * Metadata for the `UpdateWorkerPool` operation.
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.UpdateWorkerPoolOperationMetadata} - */ -public final class UpdateWorkerPoolOperationMetadata extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.UpdateWorkerPoolOperationMetadata) - UpdateWorkerPoolOperationMetadataOrBuilder { - private static final long serialVersionUID = 0L; - // Use UpdateWorkerPoolOperationMetadata.newBuilder() to construct. - private UpdateWorkerPoolOperationMetadata( - com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private UpdateWorkerPoolOperationMetadata() { - workerPool_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new UpdateWorkerPoolOperationMetadata(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_UpdateWorkerPoolOperationMetadata_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_UpdateWorkerPoolOperationMetadata_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.UpdateWorkerPoolOperationMetadata.class, - com.google.cloudbuild.v1.UpdateWorkerPoolOperationMetadata.Builder.class); - } - - public static final int WORKER_POOL_FIELD_NUMBER = 1; - private volatile java.lang.Object workerPool_; - /** - * - * - *
-   * The resource name of the `WorkerPool` being updated.
-   * Format:
-   * `projects/{project}/locations/{location}/workerPools/{worker_pool}`.
-   * 
- * - * string worker_pool = 1 [(.google.api.resource_reference) = { ... } - * - * @return The workerPool. - */ - @java.lang.Override - public java.lang.String getWorkerPool() { - java.lang.Object ref = workerPool_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - workerPool_ = s; - return s; - } - } - /** - * - * - *
-   * The resource name of the `WorkerPool` being updated.
-   * Format:
-   * `projects/{project}/locations/{location}/workerPools/{worker_pool}`.
-   * 
- * - * string worker_pool = 1 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for workerPool. - */ - @java.lang.Override - public com.google.protobuf.ByteString getWorkerPoolBytes() { - java.lang.Object ref = workerPool_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - workerPool_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int CREATE_TIME_FIELD_NUMBER = 2; - private com.google.protobuf.Timestamp createTime_; - /** - * - * - *
-   * Time the operation was created.
-   * 
- * - * .google.protobuf.Timestamp create_time = 2; - * - * @return Whether the createTime field is set. - */ - @java.lang.Override - public boolean hasCreateTime() { - return createTime_ != null; - } - /** - * - * - *
-   * Time the operation was created.
-   * 
- * - * .google.protobuf.Timestamp create_time = 2; - * - * @return The createTime. - */ - @java.lang.Override - public com.google.protobuf.Timestamp getCreateTime() { - return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; - } - /** - * - * - *
-   * Time the operation was created.
-   * 
- * - * .google.protobuf.Timestamp create_time = 2; - */ - @java.lang.Override - public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { - return getCreateTime(); - } - - public static final int COMPLETE_TIME_FIELD_NUMBER = 3; - private com.google.protobuf.Timestamp completeTime_; - /** - * - * - *
-   * Time the operation was completed.
-   * 
- * - * .google.protobuf.Timestamp complete_time = 3; - * - * @return Whether the completeTime field is set. - */ - @java.lang.Override - public boolean hasCompleteTime() { - return completeTime_ != null; - } - /** - * - * - *
-   * Time the operation was completed.
-   * 
- * - * .google.protobuf.Timestamp complete_time = 3; - * - * @return The completeTime. - */ - @java.lang.Override - public com.google.protobuf.Timestamp getCompleteTime() { - return completeTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : completeTime_; - } - /** - * - * - *
-   * Time the operation was completed.
-   * 
- * - * .google.protobuf.Timestamp complete_time = 3; - */ - @java.lang.Override - public com.google.protobuf.TimestampOrBuilder getCompleteTimeOrBuilder() { - return getCompleteTime(); - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(workerPool_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, workerPool_); - } - if (createTime_ != null) { - output.writeMessage(2, getCreateTime()); - } - if (completeTime_ != null) { - output.writeMessage(3, getCompleteTime()); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(workerPool_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, workerPool_); - } - if (createTime_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getCreateTime()); - } - if (completeTime_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getCompleteTime()); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.UpdateWorkerPoolOperationMetadata)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.UpdateWorkerPoolOperationMetadata other = - (com.google.cloudbuild.v1.UpdateWorkerPoolOperationMetadata) obj; - - if (!getWorkerPool().equals(other.getWorkerPool())) return false; - if (hasCreateTime() != other.hasCreateTime()) return false; - if (hasCreateTime()) { - if (!getCreateTime().equals(other.getCreateTime())) return false; - } - if (hasCompleteTime() != other.hasCompleteTime()) return false; - if (hasCompleteTime()) { - if (!getCompleteTime().equals(other.getCompleteTime())) return false; - } - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + WORKER_POOL_FIELD_NUMBER; - hash = (53 * hash) + getWorkerPool().hashCode(); - if (hasCreateTime()) { - hash = (37 * hash) + CREATE_TIME_FIELD_NUMBER; - hash = (53 * hash) + getCreateTime().hashCode(); - } - if (hasCompleteTime()) { - hash = (37 * hash) + COMPLETE_TIME_FIELD_NUMBER; - hash = (53 * hash) + getCompleteTime().hashCode(); - } - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.UpdateWorkerPoolOperationMetadata parseFrom( - java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.UpdateWorkerPoolOperationMetadata parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.UpdateWorkerPoolOperationMetadata parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.UpdateWorkerPoolOperationMetadata parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.UpdateWorkerPoolOperationMetadata parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.UpdateWorkerPoolOperationMetadata parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.UpdateWorkerPoolOperationMetadata parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.UpdateWorkerPoolOperationMetadata parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.UpdateWorkerPoolOperationMetadata parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.UpdateWorkerPoolOperationMetadata parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.UpdateWorkerPoolOperationMetadata parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.UpdateWorkerPoolOperationMetadata parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder( - com.google.cloudbuild.v1.UpdateWorkerPoolOperationMetadata prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * Metadata for the `UpdateWorkerPool` operation.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.UpdateWorkerPoolOperationMetadata} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.UpdateWorkerPoolOperationMetadata) - com.google.cloudbuild.v1.UpdateWorkerPoolOperationMetadataOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_UpdateWorkerPoolOperationMetadata_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_UpdateWorkerPoolOperationMetadata_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.UpdateWorkerPoolOperationMetadata.class, - com.google.cloudbuild.v1.UpdateWorkerPoolOperationMetadata.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.UpdateWorkerPoolOperationMetadata.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - workerPool_ = ""; - - if (createTimeBuilder_ == null) { - createTime_ = null; - } else { - createTime_ = null; - createTimeBuilder_ = null; - } - if (completeTimeBuilder_ == null) { - completeTime_ = null; - } else { - completeTime_ = null; - completeTimeBuilder_ = null; - } - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_UpdateWorkerPoolOperationMetadata_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.UpdateWorkerPoolOperationMetadata getDefaultInstanceForType() { - return com.google.cloudbuild.v1.UpdateWorkerPoolOperationMetadata.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.UpdateWorkerPoolOperationMetadata build() { - com.google.cloudbuild.v1.UpdateWorkerPoolOperationMetadata result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.UpdateWorkerPoolOperationMetadata buildPartial() { - com.google.cloudbuild.v1.UpdateWorkerPoolOperationMetadata result = - new com.google.cloudbuild.v1.UpdateWorkerPoolOperationMetadata(this); - result.workerPool_ = workerPool_; - if (createTimeBuilder_ == null) { - result.createTime_ = createTime_; - } else { - result.createTime_ = createTimeBuilder_.build(); - } - if (completeTimeBuilder_ == null) { - result.completeTime_ = completeTime_; - } else { - result.completeTime_ = completeTimeBuilder_.build(); - } - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.UpdateWorkerPoolOperationMetadata) { - return mergeFrom((com.google.cloudbuild.v1.UpdateWorkerPoolOperationMetadata) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.UpdateWorkerPoolOperationMetadata other) { - if (other == com.google.cloudbuild.v1.UpdateWorkerPoolOperationMetadata.getDefaultInstance()) - return this; - if (!other.getWorkerPool().isEmpty()) { - workerPool_ = other.workerPool_; - onChanged(); - } - if (other.hasCreateTime()) { - mergeCreateTime(other.getCreateTime()); - } - if (other.hasCompleteTime()) { - mergeCompleteTime(other.getCompleteTime()); - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - workerPool_ = input.readStringRequireUtf8(); - - break; - } // case 10 - case 18: - { - input.readMessage(getCreateTimeFieldBuilder().getBuilder(), extensionRegistry); - - break; - } // case 18 - case 26: - { - input.readMessage(getCompleteTimeFieldBuilder().getBuilder(), extensionRegistry); - - break; - } // case 26 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private java.lang.Object workerPool_ = ""; - /** - * - * - *
-     * The resource name of the `WorkerPool` being updated.
-     * Format:
-     * `projects/{project}/locations/{location}/workerPools/{worker_pool}`.
-     * 
- * - * string worker_pool = 1 [(.google.api.resource_reference) = { ... } - * - * @return The workerPool. - */ - public java.lang.String getWorkerPool() { - java.lang.Object ref = workerPool_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - workerPool_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * The resource name of the `WorkerPool` being updated.
-     * Format:
-     * `projects/{project}/locations/{location}/workerPools/{worker_pool}`.
-     * 
- * - * string worker_pool = 1 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for workerPool. - */ - public com.google.protobuf.ByteString getWorkerPoolBytes() { - java.lang.Object ref = workerPool_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - workerPool_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * The resource name of the `WorkerPool` being updated.
-     * Format:
-     * `projects/{project}/locations/{location}/workerPools/{worker_pool}`.
-     * 
- * - * string worker_pool = 1 [(.google.api.resource_reference) = { ... } - * - * @param value The workerPool to set. - * @return This builder for chaining. - */ - public Builder setWorkerPool(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - workerPool_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * The resource name of the `WorkerPool` being updated.
-     * Format:
-     * `projects/{project}/locations/{location}/workerPools/{worker_pool}`.
-     * 
- * - * string worker_pool = 1 [(.google.api.resource_reference) = { ... } - * - * @return This builder for chaining. - */ - public Builder clearWorkerPool() { - - workerPool_ = getDefaultInstance().getWorkerPool(); - onChanged(); - return this; - } - /** - * - * - *
-     * The resource name of the `WorkerPool` being updated.
-     * Format:
-     * `projects/{project}/locations/{location}/workerPools/{worker_pool}`.
-     * 
- * - * string worker_pool = 1 [(.google.api.resource_reference) = { ... } - * - * @param value The bytes for workerPool to set. - * @return This builder for chaining. - */ - public Builder setWorkerPoolBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - workerPool_ = value; - onChanged(); - return this; - } - - private com.google.protobuf.Timestamp createTime_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - createTimeBuilder_; - /** - * - * - *
-     * Time the operation was created.
-     * 
- * - * .google.protobuf.Timestamp create_time = 2; - * - * @return Whether the createTime field is set. - */ - public boolean hasCreateTime() { - return createTimeBuilder_ != null || createTime_ != null; - } - /** - * - * - *
-     * Time the operation was created.
-     * 
- * - * .google.protobuf.Timestamp create_time = 2; - * - * @return The createTime. - */ - public com.google.protobuf.Timestamp getCreateTime() { - if (createTimeBuilder_ == null) { - return createTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : createTime_; - } else { - return createTimeBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Time the operation was created.
-     * 
- * - * .google.protobuf.Timestamp create_time = 2; - */ - public Builder setCreateTime(com.google.protobuf.Timestamp value) { - if (createTimeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - createTime_ = value; - onChanged(); - } else { - createTimeBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * Time the operation was created.
-     * 
- * - * .google.protobuf.Timestamp create_time = 2; - */ - public Builder setCreateTime(com.google.protobuf.Timestamp.Builder builderForValue) { - if (createTimeBuilder_ == null) { - createTime_ = builderForValue.build(); - onChanged(); - } else { - createTimeBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Time the operation was created.
-     * 
- * - * .google.protobuf.Timestamp create_time = 2; - */ - public Builder mergeCreateTime(com.google.protobuf.Timestamp value) { - if (createTimeBuilder_ == null) { - if (createTime_ != null) { - createTime_ = - com.google.protobuf.Timestamp.newBuilder(createTime_).mergeFrom(value).buildPartial(); - } else { - createTime_ = value; - } - onChanged(); - } else { - createTimeBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * Time the operation was created.
-     * 
- * - * .google.protobuf.Timestamp create_time = 2; - */ - public Builder clearCreateTime() { - if (createTimeBuilder_ == null) { - createTime_ = null; - onChanged(); - } else { - createTime_ = null; - createTimeBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Time the operation was created.
-     * 
- * - * .google.protobuf.Timestamp create_time = 2; - */ - public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder() { - - onChanged(); - return getCreateTimeFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Time the operation was created.
-     * 
- * - * .google.protobuf.Timestamp create_time = 2; - */ - public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { - if (createTimeBuilder_ != null) { - return createTimeBuilder_.getMessageOrBuilder(); - } else { - return createTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : createTime_; - } - } - /** - * - * - *
-     * Time the operation was created.
-     * 
- * - * .google.protobuf.Timestamp create_time = 2; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - getCreateTimeFieldBuilder() { - if (createTimeBuilder_ == null) { - createTimeBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder>( - getCreateTime(), getParentForChildren(), isClean()); - createTime_ = null; - } - return createTimeBuilder_; - } - - private com.google.protobuf.Timestamp completeTime_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - completeTimeBuilder_; - /** - * - * - *
-     * Time the operation was completed.
-     * 
- * - * .google.protobuf.Timestamp complete_time = 3; - * - * @return Whether the completeTime field is set. - */ - public boolean hasCompleteTime() { - return completeTimeBuilder_ != null || completeTime_ != null; - } - /** - * - * - *
-     * Time the operation was completed.
-     * 
- * - * .google.protobuf.Timestamp complete_time = 3; - * - * @return The completeTime. - */ - public com.google.protobuf.Timestamp getCompleteTime() { - if (completeTimeBuilder_ == null) { - return completeTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : completeTime_; - } else { - return completeTimeBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Time the operation was completed.
-     * 
- * - * .google.protobuf.Timestamp complete_time = 3; - */ - public Builder setCompleteTime(com.google.protobuf.Timestamp value) { - if (completeTimeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - completeTime_ = value; - onChanged(); - } else { - completeTimeBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * Time the operation was completed.
-     * 
- * - * .google.protobuf.Timestamp complete_time = 3; - */ - public Builder setCompleteTime(com.google.protobuf.Timestamp.Builder builderForValue) { - if (completeTimeBuilder_ == null) { - completeTime_ = builderForValue.build(); - onChanged(); - } else { - completeTimeBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Time the operation was completed.
-     * 
- * - * .google.protobuf.Timestamp complete_time = 3; - */ - public Builder mergeCompleteTime(com.google.protobuf.Timestamp value) { - if (completeTimeBuilder_ == null) { - if (completeTime_ != null) { - completeTime_ = - com.google.protobuf.Timestamp.newBuilder(completeTime_) - .mergeFrom(value) - .buildPartial(); - } else { - completeTime_ = value; - } - onChanged(); - } else { - completeTimeBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * Time the operation was completed.
-     * 
- * - * .google.protobuf.Timestamp complete_time = 3; - */ - public Builder clearCompleteTime() { - if (completeTimeBuilder_ == null) { - completeTime_ = null; - onChanged(); - } else { - completeTime_ = null; - completeTimeBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Time the operation was completed.
-     * 
- * - * .google.protobuf.Timestamp complete_time = 3; - */ - public com.google.protobuf.Timestamp.Builder getCompleteTimeBuilder() { - - onChanged(); - return getCompleteTimeFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Time the operation was completed.
-     * 
- * - * .google.protobuf.Timestamp complete_time = 3; - */ - public com.google.protobuf.TimestampOrBuilder getCompleteTimeOrBuilder() { - if (completeTimeBuilder_ != null) { - return completeTimeBuilder_.getMessageOrBuilder(); - } else { - return completeTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : completeTime_; - } - } - /** - * - * - *
-     * Time the operation was completed.
-     * 
- * - * .google.protobuf.Timestamp complete_time = 3; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - getCompleteTimeFieldBuilder() { - if (completeTimeBuilder_ == null) { - completeTimeBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder>( - getCompleteTime(), getParentForChildren(), isClean()); - completeTime_ = null; - } - return completeTimeBuilder_; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.UpdateWorkerPoolOperationMetadata) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.UpdateWorkerPoolOperationMetadata) - private static final com.google.cloudbuild.v1.UpdateWorkerPoolOperationMetadata DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.UpdateWorkerPoolOperationMetadata(); - } - - public static com.google.cloudbuild.v1.UpdateWorkerPoolOperationMetadata getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public UpdateWorkerPoolOperationMetadata parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.UpdateWorkerPoolOperationMetadata getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/UpdateWorkerPoolOperationMetadataOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/UpdateWorkerPoolOperationMetadataOrBuilder.java deleted file mode 100644 index 0abad945..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/UpdateWorkerPoolOperationMetadataOrBuilder.java +++ /dev/null @@ -1,124 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface UpdateWorkerPoolOperationMetadataOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.UpdateWorkerPoolOperationMetadata) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * The resource name of the `WorkerPool` being updated.
-   * Format:
-   * `projects/{project}/locations/{location}/workerPools/{worker_pool}`.
-   * 
- * - * string worker_pool = 1 [(.google.api.resource_reference) = { ... } - * - * @return The workerPool. - */ - java.lang.String getWorkerPool(); - /** - * - * - *
-   * The resource name of the `WorkerPool` being updated.
-   * Format:
-   * `projects/{project}/locations/{location}/workerPools/{worker_pool}`.
-   * 
- * - * string worker_pool = 1 [(.google.api.resource_reference) = { ... } - * - * @return The bytes for workerPool. - */ - com.google.protobuf.ByteString getWorkerPoolBytes(); - - /** - * - * - *
-   * Time the operation was created.
-   * 
- * - * .google.protobuf.Timestamp create_time = 2; - * - * @return Whether the createTime field is set. - */ - boolean hasCreateTime(); - /** - * - * - *
-   * Time the operation was created.
-   * 
- * - * .google.protobuf.Timestamp create_time = 2; - * - * @return The createTime. - */ - com.google.protobuf.Timestamp getCreateTime(); - /** - * - * - *
-   * Time the operation was created.
-   * 
- * - * .google.protobuf.Timestamp create_time = 2; - */ - com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder(); - - /** - * - * - *
-   * Time the operation was completed.
-   * 
- * - * .google.protobuf.Timestamp complete_time = 3; - * - * @return Whether the completeTime field is set. - */ - boolean hasCompleteTime(); - /** - * - * - *
-   * Time the operation was completed.
-   * 
- * - * .google.protobuf.Timestamp complete_time = 3; - * - * @return The completeTime. - */ - com.google.protobuf.Timestamp getCompleteTime(); - /** - * - * - *
-   * Time the operation was completed.
-   * 
- * - * .google.protobuf.Timestamp complete_time = 3; - */ - com.google.protobuf.TimestampOrBuilder getCompleteTimeOrBuilder(); -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/UpdateWorkerPoolRequest.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/UpdateWorkerPoolRequest.java deleted file mode 100644 index e3b2dd15..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/UpdateWorkerPoolRequest.java +++ /dev/null @@ -1,1109 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * Request to update a `WorkerPool`.
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.UpdateWorkerPoolRequest} - */ -public final class UpdateWorkerPoolRequest extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.UpdateWorkerPoolRequest) - UpdateWorkerPoolRequestOrBuilder { - private static final long serialVersionUID = 0L; - // Use UpdateWorkerPoolRequest.newBuilder() to construct. - private UpdateWorkerPoolRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private UpdateWorkerPoolRequest() {} - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new UpdateWorkerPoolRequest(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_UpdateWorkerPoolRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_UpdateWorkerPoolRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.UpdateWorkerPoolRequest.class, - com.google.cloudbuild.v1.UpdateWorkerPoolRequest.Builder.class); - } - - public static final int WORKER_POOL_FIELD_NUMBER = 1; - private com.google.cloudbuild.v1.WorkerPool workerPool_; - /** - * - * - *
-   * Required. The `WorkerPool` to update.
-   * The `name` field is used to identify the `WorkerPool` to update.
-   * Format: `projects/{project}/locations/{location}/workerPools/{workerPool}`.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.WorkerPool worker_pool = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * - * @return Whether the workerPool field is set. - */ - @java.lang.Override - public boolean hasWorkerPool() { - return workerPool_ != null; - } - /** - * - * - *
-   * Required. The `WorkerPool` to update.
-   * The `name` field is used to identify the `WorkerPool` to update.
-   * Format: `projects/{project}/locations/{location}/workerPools/{workerPool}`.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.WorkerPool worker_pool = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * - * @return The workerPool. - */ - @java.lang.Override - public com.google.cloudbuild.v1.WorkerPool getWorkerPool() { - return workerPool_ == null - ? com.google.cloudbuild.v1.WorkerPool.getDefaultInstance() - : workerPool_; - } - /** - * - * - *
-   * Required. The `WorkerPool` to update.
-   * The `name` field is used to identify the `WorkerPool` to update.
-   * Format: `projects/{project}/locations/{location}/workerPools/{workerPool}`.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.WorkerPool worker_pool = 1 [(.google.api.field_behavior) = REQUIRED]; - * - */ - @java.lang.Override - public com.google.cloudbuild.v1.WorkerPoolOrBuilder getWorkerPoolOrBuilder() { - return getWorkerPool(); - } - - public static final int UPDATE_MASK_FIELD_NUMBER = 2; - private com.google.protobuf.FieldMask updateMask_; - /** - * - * - *
-   * A mask specifying which fields in `worker_pool` to update.
-   * 
- * - * .google.protobuf.FieldMask update_mask = 2; - * - * @return Whether the updateMask field is set. - */ - @java.lang.Override - public boolean hasUpdateMask() { - return updateMask_ != null; - } - /** - * - * - *
-   * A mask specifying which fields in `worker_pool` to update.
-   * 
- * - * .google.protobuf.FieldMask update_mask = 2; - * - * @return The updateMask. - */ - @java.lang.Override - public com.google.protobuf.FieldMask getUpdateMask() { - return updateMask_ == null ? com.google.protobuf.FieldMask.getDefaultInstance() : updateMask_; - } - /** - * - * - *
-   * A mask specifying which fields in `worker_pool` to update.
-   * 
- * - * .google.protobuf.FieldMask update_mask = 2; - */ - @java.lang.Override - public com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder() { - return getUpdateMask(); - } - - public static final int VALIDATE_ONLY_FIELD_NUMBER = 4; - private boolean validateOnly_; - /** - * - * - *
-   * If set, validate the request and preview the response, but do not actually
-   * post it.
-   * 
- * - * bool validate_only = 4; - * - * @return The validateOnly. - */ - @java.lang.Override - public boolean getValidateOnly() { - return validateOnly_; - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (workerPool_ != null) { - output.writeMessage(1, getWorkerPool()); - } - if (updateMask_ != null) { - output.writeMessage(2, getUpdateMask()); - } - if (validateOnly_ != false) { - output.writeBool(4, validateOnly_); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (workerPool_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, getWorkerPool()); - } - if (updateMask_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getUpdateMask()); - } - if (validateOnly_ != false) { - size += com.google.protobuf.CodedOutputStream.computeBoolSize(4, validateOnly_); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.UpdateWorkerPoolRequest)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.UpdateWorkerPoolRequest other = - (com.google.cloudbuild.v1.UpdateWorkerPoolRequest) obj; - - if (hasWorkerPool() != other.hasWorkerPool()) return false; - if (hasWorkerPool()) { - if (!getWorkerPool().equals(other.getWorkerPool())) return false; - } - if (hasUpdateMask() != other.hasUpdateMask()) return false; - if (hasUpdateMask()) { - if (!getUpdateMask().equals(other.getUpdateMask())) return false; - } - if (getValidateOnly() != other.getValidateOnly()) return false; - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - if (hasWorkerPool()) { - hash = (37 * hash) + WORKER_POOL_FIELD_NUMBER; - hash = (53 * hash) + getWorkerPool().hashCode(); - } - if (hasUpdateMask()) { - hash = (37 * hash) + UPDATE_MASK_FIELD_NUMBER; - hash = (53 * hash) + getUpdateMask().hashCode(); - } - hash = (37 * hash) + VALIDATE_ONLY_FIELD_NUMBER; - hash = (53 * hash) + com.google.protobuf.Internal.hashBoolean(getValidateOnly()); - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.UpdateWorkerPoolRequest parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.UpdateWorkerPoolRequest parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.UpdateWorkerPoolRequest parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.UpdateWorkerPoolRequest parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.UpdateWorkerPoolRequest parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.UpdateWorkerPoolRequest parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.UpdateWorkerPoolRequest parseFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.UpdateWorkerPoolRequest parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.UpdateWorkerPoolRequest parseDelimitedFrom( - java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.UpdateWorkerPoolRequest parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.UpdateWorkerPoolRequest parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.UpdateWorkerPoolRequest parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.UpdateWorkerPoolRequest prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * Request to update a `WorkerPool`.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.UpdateWorkerPoolRequest} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.UpdateWorkerPoolRequest) - com.google.cloudbuild.v1.UpdateWorkerPoolRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_UpdateWorkerPoolRequest_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_UpdateWorkerPoolRequest_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.UpdateWorkerPoolRequest.class, - com.google.cloudbuild.v1.UpdateWorkerPoolRequest.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.UpdateWorkerPoolRequest.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - if (workerPoolBuilder_ == null) { - workerPool_ = null; - } else { - workerPool_ = null; - workerPoolBuilder_ = null; - } - if (updateMaskBuilder_ == null) { - updateMask_ = null; - } else { - updateMask_ = null; - updateMaskBuilder_ = null; - } - validateOnly_ = false; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_UpdateWorkerPoolRequest_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.UpdateWorkerPoolRequest getDefaultInstanceForType() { - return com.google.cloudbuild.v1.UpdateWorkerPoolRequest.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.UpdateWorkerPoolRequest build() { - com.google.cloudbuild.v1.UpdateWorkerPoolRequest result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.UpdateWorkerPoolRequest buildPartial() { - com.google.cloudbuild.v1.UpdateWorkerPoolRequest result = - new com.google.cloudbuild.v1.UpdateWorkerPoolRequest(this); - if (workerPoolBuilder_ == null) { - result.workerPool_ = workerPool_; - } else { - result.workerPool_ = workerPoolBuilder_.build(); - } - if (updateMaskBuilder_ == null) { - result.updateMask_ = updateMask_; - } else { - result.updateMask_ = updateMaskBuilder_.build(); - } - result.validateOnly_ = validateOnly_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.UpdateWorkerPoolRequest) { - return mergeFrom((com.google.cloudbuild.v1.UpdateWorkerPoolRequest) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.UpdateWorkerPoolRequest other) { - if (other == com.google.cloudbuild.v1.UpdateWorkerPoolRequest.getDefaultInstance()) - return this; - if (other.hasWorkerPool()) { - mergeWorkerPool(other.getWorkerPool()); - } - if (other.hasUpdateMask()) { - mergeUpdateMask(other.getUpdateMask()); - } - if (other.getValidateOnly() != false) { - setValidateOnly(other.getValidateOnly()); - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - input.readMessage(getWorkerPoolFieldBuilder().getBuilder(), extensionRegistry); - - break; - } // case 10 - case 18: - { - input.readMessage(getUpdateMaskFieldBuilder().getBuilder(), extensionRegistry); - - break; - } // case 18 - case 32: - { - validateOnly_ = input.readBool(); - - break; - } // case 32 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private com.google.cloudbuild.v1.WorkerPool workerPool_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.WorkerPool, - com.google.cloudbuild.v1.WorkerPool.Builder, - com.google.cloudbuild.v1.WorkerPoolOrBuilder> - workerPoolBuilder_; - /** - * - * - *
-     * Required. The `WorkerPool` to update.
-     * The `name` field is used to identify the `WorkerPool` to update.
-     * Format: `projects/{project}/locations/{location}/workerPools/{workerPool}`.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.WorkerPool worker_pool = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * - * @return Whether the workerPool field is set. - */ - public boolean hasWorkerPool() { - return workerPoolBuilder_ != null || workerPool_ != null; - } - /** - * - * - *
-     * Required. The `WorkerPool` to update.
-     * The `name` field is used to identify the `WorkerPool` to update.
-     * Format: `projects/{project}/locations/{location}/workerPools/{workerPool}`.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.WorkerPool worker_pool = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * - * @return The workerPool. - */ - public com.google.cloudbuild.v1.WorkerPool getWorkerPool() { - if (workerPoolBuilder_ == null) { - return workerPool_ == null - ? com.google.cloudbuild.v1.WorkerPool.getDefaultInstance() - : workerPool_; - } else { - return workerPoolBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Required. The `WorkerPool` to update.
-     * The `name` field is used to identify the `WorkerPool` to update.
-     * Format: `projects/{project}/locations/{location}/workerPools/{workerPool}`.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.WorkerPool worker_pool = 1 [(.google.api.field_behavior) = REQUIRED]; - * - */ - public Builder setWorkerPool(com.google.cloudbuild.v1.WorkerPool value) { - if (workerPoolBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - workerPool_ = value; - onChanged(); - } else { - workerPoolBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * Required. The `WorkerPool` to update.
-     * The `name` field is used to identify the `WorkerPool` to update.
-     * Format: `projects/{project}/locations/{location}/workerPools/{workerPool}`.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.WorkerPool worker_pool = 1 [(.google.api.field_behavior) = REQUIRED]; - * - */ - public Builder setWorkerPool(com.google.cloudbuild.v1.WorkerPool.Builder builderForValue) { - if (workerPoolBuilder_ == null) { - workerPool_ = builderForValue.build(); - onChanged(); - } else { - workerPoolBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Required. The `WorkerPool` to update.
-     * The `name` field is used to identify the `WorkerPool` to update.
-     * Format: `projects/{project}/locations/{location}/workerPools/{workerPool}`.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.WorkerPool worker_pool = 1 [(.google.api.field_behavior) = REQUIRED]; - * - */ - public Builder mergeWorkerPool(com.google.cloudbuild.v1.WorkerPool value) { - if (workerPoolBuilder_ == null) { - if (workerPool_ != null) { - workerPool_ = - com.google.cloudbuild.v1.WorkerPool.newBuilder(workerPool_) - .mergeFrom(value) - .buildPartial(); - } else { - workerPool_ = value; - } - onChanged(); - } else { - workerPoolBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * Required. The `WorkerPool` to update.
-     * The `name` field is used to identify the `WorkerPool` to update.
-     * Format: `projects/{project}/locations/{location}/workerPools/{workerPool}`.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.WorkerPool worker_pool = 1 [(.google.api.field_behavior) = REQUIRED]; - * - */ - public Builder clearWorkerPool() { - if (workerPoolBuilder_ == null) { - workerPool_ = null; - onChanged(); - } else { - workerPool_ = null; - workerPoolBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Required. The `WorkerPool` to update.
-     * The `name` field is used to identify the `WorkerPool` to update.
-     * Format: `projects/{project}/locations/{location}/workerPools/{workerPool}`.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.WorkerPool worker_pool = 1 [(.google.api.field_behavior) = REQUIRED]; - * - */ - public com.google.cloudbuild.v1.WorkerPool.Builder getWorkerPoolBuilder() { - - onChanged(); - return getWorkerPoolFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Required. The `WorkerPool` to update.
-     * The `name` field is used to identify the `WorkerPool` to update.
-     * Format: `projects/{project}/locations/{location}/workerPools/{workerPool}`.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.WorkerPool worker_pool = 1 [(.google.api.field_behavior) = REQUIRED]; - * - */ - public com.google.cloudbuild.v1.WorkerPoolOrBuilder getWorkerPoolOrBuilder() { - if (workerPoolBuilder_ != null) { - return workerPoolBuilder_.getMessageOrBuilder(); - } else { - return workerPool_ == null - ? com.google.cloudbuild.v1.WorkerPool.getDefaultInstance() - : workerPool_; - } - } - /** - * - * - *
-     * Required. The `WorkerPool` to update.
-     * The `name` field is used to identify the `WorkerPool` to update.
-     * Format: `projects/{project}/locations/{location}/workerPools/{workerPool}`.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.WorkerPool worker_pool = 1 [(.google.api.field_behavior) = REQUIRED]; - * - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.WorkerPool, - com.google.cloudbuild.v1.WorkerPool.Builder, - com.google.cloudbuild.v1.WorkerPoolOrBuilder> - getWorkerPoolFieldBuilder() { - if (workerPoolBuilder_ == null) { - workerPoolBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.WorkerPool, - com.google.cloudbuild.v1.WorkerPool.Builder, - com.google.cloudbuild.v1.WorkerPoolOrBuilder>( - getWorkerPool(), getParentForChildren(), isClean()); - workerPool_ = null; - } - return workerPoolBuilder_; - } - - private com.google.protobuf.FieldMask updateMask_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.FieldMask, - com.google.protobuf.FieldMask.Builder, - com.google.protobuf.FieldMaskOrBuilder> - updateMaskBuilder_; - /** - * - * - *
-     * A mask specifying which fields in `worker_pool` to update.
-     * 
- * - * .google.protobuf.FieldMask update_mask = 2; - * - * @return Whether the updateMask field is set. - */ - public boolean hasUpdateMask() { - return updateMaskBuilder_ != null || updateMask_ != null; - } - /** - * - * - *
-     * A mask specifying which fields in `worker_pool` to update.
-     * 
- * - * .google.protobuf.FieldMask update_mask = 2; - * - * @return The updateMask. - */ - public com.google.protobuf.FieldMask getUpdateMask() { - if (updateMaskBuilder_ == null) { - return updateMask_ == null - ? com.google.protobuf.FieldMask.getDefaultInstance() - : updateMask_; - } else { - return updateMaskBuilder_.getMessage(); - } - } - /** - * - * - *
-     * A mask specifying which fields in `worker_pool` to update.
-     * 
- * - * .google.protobuf.FieldMask update_mask = 2; - */ - public Builder setUpdateMask(com.google.protobuf.FieldMask value) { - if (updateMaskBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - updateMask_ = value; - onChanged(); - } else { - updateMaskBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * A mask specifying which fields in `worker_pool` to update.
-     * 
- * - * .google.protobuf.FieldMask update_mask = 2; - */ - public Builder setUpdateMask(com.google.protobuf.FieldMask.Builder builderForValue) { - if (updateMaskBuilder_ == null) { - updateMask_ = builderForValue.build(); - onChanged(); - } else { - updateMaskBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * A mask specifying which fields in `worker_pool` to update.
-     * 
- * - * .google.protobuf.FieldMask update_mask = 2; - */ - public Builder mergeUpdateMask(com.google.protobuf.FieldMask value) { - if (updateMaskBuilder_ == null) { - if (updateMask_ != null) { - updateMask_ = - com.google.protobuf.FieldMask.newBuilder(updateMask_).mergeFrom(value).buildPartial(); - } else { - updateMask_ = value; - } - onChanged(); - } else { - updateMaskBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * A mask specifying which fields in `worker_pool` to update.
-     * 
- * - * .google.protobuf.FieldMask update_mask = 2; - */ - public Builder clearUpdateMask() { - if (updateMaskBuilder_ == null) { - updateMask_ = null; - onChanged(); - } else { - updateMask_ = null; - updateMaskBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * A mask specifying which fields in `worker_pool` to update.
-     * 
- * - * .google.protobuf.FieldMask update_mask = 2; - */ - public com.google.protobuf.FieldMask.Builder getUpdateMaskBuilder() { - - onChanged(); - return getUpdateMaskFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * A mask specifying which fields in `worker_pool` to update.
-     * 
- * - * .google.protobuf.FieldMask update_mask = 2; - */ - public com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder() { - if (updateMaskBuilder_ != null) { - return updateMaskBuilder_.getMessageOrBuilder(); - } else { - return updateMask_ == null - ? com.google.protobuf.FieldMask.getDefaultInstance() - : updateMask_; - } - } - /** - * - * - *
-     * A mask specifying which fields in `worker_pool` to update.
-     * 
- * - * .google.protobuf.FieldMask update_mask = 2; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.FieldMask, - com.google.protobuf.FieldMask.Builder, - com.google.protobuf.FieldMaskOrBuilder> - getUpdateMaskFieldBuilder() { - if (updateMaskBuilder_ == null) { - updateMaskBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.FieldMask, - com.google.protobuf.FieldMask.Builder, - com.google.protobuf.FieldMaskOrBuilder>( - getUpdateMask(), getParentForChildren(), isClean()); - updateMask_ = null; - } - return updateMaskBuilder_; - } - - private boolean validateOnly_; - /** - * - * - *
-     * If set, validate the request and preview the response, but do not actually
-     * post it.
-     * 
- * - * bool validate_only = 4; - * - * @return The validateOnly. - */ - @java.lang.Override - public boolean getValidateOnly() { - return validateOnly_; - } - /** - * - * - *
-     * If set, validate the request and preview the response, but do not actually
-     * post it.
-     * 
- * - * bool validate_only = 4; - * - * @param value The validateOnly to set. - * @return This builder for chaining. - */ - public Builder setValidateOnly(boolean value) { - - validateOnly_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * If set, validate the request and preview the response, but do not actually
-     * post it.
-     * 
- * - * bool validate_only = 4; - * - * @return This builder for chaining. - */ - public Builder clearValidateOnly() { - - validateOnly_ = false; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.UpdateWorkerPoolRequest) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.UpdateWorkerPoolRequest) - private static final com.google.cloudbuild.v1.UpdateWorkerPoolRequest DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.UpdateWorkerPoolRequest(); - } - - public static com.google.cloudbuild.v1.UpdateWorkerPoolRequest getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public UpdateWorkerPoolRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.UpdateWorkerPoolRequest getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/UpdateWorkerPoolRequestOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/UpdateWorkerPoolRequestOrBuilder.java deleted file mode 100644 index cf0279aa..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/UpdateWorkerPoolRequestOrBuilder.java +++ /dev/null @@ -1,121 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface UpdateWorkerPoolRequestOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.UpdateWorkerPoolRequest) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * Required. The `WorkerPool` to update.
-   * The `name` field is used to identify the `WorkerPool` to update.
-   * Format: `projects/{project}/locations/{location}/workerPools/{workerPool}`.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.WorkerPool worker_pool = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * - * @return Whether the workerPool field is set. - */ - boolean hasWorkerPool(); - /** - * - * - *
-   * Required. The `WorkerPool` to update.
-   * The `name` field is used to identify the `WorkerPool` to update.
-   * Format: `projects/{project}/locations/{location}/workerPools/{workerPool}`.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.WorkerPool worker_pool = 1 [(.google.api.field_behavior) = REQUIRED]; - * - * - * @return The workerPool. - */ - com.google.cloudbuild.v1.WorkerPool getWorkerPool(); - /** - * - * - *
-   * Required. The `WorkerPool` to update.
-   * The `name` field is used to identify the `WorkerPool` to update.
-   * Format: `projects/{project}/locations/{location}/workerPools/{workerPool}`.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.WorkerPool worker_pool = 1 [(.google.api.field_behavior) = REQUIRED]; - * - */ - com.google.cloudbuild.v1.WorkerPoolOrBuilder getWorkerPoolOrBuilder(); - - /** - * - * - *
-   * A mask specifying which fields in `worker_pool` to update.
-   * 
- * - * .google.protobuf.FieldMask update_mask = 2; - * - * @return Whether the updateMask field is set. - */ - boolean hasUpdateMask(); - /** - * - * - *
-   * A mask specifying which fields in `worker_pool` to update.
-   * 
- * - * .google.protobuf.FieldMask update_mask = 2; - * - * @return The updateMask. - */ - com.google.protobuf.FieldMask getUpdateMask(); - /** - * - * - *
-   * A mask specifying which fields in `worker_pool` to update.
-   * 
- * - * .google.protobuf.FieldMask update_mask = 2; - */ - com.google.protobuf.FieldMaskOrBuilder getUpdateMaskOrBuilder(); - - /** - * - * - *
-   * If set, validate the request and preview the response, but do not actually
-   * post it.
-   * 
- * - * bool validate_only = 4; - * - * @return The validateOnly. - */ - boolean getValidateOnly(); -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Volume.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Volume.java deleted file mode 100644 index 68bc60e7..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Volume.java +++ /dev/null @@ -1,817 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * Volume describes a Docker container volume which is mounted into build steps
- * in order to persist files across build step execution.
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.Volume} - */ -public final class Volume extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.Volume) - VolumeOrBuilder { - private static final long serialVersionUID = 0L; - // Use Volume.newBuilder() to construct. - private Volume(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private Volume() { - name_ = ""; - path_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new Volume(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Volume_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Volume_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.Volume.class, com.google.cloudbuild.v1.Volume.Builder.class); - } - - public static final int NAME_FIELD_NUMBER = 1; - private volatile java.lang.Object name_; - /** - * - * - *
-   * Name of the volume to mount.
-   * Volume names must be unique per build step and must be valid names for
-   * Docker volumes. Each named volume must be used by at least two build steps.
-   * 
- * - * string name = 1; - * - * @return The name. - */ - @java.lang.Override - public java.lang.String getName() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - name_ = s; - return s; - } - } - /** - * - * - *
-   * Name of the volume to mount.
-   * Volume names must be unique per build step and must be valid names for
-   * Docker volumes. Each named volume must be used by at least two build steps.
-   * 
- * - * string name = 1; - * - * @return The bytes for name. - */ - @java.lang.Override - public com.google.protobuf.ByteString getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int PATH_FIELD_NUMBER = 2; - private volatile java.lang.Object path_; - /** - * - * - *
-   * Path at which to mount the volume.
-   * Paths must be absolute and cannot conflict with other volume paths on the
-   * same build step or with certain reserved volume paths.
-   * 
- * - * string path = 2; - * - * @return The path. - */ - @java.lang.Override - public java.lang.String getPath() { - java.lang.Object ref = path_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - path_ = s; - return s; - } - } - /** - * - * - *
-   * Path at which to mount the volume.
-   * Paths must be absolute and cannot conflict with other volume paths on the
-   * same build step or with certain reserved volume paths.
-   * 
- * - * string path = 2; - * - * @return The bytes for path. - */ - @java.lang.Override - public com.google.protobuf.ByteString getPathBytes() { - java.lang.Object ref = path_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - path_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(path_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, path_); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(path_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, path_); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.Volume)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.Volume other = (com.google.cloudbuild.v1.Volume) obj; - - if (!getName().equals(other.getName())) return false; - if (!getPath().equals(other.getPath())) return false; - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + NAME_FIELD_NUMBER; - hash = (53 * hash) + getName().hashCode(); - hash = (37 * hash) + PATH_FIELD_NUMBER; - hash = (53 * hash) + getPath().hashCode(); - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.Volume parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.Volume parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.Volume parseFrom(com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.Volume parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.Volume parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.Volume parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.Volume parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.Volume parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.Volume parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.Volume parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.Volume parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.Volume parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.Volume prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * Volume describes a Docker container volume which is mounted into build steps
-   * in order to persist files across build step execution.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.Volume} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.Volume) - com.google.cloudbuild.v1.VolumeOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Volume_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Volume_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.Volume.class, com.google.cloudbuild.v1.Volume.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.Volume.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - name_ = ""; - - path_ = ""; - - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_Volume_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.Volume getDefaultInstanceForType() { - return com.google.cloudbuild.v1.Volume.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.Volume build() { - com.google.cloudbuild.v1.Volume result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.Volume buildPartial() { - com.google.cloudbuild.v1.Volume result = new com.google.cloudbuild.v1.Volume(this); - result.name_ = name_; - result.path_ = path_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.Volume) { - return mergeFrom((com.google.cloudbuild.v1.Volume) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.Volume other) { - if (other == com.google.cloudbuild.v1.Volume.getDefaultInstance()) return this; - if (!other.getName().isEmpty()) { - name_ = other.name_; - onChanged(); - } - if (!other.getPath().isEmpty()) { - path_ = other.path_; - onChanged(); - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - name_ = input.readStringRequireUtf8(); - - break; - } // case 10 - case 18: - { - path_ = input.readStringRequireUtf8(); - - break; - } // case 18 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private java.lang.Object name_ = ""; - /** - * - * - *
-     * Name of the volume to mount.
-     * Volume names must be unique per build step and must be valid names for
-     * Docker volumes. Each named volume must be used by at least two build steps.
-     * 
- * - * string name = 1; - * - * @return The name. - */ - public java.lang.String getName() { - java.lang.Object ref = name_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - name_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Name of the volume to mount.
-     * Volume names must be unique per build step and must be valid names for
-     * Docker volumes. Each named volume must be used by at least two build steps.
-     * 
- * - * string name = 1; - * - * @return The bytes for name. - */ - public com.google.protobuf.ByteString getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Name of the volume to mount.
-     * Volume names must be unique per build step and must be valid names for
-     * Docker volumes. Each named volume must be used by at least two build steps.
-     * 
- * - * string name = 1; - * - * @param value The name to set. - * @return This builder for chaining. - */ - public Builder setName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - name_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Name of the volume to mount.
-     * Volume names must be unique per build step and must be valid names for
-     * Docker volumes. Each named volume must be used by at least two build steps.
-     * 
- * - * string name = 1; - * - * @return This builder for chaining. - */ - public Builder clearName() { - - name_ = getDefaultInstance().getName(); - onChanged(); - return this; - } - /** - * - * - *
-     * Name of the volume to mount.
-     * Volume names must be unique per build step and must be valid names for
-     * Docker volumes. Each named volume must be used by at least two build steps.
-     * 
- * - * string name = 1; - * - * @param value The bytes for name to set. - * @return This builder for chaining. - */ - public Builder setNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - name_ = value; - onChanged(); - return this; - } - - private java.lang.Object path_ = ""; - /** - * - * - *
-     * Path at which to mount the volume.
-     * Paths must be absolute and cannot conflict with other volume paths on the
-     * same build step or with certain reserved volume paths.
-     * 
- * - * string path = 2; - * - * @return The path. - */ - public java.lang.String getPath() { - java.lang.Object ref = path_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - path_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Path at which to mount the volume.
-     * Paths must be absolute and cannot conflict with other volume paths on the
-     * same build step or with certain reserved volume paths.
-     * 
- * - * string path = 2; - * - * @return The bytes for path. - */ - public com.google.protobuf.ByteString getPathBytes() { - java.lang.Object ref = path_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - path_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Path at which to mount the volume.
-     * Paths must be absolute and cannot conflict with other volume paths on the
-     * same build step or with certain reserved volume paths.
-     * 
- * - * string path = 2; - * - * @param value The path to set. - * @return This builder for chaining. - */ - public Builder setPath(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - path_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Path at which to mount the volume.
-     * Paths must be absolute and cannot conflict with other volume paths on the
-     * same build step or with certain reserved volume paths.
-     * 
- * - * string path = 2; - * - * @return This builder for chaining. - */ - public Builder clearPath() { - - path_ = getDefaultInstance().getPath(); - onChanged(); - return this; - } - /** - * - * - *
-     * Path at which to mount the volume.
-     * Paths must be absolute and cannot conflict with other volume paths on the
-     * same build step or with certain reserved volume paths.
-     * 
- * - * string path = 2; - * - * @param value The bytes for path to set. - * @return This builder for chaining. - */ - public Builder setPathBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - path_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.Volume) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.Volume) - private static final com.google.cloudbuild.v1.Volume DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.Volume(); - } - - public static com.google.cloudbuild.v1.Volume getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public Volume parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.Volume getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/VolumeOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/VolumeOrBuilder.java deleted file mode 100644 index c6c6bc60..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/VolumeOrBuilder.java +++ /dev/null @@ -1,83 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface VolumeOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.Volume) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * Name of the volume to mount.
-   * Volume names must be unique per build step and must be valid names for
-   * Docker volumes. Each named volume must be used by at least two build steps.
-   * 
- * - * string name = 1; - * - * @return The name. - */ - java.lang.String getName(); - /** - * - * - *
-   * Name of the volume to mount.
-   * Volume names must be unique per build step and must be valid names for
-   * Docker volumes. Each named volume must be used by at least two build steps.
-   * 
- * - * string name = 1; - * - * @return The bytes for name. - */ - com.google.protobuf.ByteString getNameBytes(); - - /** - * - * - *
-   * Path at which to mount the volume.
-   * Paths must be absolute and cannot conflict with other volume paths on the
-   * same build step or with certain reserved volume paths.
-   * 
- * - * string path = 2; - * - * @return The path. - */ - java.lang.String getPath(); - /** - * - * - *
-   * Path at which to mount the volume.
-   * Paths must be absolute and cannot conflict with other volume paths on the
-   * same build step or with certain reserved volume paths.
-   * 
- * - * string path = 2; - * - * @return The bytes for path. - */ - com.google.protobuf.ByteString getPathBytes(); -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/WebhookConfig.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/WebhookConfig.java deleted file mode 100644 index 6ea37005..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/WebhookConfig.java +++ /dev/null @@ -1,1079 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * WebhookConfig describes the configuration of a trigger that
- * creates a build whenever a webhook is sent to a trigger's webhook URL.
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.WebhookConfig} - */ -public final class WebhookConfig extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.WebhookConfig) - WebhookConfigOrBuilder { - private static final long serialVersionUID = 0L; - // Use WebhookConfig.newBuilder() to construct. - private WebhookConfig(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private WebhookConfig() { - state_ = 0; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new WebhookConfig(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_WebhookConfig_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_WebhookConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.WebhookConfig.class, - com.google.cloudbuild.v1.WebhookConfig.Builder.class); - } - - /** - * - * - *
-   * Enumerates potential issues with the Secret Manager secret provided by the
-   * user.
-   * 
- * - * Protobuf enum {@code google.devtools.cloudbuild.v1.WebhookConfig.State} - */ - public enum State implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
-     * The webhook auth configuration not been checked.
-     * 
- * - * STATE_UNSPECIFIED = 0; - */ - STATE_UNSPECIFIED(0), - /** - * - * - *
-     * The auth configuration is properly setup.
-     * 
- * - * OK = 1; - */ - OK(1), - /** - * - * - *
-     * The secret provided in auth_method has been deleted.
-     * 
- * - * SECRET_DELETED = 2; - */ - SECRET_DELETED(2), - UNRECOGNIZED(-1), - ; - - /** - * - * - *
-     * The webhook auth configuration not been checked.
-     * 
- * - * STATE_UNSPECIFIED = 0; - */ - public static final int STATE_UNSPECIFIED_VALUE = 0; - /** - * - * - *
-     * The auth configuration is properly setup.
-     * 
- * - * OK = 1; - */ - public static final int OK_VALUE = 1; - /** - * - * - *
-     * The secret provided in auth_method has been deleted.
-     * 
- * - * SECRET_DELETED = 2; - */ - public static final int SECRET_DELETED_VALUE = 2; - - public final int getNumber() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalArgumentException( - "Can't get the number of an unknown enum value."); - } - return value; - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static State valueOf(int value) { - return forNumber(value); - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - */ - public static State forNumber(int value) { - switch (value) { - case 0: - return STATE_UNSPECIFIED; - case 1: - return OK; - case 2: - return SECRET_DELETED; - default: - return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { - return internalValueMap; - } - - private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public State findValueByNumber(int number) { - return State.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalStateException( - "Can't get the descriptor of an unrecognized enum value."); - } - return getDescriptor().getValues().get(ordinal()); - } - - public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { - return getDescriptor(); - } - - public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return com.google.cloudbuild.v1.WebhookConfig.getDescriptor().getEnumTypes().get(0); - } - - private static final State[] VALUES = values(); - - public static State valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); - } - if (desc.getIndex() == -1) { - return UNRECOGNIZED; - } - return VALUES[desc.getIndex()]; - } - - private final int value; - - private State(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:google.devtools.cloudbuild.v1.WebhookConfig.State) - } - - private int authMethodCase_ = 0; - private java.lang.Object authMethod_; - - public enum AuthMethodCase - implements - com.google.protobuf.Internal.EnumLite, - com.google.protobuf.AbstractMessage.InternalOneOfEnum { - SECRET(3), - AUTHMETHOD_NOT_SET(0); - private final int value; - - private AuthMethodCase(int value) { - this.value = value; - } - /** - * @param value The number of the enum to look for. - * @return The enum associated with the given number. - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static AuthMethodCase valueOf(int value) { - return forNumber(value); - } - - public static AuthMethodCase forNumber(int value) { - switch (value) { - case 3: - return SECRET; - case 0: - return AUTHMETHOD_NOT_SET; - default: - return null; - } - } - - public int getNumber() { - return this.value; - } - }; - - public AuthMethodCase getAuthMethodCase() { - return AuthMethodCase.forNumber(authMethodCase_); - } - - public static final int SECRET_FIELD_NUMBER = 3; - /** - * - * - *
-   * Required. Resource name for the secret required as a URL parameter.
-   * 
- * - * - * string secret = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return Whether the secret field is set. - */ - public boolean hasSecret() { - return authMethodCase_ == 3; - } - /** - * - * - *
-   * Required. Resource name for the secret required as a URL parameter.
-   * 
- * - * - * string secret = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return The secret. - */ - public java.lang.String getSecret() { - java.lang.Object ref = ""; - if (authMethodCase_ == 3) { - ref = authMethod_; - } - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (authMethodCase_ == 3) { - authMethod_ = s; - } - return s; - } - } - /** - * - * - *
-   * Required. Resource name for the secret required as a URL parameter.
-   * 
- * - * - * string secret = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return The bytes for secret. - */ - public com.google.protobuf.ByteString getSecretBytes() { - java.lang.Object ref = ""; - if (authMethodCase_ == 3) { - ref = authMethod_; - } - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - if (authMethodCase_ == 3) { - authMethod_ = b; - } - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int STATE_FIELD_NUMBER = 4; - private int state_; - /** - * - * - *
-   * Potential issues with the underlying Pub/Sub subscription configuration.
-   * Only populated on get requests.
-   * 
- * - * .google.devtools.cloudbuild.v1.WebhookConfig.State state = 4; - * - * @return The enum numeric value on the wire for state. - */ - @java.lang.Override - public int getStateValue() { - return state_; - } - /** - * - * - *
-   * Potential issues with the underlying Pub/Sub subscription configuration.
-   * Only populated on get requests.
-   * 
- * - * .google.devtools.cloudbuild.v1.WebhookConfig.State state = 4; - * - * @return The state. - */ - @java.lang.Override - public com.google.cloudbuild.v1.WebhookConfig.State getState() { - @SuppressWarnings("deprecation") - com.google.cloudbuild.v1.WebhookConfig.State result = - com.google.cloudbuild.v1.WebhookConfig.State.valueOf(state_); - return result == null ? com.google.cloudbuild.v1.WebhookConfig.State.UNRECOGNIZED : result; - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (authMethodCase_ == 3) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 3, authMethod_); - } - if (state_ != com.google.cloudbuild.v1.WebhookConfig.State.STATE_UNSPECIFIED.getNumber()) { - output.writeEnum(4, state_); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (authMethodCase_ == 3) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, authMethod_); - } - if (state_ != com.google.cloudbuild.v1.WebhookConfig.State.STATE_UNSPECIFIED.getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(4, state_); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.WebhookConfig)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.WebhookConfig other = (com.google.cloudbuild.v1.WebhookConfig) obj; - - if (state_ != other.state_) return false; - if (!getAuthMethodCase().equals(other.getAuthMethodCase())) return false; - switch (authMethodCase_) { - case 3: - if (!getSecret().equals(other.getSecret())) return false; - break; - case 0: - default: - } - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + STATE_FIELD_NUMBER; - hash = (53 * hash) + state_; - switch (authMethodCase_) { - case 3: - hash = (37 * hash) + SECRET_FIELD_NUMBER; - hash = (53 * hash) + getSecret().hashCode(); - break; - case 0: - default: - } - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.WebhookConfig parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.WebhookConfig parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.WebhookConfig parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.WebhookConfig parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.WebhookConfig parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.WebhookConfig parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.WebhookConfig parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.WebhookConfig parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.WebhookConfig parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.WebhookConfig parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.WebhookConfig parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.WebhookConfig parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.WebhookConfig prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * WebhookConfig describes the configuration of a trigger that
-   * creates a build whenever a webhook is sent to a trigger's webhook URL.
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.WebhookConfig} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.WebhookConfig) - com.google.cloudbuild.v1.WebhookConfigOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_WebhookConfig_descriptor; - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_WebhookConfig_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.WebhookConfig.class, - com.google.cloudbuild.v1.WebhookConfig.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.WebhookConfig.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - state_ = 0; - - authMethodCase_ = 0; - authMethod_ = null; - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_WebhookConfig_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.WebhookConfig getDefaultInstanceForType() { - return com.google.cloudbuild.v1.WebhookConfig.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.WebhookConfig build() { - com.google.cloudbuild.v1.WebhookConfig result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.WebhookConfig buildPartial() { - com.google.cloudbuild.v1.WebhookConfig result = - new com.google.cloudbuild.v1.WebhookConfig(this); - if (authMethodCase_ == 3) { - result.authMethod_ = authMethod_; - } - result.state_ = state_; - result.authMethodCase_ = authMethodCase_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.WebhookConfig) { - return mergeFrom((com.google.cloudbuild.v1.WebhookConfig) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.WebhookConfig other) { - if (other == com.google.cloudbuild.v1.WebhookConfig.getDefaultInstance()) return this; - if (other.state_ != 0) { - setStateValue(other.getStateValue()); - } - switch (other.getAuthMethodCase()) { - case SECRET: - { - authMethodCase_ = 3; - authMethod_ = other.authMethod_; - onChanged(); - break; - } - case AUTHMETHOD_NOT_SET: - { - break; - } - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 26: - { - java.lang.String s = input.readStringRequireUtf8(); - authMethodCase_ = 3; - authMethod_ = s; - break; - } // case 26 - case 32: - { - state_ = input.readEnum(); - - break; - } // case 32 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private int authMethodCase_ = 0; - private java.lang.Object authMethod_; - - public AuthMethodCase getAuthMethodCase() { - return AuthMethodCase.forNumber(authMethodCase_); - } - - public Builder clearAuthMethod() { - authMethodCase_ = 0; - authMethod_ = null; - onChanged(); - return this; - } - - /** - * - * - *
-     * Required. Resource name for the secret required as a URL parameter.
-     * 
- * - * - * string secret = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return Whether the secret field is set. - */ - @java.lang.Override - public boolean hasSecret() { - return authMethodCase_ == 3; - } - /** - * - * - *
-     * Required. Resource name for the secret required as a URL parameter.
-     * 
- * - * - * string secret = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return The secret. - */ - @java.lang.Override - public java.lang.String getSecret() { - java.lang.Object ref = ""; - if (authMethodCase_ == 3) { - ref = authMethod_; - } - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (authMethodCase_ == 3) { - authMethod_ = s; - } - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Required. Resource name for the secret required as a URL parameter.
-     * 
- * - * - * string secret = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return The bytes for secret. - */ - @java.lang.Override - public com.google.protobuf.ByteString getSecretBytes() { - java.lang.Object ref = ""; - if (authMethodCase_ == 3) { - ref = authMethod_; - } - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - if (authMethodCase_ == 3) { - authMethod_ = b; - } - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Required. Resource name for the secret required as a URL parameter.
-     * 
- * - * - * string secret = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @param value The secret to set. - * @return This builder for chaining. - */ - public Builder setSecret(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - authMethodCase_ = 3; - authMethod_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Required. Resource name for the secret required as a URL parameter.
-     * 
- * - * - * string secret = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return This builder for chaining. - */ - public Builder clearSecret() { - if (authMethodCase_ == 3) { - authMethodCase_ = 0; - authMethod_ = null; - onChanged(); - } - return this; - } - /** - * - * - *
-     * Required. Resource name for the secret required as a URL parameter.
-     * 
- * - * - * string secret = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @param value The bytes for secret to set. - * @return This builder for chaining. - */ - public Builder setSecretBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - authMethodCase_ = 3; - authMethod_ = value; - onChanged(); - return this; - } - - private int state_ = 0; - /** - * - * - *
-     * Potential issues with the underlying Pub/Sub subscription configuration.
-     * Only populated on get requests.
-     * 
- * - * .google.devtools.cloudbuild.v1.WebhookConfig.State state = 4; - * - * @return The enum numeric value on the wire for state. - */ - @java.lang.Override - public int getStateValue() { - return state_; - } - /** - * - * - *
-     * Potential issues with the underlying Pub/Sub subscription configuration.
-     * Only populated on get requests.
-     * 
- * - * .google.devtools.cloudbuild.v1.WebhookConfig.State state = 4; - * - * @param value The enum numeric value on the wire for state to set. - * @return This builder for chaining. - */ - public Builder setStateValue(int value) { - - state_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Potential issues with the underlying Pub/Sub subscription configuration.
-     * Only populated on get requests.
-     * 
- * - * .google.devtools.cloudbuild.v1.WebhookConfig.State state = 4; - * - * @return The state. - */ - @java.lang.Override - public com.google.cloudbuild.v1.WebhookConfig.State getState() { - @SuppressWarnings("deprecation") - com.google.cloudbuild.v1.WebhookConfig.State result = - com.google.cloudbuild.v1.WebhookConfig.State.valueOf(state_); - return result == null ? com.google.cloudbuild.v1.WebhookConfig.State.UNRECOGNIZED : result; - } - /** - * - * - *
-     * Potential issues with the underlying Pub/Sub subscription configuration.
-     * Only populated on get requests.
-     * 
- * - * .google.devtools.cloudbuild.v1.WebhookConfig.State state = 4; - * - * @param value The state to set. - * @return This builder for chaining. - */ - public Builder setState(com.google.cloudbuild.v1.WebhookConfig.State value) { - if (value == null) { - throw new NullPointerException(); - } - - state_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-     * Potential issues with the underlying Pub/Sub subscription configuration.
-     * Only populated on get requests.
-     * 
- * - * .google.devtools.cloudbuild.v1.WebhookConfig.State state = 4; - * - * @return This builder for chaining. - */ - public Builder clearState() { - - state_ = 0; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.WebhookConfig) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.WebhookConfig) - private static final com.google.cloudbuild.v1.WebhookConfig DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.WebhookConfig(); - } - - public static com.google.cloudbuild.v1.WebhookConfig getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public WebhookConfig parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.WebhookConfig getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/WebhookConfigOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/WebhookConfigOrBuilder.java deleted file mode 100644 index 4d5816d4..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/WebhookConfigOrBuilder.java +++ /dev/null @@ -1,97 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface WebhookConfigOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.WebhookConfig) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * Required. Resource name for the secret required as a URL parameter.
-   * 
- * - * - * string secret = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return Whether the secret field is set. - */ - boolean hasSecret(); - /** - * - * - *
-   * Required. Resource name for the secret required as a URL parameter.
-   * 
- * - * - * string secret = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return The secret. - */ - java.lang.String getSecret(); - /** - * - * - *
-   * Required. Resource name for the secret required as a URL parameter.
-   * 
- * - * - * string secret = 3 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } - * - * - * @return The bytes for secret. - */ - com.google.protobuf.ByteString getSecretBytes(); - - /** - * - * - *
-   * Potential issues with the underlying Pub/Sub subscription configuration.
-   * Only populated on get requests.
-   * 
- * - * .google.devtools.cloudbuild.v1.WebhookConfig.State state = 4; - * - * @return The enum numeric value on the wire for state. - */ - int getStateValue(); - /** - * - * - *
-   * Potential issues with the underlying Pub/Sub subscription configuration.
-   * Only populated on get requests.
-   * 
- * - * .google.devtools.cloudbuild.v1.WebhookConfig.State state = 4; - * - * @return The state. - */ - com.google.cloudbuild.v1.WebhookConfig.State getState(); - - public com.google.cloudbuild.v1.WebhookConfig.AuthMethodCase getAuthMethodCase(); -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/WorkerPool.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/WorkerPool.java deleted file mode 100644 index 8f38b614..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/WorkerPool.java +++ /dev/null @@ -1,3178 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -/** - * - * - *
- * Configuration for a `WorkerPool`.
- * Cloud Build owns and maintains a pool of workers for general use and have no
- * access to a project's private network. By default, builds submitted to
- * Cloud Build will use a worker from this pool.
- * If your build needs access to resources on a private network,
- * create and use a `WorkerPool` to run your builds. Private `WorkerPool`s give
- * your builds access to any single VPC network that you
- * administer, including any on-prem resources connected to that VPC
- * network. For an overview of private pools, see
- * [Private pools
- * overview](https://cloud.google.com/build/docs/private-pools/private-pools-overview).
- * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.WorkerPool} - */ -public final class WorkerPool extends com.google.protobuf.GeneratedMessageV3 - implements - // @@protoc_insertion_point(message_implements:google.devtools.cloudbuild.v1.WorkerPool) - WorkerPoolOrBuilder { - private static final long serialVersionUID = 0L; - // Use WorkerPool.newBuilder() to construct. - private WorkerPool(com.google.protobuf.GeneratedMessageV3.Builder builder) { - super(builder); - } - - private WorkerPool() { - name_ = ""; - displayName_ = ""; - uid_ = ""; - state_ = 0; - etag_ = ""; - } - - @java.lang.Override - @SuppressWarnings({"unused"}) - protected java.lang.Object newInstance(UnusedPrivateParameter unused) { - return new WorkerPool(); - } - - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet getUnknownFields() { - return this.unknownFields; - } - - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_WorkerPool_descriptor; - } - - @SuppressWarnings({"rawtypes"}) - @java.lang.Override - protected com.google.protobuf.MapField internalGetMapField(int number) { - switch (number) { - case 4: - return internalGetAnnotations(); - default: - throw new RuntimeException("Invalid map field number: " + number); - } - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_WorkerPool_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.WorkerPool.class, - com.google.cloudbuild.v1.WorkerPool.Builder.class); - } - - /** - * - * - *
-   * State of the `WorkerPool`.
-   * 
- * - * Protobuf enum {@code google.devtools.cloudbuild.v1.WorkerPool.State} - */ - public enum State implements com.google.protobuf.ProtocolMessageEnum { - /** - * - * - *
-     * State of the `WorkerPool` is unknown.
-     * 
- * - * STATE_UNSPECIFIED = 0; - */ - STATE_UNSPECIFIED(0), - /** - * - * - *
-     * `WorkerPool` is being created.
-     * 
- * - * CREATING = 1; - */ - CREATING(1), - /** - * - * - *
-     * `WorkerPool` is running.
-     * 
- * - * RUNNING = 2; - */ - RUNNING(2), - /** - * - * - *
-     * `WorkerPool` is being deleted: cancelling builds and draining workers.
-     * 
- * - * DELETING = 3; - */ - DELETING(3), - /** - * - * - *
-     * `WorkerPool` is deleted.
-     * 
- * - * DELETED = 4; - */ - DELETED(4), - UNRECOGNIZED(-1), - ; - - /** - * - * - *
-     * State of the `WorkerPool` is unknown.
-     * 
- * - * STATE_UNSPECIFIED = 0; - */ - public static final int STATE_UNSPECIFIED_VALUE = 0; - /** - * - * - *
-     * `WorkerPool` is being created.
-     * 
- * - * CREATING = 1; - */ - public static final int CREATING_VALUE = 1; - /** - * - * - *
-     * `WorkerPool` is running.
-     * 
- * - * RUNNING = 2; - */ - public static final int RUNNING_VALUE = 2; - /** - * - * - *
-     * `WorkerPool` is being deleted: cancelling builds and draining workers.
-     * 
- * - * DELETING = 3; - */ - public static final int DELETING_VALUE = 3; - /** - * - * - *
-     * `WorkerPool` is deleted.
-     * 
- * - * DELETED = 4; - */ - public static final int DELETED_VALUE = 4; - - public final int getNumber() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalArgumentException( - "Can't get the number of an unknown enum value."); - } - return value; - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static State valueOf(int value) { - return forNumber(value); - } - - /** - * @param value The numeric wire value of the corresponding enum entry. - * @return The enum associated with the given numeric wire value. - */ - public static State forNumber(int value) { - switch (value) { - case 0: - return STATE_UNSPECIFIED; - case 1: - return CREATING; - case 2: - return RUNNING; - case 3: - return DELETING; - case 4: - return DELETED; - default: - return null; - } - } - - public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { - return internalValueMap; - } - - private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public State findValueByNumber(int number) { - return State.forNumber(number); - } - }; - - public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { - if (this == UNRECOGNIZED) { - throw new java.lang.IllegalStateException( - "Can't get the descriptor of an unrecognized enum value."); - } - return getDescriptor().getValues().get(ordinal()); - } - - public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { - return getDescriptor(); - } - - public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { - return com.google.cloudbuild.v1.WorkerPool.getDescriptor().getEnumTypes().get(0); - } - - private static final State[] VALUES = values(); - - public static State valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { - if (desc.getType() != getDescriptor()) { - throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); - } - if (desc.getIndex() == -1) { - return UNRECOGNIZED; - } - return VALUES[desc.getIndex()]; - } - - private final int value; - - private State(int value) { - this.value = value; - } - - // @@protoc_insertion_point(enum_scope:google.devtools.cloudbuild.v1.WorkerPool.State) - } - - private int configCase_ = 0; - private java.lang.Object config_; - - public enum ConfigCase - implements - com.google.protobuf.Internal.EnumLite, - com.google.protobuf.AbstractMessage.InternalOneOfEnum { - PRIVATE_POOL_V1_CONFIG(12), - CONFIG_NOT_SET(0); - private final int value; - - private ConfigCase(int value) { - this.value = value; - } - /** - * @param value The number of the enum to look for. - * @return The enum associated with the given number. - * @deprecated Use {@link #forNumber(int)} instead. - */ - @java.lang.Deprecated - public static ConfigCase valueOf(int value) { - return forNumber(value); - } - - public static ConfigCase forNumber(int value) { - switch (value) { - case 12: - return PRIVATE_POOL_V1_CONFIG; - case 0: - return CONFIG_NOT_SET; - default: - return null; - } - } - - public int getNumber() { - return this.value; - } - }; - - public ConfigCase getConfigCase() { - return ConfigCase.forNumber(configCase_); - } - - public static final int NAME_FIELD_NUMBER = 1; - private volatile java.lang.Object name_; - /** - * - * - *
-   * Output only. The resource name of the `WorkerPool`, with format
-   * `projects/{project}/locations/{location}/workerPools/{worker_pool}`.
-   * The value of `{worker_pool}` is provided by `worker_pool_id` in
-   * `CreateWorkerPool` request and the value of `{location}` is determined by
-   * the endpoint accessed.
-   * 
- * - * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The name. - */ - @java.lang.Override - public java.lang.String getName() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - name_ = s; - return s; - } - } - /** - * - * - *
-   * Output only. The resource name of the `WorkerPool`, with format
-   * `projects/{project}/locations/{location}/workerPools/{worker_pool}`.
-   * The value of `{worker_pool}` is provided by `worker_pool_id` in
-   * `CreateWorkerPool` request and the value of `{location}` is determined by
-   * the endpoint accessed.
-   * 
- * - * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The bytes for name. - */ - @java.lang.Override - public com.google.protobuf.ByteString getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int DISPLAY_NAME_FIELD_NUMBER = 2; - private volatile java.lang.Object displayName_; - /** - * - * - *
-   * A user-specified, human-readable name for the `WorkerPool`. If provided,
-   * this value must be 1-63 characters.
-   * 
- * - * string display_name = 2; - * - * @return The displayName. - */ - @java.lang.Override - public java.lang.String getDisplayName() { - java.lang.Object ref = displayName_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - displayName_ = s; - return s; - } - } - /** - * - * - *
-   * A user-specified, human-readable name for the `WorkerPool`. If provided,
-   * this value must be 1-63 characters.
-   * 
- * - * string display_name = 2; - * - * @return The bytes for displayName. - */ - @java.lang.Override - public com.google.protobuf.ByteString getDisplayNameBytes() { - java.lang.Object ref = displayName_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - displayName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int UID_FIELD_NUMBER = 3; - private volatile java.lang.Object uid_; - /** - * - * - *
-   * Output only. A unique identifier for the `WorkerPool`.
-   * 
- * - * string uid = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The uid. - */ - @java.lang.Override - public java.lang.String getUid() { - java.lang.Object ref = uid_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - uid_ = s; - return s; - } - } - /** - * - * - *
-   * Output only. A unique identifier for the `WorkerPool`.
-   * 
- * - * string uid = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The bytes for uid. - */ - @java.lang.Override - public com.google.protobuf.ByteString getUidBytes() { - java.lang.Object ref = uid_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - uid_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - public static final int ANNOTATIONS_FIELD_NUMBER = 4; - - private static final class AnnotationsDefaultEntryHolder { - static final com.google.protobuf.MapEntry defaultEntry = - com.google.protobuf.MapEntry.newDefaultInstance( - com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_WorkerPool_AnnotationsEntry_descriptor, - com.google.protobuf.WireFormat.FieldType.STRING, - "", - com.google.protobuf.WireFormat.FieldType.STRING, - ""); - } - - private com.google.protobuf.MapField annotations_; - - private com.google.protobuf.MapField - internalGetAnnotations() { - if (annotations_ == null) { - return com.google.protobuf.MapField.emptyMapField(AnnotationsDefaultEntryHolder.defaultEntry); - } - return annotations_; - } - - public int getAnnotationsCount() { - return internalGetAnnotations().getMap().size(); - } - /** - * - * - *
-   * User specified annotations. See https://google.aip.dev/128#annotations
-   * for more details such as format and size limitations.
-   * 
- * - * map<string, string> annotations = 4; - */ - @java.lang.Override - public boolean containsAnnotations(java.lang.String key) { - if (key == null) { - throw new NullPointerException("map key"); - } - return internalGetAnnotations().getMap().containsKey(key); - } - /** Use {@link #getAnnotationsMap()} instead. */ - @java.lang.Override - @java.lang.Deprecated - public java.util.Map getAnnotations() { - return getAnnotationsMap(); - } - /** - * - * - *
-   * User specified annotations. See https://google.aip.dev/128#annotations
-   * for more details such as format and size limitations.
-   * 
- * - * map<string, string> annotations = 4; - */ - @java.lang.Override - public java.util.Map getAnnotationsMap() { - return internalGetAnnotations().getMap(); - } - /** - * - * - *
-   * User specified annotations. See https://google.aip.dev/128#annotations
-   * for more details such as format and size limitations.
-   * 
- * - * map<string, string> annotations = 4; - */ - @java.lang.Override - public java.lang.String getAnnotationsOrDefault( - java.lang.String key, java.lang.String defaultValue) { - if (key == null) { - throw new NullPointerException("map key"); - } - java.util.Map map = internalGetAnnotations().getMap(); - return map.containsKey(key) ? map.get(key) : defaultValue; - } - /** - * - * - *
-   * User specified annotations. See https://google.aip.dev/128#annotations
-   * for more details such as format and size limitations.
-   * 
- * - * map<string, string> annotations = 4; - */ - @java.lang.Override - public java.lang.String getAnnotationsOrThrow(java.lang.String key) { - if (key == null) { - throw new NullPointerException("map key"); - } - java.util.Map map = internalGetAnnotations().getMap(); - if (!map.containsKey(key)) { - throw new java.lang.IllegalArgumentException(); - } - return map.get(key); - } - - public static final int CREATE_TIME_FIELD_NUMBER = 5; - private com.google.protobuf.Timestamp createTime_; - /** - * - * - *
-   * Output only. Time at which the request to create the `WorkerPool` was
-   * received.
-   * 
- * - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return Whether the createTime field is set. - */ - @java.lang.Override - public boolean hasCreateTime() { - return createTime_ != null; - } - /** - * - * - *
-   * Output only. Time at which the request to create the `WorkerPool` was
-   * received.
-   * 
- * - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The createTime. - */ - @java.lang.Override - public com.google.protobuf.Timestamp getCreateTime() { - return createTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : createTime_; - } - /** - * - * - *
-   * Output only. Time at which the request to create the `WorkerPool` was
-   * received.
-   * 
- * - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - @java.lang.Override - public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { - return getCreateTime(); - } - - public static final int UPDATE_TIME_FIELD_NUMBER = 6; - private com.google.protobuf.Timestamp updateTime_; - /** - * - * - *
-   * Output only. Time at which the request to update the `WorkerPool` was
-   * received.
-   * 
- * - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return Whether the updateTime field is set. - */ - @java.lang.Override - public boolean hasUpdateTime() { - return updateTime_ != null; - } - /** - * - * - *
-   * Output only. Time at which the request to update the `WorkerPool` was
-   * received.
-   * 
- * - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The updateTime. - */ - @java.lang.Override - public com.google.protobuf.Timestamp getUpdateTime() { - return updateTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : updateTime_; - } - /** - * - * - *
-   * Output only. Time at which the request to update the `WorkerPool` was
-   * received.
-   * 
- * - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - @java.lang.Override - public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { - return getUpdateTime(); - } - - public static final int DELETE_TIME_FIELD_NUMBER = 7; - private com.google.protobuf.Timestamp deleteTime_; - /** - * - * - *
-   * Output only. Time at which the request to delete the `WorkerPool` was
-   * received.
-   * 
- * - * .google.protobuf.Timestamp delete_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return Whether the deleteTime field is set. - */ - @java.lang.Override - public boolean hasDeleteTime() { - return deleteTime_ != null; - } - /** - * - * - *
-   * Output only. Time at which the request to delete the `WorkerPool` was
-   * received.
-   * 
- * - * .google.protobuf.Timestamp delete_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The deleteTime. - */ - @java.lang.Override - public com.google.protobuf.Timestamp getDeleteTime() { - return deleteTime_ == null ? com.google.protobuf.Timestamp.getDefaultInstance() : deleteTime_; - } - /** - * - * - *
-   * Output only. Time at which the request to delete the `WorkerPool` was
-   * received.
-   * 
- * - * .google.protobuf.Timestamp delete_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - @java.lang.Override - public com.google.protobuf.TimestampOrBuilder getDeleteTimeOrBuilder() { - return getDeleteTime(); - } - - public static final int STATE_FIELD_NUMBER = 8; - private int state_; - /** - * - * - *
-   * Output only. `WorkerPool` state.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.WorkerPool.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The enum numeric value on the wire for state. - */ - @java.lang.Override - public int getStateValue() { - return state_; - } - /** - * - * - *
-   * Output only. `WorkerPool` state.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.WorkerPool.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The state. - */ - @java.lang.Override - public com.google.cloudbuild.v1.WorkerPool.State getState() { - @SuppressWarnings("deprecation") - com.google.cloudbuild.v1.WorkerPool.State result = - com.google.cloudbuild.v1.WorkerPool.State.valueOf(state_); - return result == null ? com.google.cloudbuild.v1.WorkerPool.State.UNRECOGNIZED : result; - } - - public static final int PRIVATE_POOL_V1_CONFIG_FIELD_NUMBER = 12; - /** - * - * - *
-   * Private Pool using a v1 configuration.
-   * 
- * - * .google.devtools.cloudbuild.v1.PrivatePoolV1Config private_pool_v1_config = 12; - * - * @return Whether the privatePoolV1Config field is set. - */ - @java.lang.Override - public boolean hasPrivatePoolV1Config() { - return configCase_ == 12; - } - /** - * - * - *
-   * Private Pool using a v1 configuration.
-   * 
- * - * .google.devtools.cloudbuild.v1.PrivatePoolV1Config private_pool_v1_config = 12; - * - * @return The privatePoolV1Config. - */ - @java.lang.Override - public com.google.cloudbuild.v1.PrivatePoolV1Config getPrivatePoolV1Config() { - if (configCase_ == 12) { - return (com.google.cloudbuild.v1.PrivatePoolV1Config) config_; - } - return com.google.cloudbuild.v1.PrivatePoolV1Config.getDefaultInstance(); - } - /** - * - * - *
-   * Private Pool using a v1 configuration.
-   * 
- * - * .google.devtools.cloudbuild.v1.PrivatePoolV1Config private_pool_v1_config = 12; - */ - @java.lang.Override - public com.google.cloudbuild.v1.PrivatePoolV1ConfigOrBuilder getPrivatePoolV1ConfigOrBuilder() { - if (configCase_ == 12) { - return (com.google.cloudbuild.v1.PrivatePoolV1Config) config_; - } - return com.google.cloudbuild.v1.PrivatePoolV1Config.getDefaultInstance(); - } - - public static final int ETAG_FIELD_NUMBER = 11; - private volatile java.lang.Object etag_; - /** - * - * - *
-   * Output only. Checksum computed by the server. May be sent on update and
-   * delete requests to ensure that the client has an up-to-date value before
-   * proceeding.
-   * 
- * - * string etag = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The etag. - */ - @java.lang.Override - public java.lang.String getEtag() { - java.lang.Object ref = etag_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - etag_ = s; - return s; - } - } - /** - * - * - *
-   * Output only. Checksum computed by the server. May be sent on update and
-   * delete requests to ensure that the client has an up-to-date value before
-   * proceeding.
-   * 
- * - * string etag = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The bytes for etag. - */ - @java.lang.Override - public com.google.protobuf.ByteString getEtagBytes() { - java.lang.Object ref = etag_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - etag_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - private byte memoizedIsInitialized = -1; - - @java.lang.Override - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized == 1) return true; - if (isInitialized == 0) return false; - - memoizedIsInitialized = 1; - return true; - } - - @java.lang.Override - public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 1, name_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(displayName_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 2, displayName_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(uid_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 3, uid_); - } - com.google.protobuf.GeneratedMessageV3.serializeStringMapTo( - output, internalGetAnnotations(), AnnotationsDefaultEntryHolder.defaultEntry, 4); - if (createTime_ != null) { - output.writeMessage(5, getCreateTime()); - } - if (updateTime_ != null) { - output.writeMessage(6, getUpdateTime()); - } - if (deleteTime_ != null) { - output.writeMessage(7, getDeleteTime()); - } - if (state_ != com.google.cloudbuild.v1.WorkerPool.State.STATE_UNSPECIFIED.getNumber()) { - output.writeEnum(8, state_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(etag_)) { - com.google.protobuf.GeneratedMessageV3.writeString(output, 11, etag_); - } - if (configCase_ == 12) { - output.writeMessage(12, (com.google.cloudbuild.v1.PrivatePoolV1Config) config_); - } - getUnknownFields().writeTo(output); - } - - @java.lang.Override - public int getSerializedSize() { - int size = memoizedSize; - if (size != -1) return size; - - size = 0; - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(name_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, name_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(displayName_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, displayName_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(uid_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, uid_); - } - for (java.util.Map.Entry entry : - internalGetAnnotations().getMap().entrySet()) { - com.google.protobuf.MapEntry annotations__ = - AnnotationsDefaultEntryHolder.defaultEntry - .newBuilderForType() - .setKey(entry.getKey()) - .setValue(entry.getValue()) - .build(); - size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, annotations__); - } - if (createTime_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(5, getCreateTime()); - } - if (updateTime_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(6, getUpdateTime()); - } - if (deleteTime_ != null) { - size += com.google.protobuf.CodedOutputStream.computeMessageSize(7, getDeleteTime()); - } - if (state_ != com.google.cloudbuild.v1.WorkerPool.State.STATE_UNSPECIFIED.getNumber()) { - size += com.google.protobuf.CodedOutputStream.computeEnumSize(8, state_); - } - if (!com.google.protobuf.GeneratedMessageV3.isStringEmpty(etag_)) { - size += com.google.protobuf.GeneratedMessageV3.computeStringSize(11, etag_); - } - if (configCase_ == 12) { - size += - com.google.protobuf.CodedOutputStream.computeMessageSize( - 12, (com.google.cloudbuild.v1.PrivatePoolV1Config) config_); - } - size += getUnknownFields().getSerializedSize(); - memoizedSize = size; - return size; - } - - @java.lang.Override - public boolean equals(final java.lang.Object obj) { - if (obj == this) { - return true; - } - if (!(obj instanceof com.google.cloudbuild.v1.WorkerPool)) { - return super.equals(obj); - } - com.google.cloudbuild.v1.WorkerPool other = (com.google.cloudbuild.v1.WorkerPool) obj; - - if (!getName().equals(other.getName())) return false; - if (!getDisplayName().equals(other.getDisplayName())) return false; - if (!getUid().equals(other.getUid())) return false; - if (!internalGetAnnotations().equals(other.internalGetAnnotations())) return false; - if (hasCreateTime() != other.hasCreateTime()) return false; - if (hasCreateTime()) { - if (!getCreateTime().equals(other.getCreateTime())) return false; - } - if (hasUpdateTime() != other.hasUpdateTime()) return false; - if (hasUpdateTime()) { - if (!getUpdateTime().equals(other.getUpdateTime())) return false; - } - if (hasDeleteTime() != other.hasDeleteTime()) return false; - if (hasDeleteTime()) { - if (!getDeleteTime().equals(other.getDeleteTime())) return false; - } - if (state_ != other.state_) return false; - if (!getEtag().equals(other.getEtag())) return false; - if (!getConfigCase().equals(other.getConfigCase())) return false; - switch (configCase_) { - case 12: - if (!getPrivatePoolV1Config().equals(other.getPrivatePoolV1Config())) return false; - break; - case 0: - default: - } - if (!getUnknownFields().equals(other.getUnknownFields())) return false; - return true; - } - - @java.lang.Override - public int hashCode() { - if (memoizedHashCode != 0) { - return memoizedHashCode; - } - int hash = 41; - hash = (19 * hash) + getDescriptor().hashCode(); - hash = (37 * hash) + NAME_FIELD_NUMBER; - hash = (53 * hash) + getName().hashCode(); - hash = (37 * hash) + DISPLAY_NAME_FIELD_NUMBER; - hash = (53 * hash) + getDisplayName().hashCode(); - hash = (37 * hash) + UID_FIELD_NUMBER; - hash = (53 * hash) + getUid().hashCode(); - if (!internalGetAnnotations().getMap().isEmpty()) { - hash = (37 * hash) + ANNOTATIONS_FIELD_NUMBER; - hash = (53 * hash) + internalGetAnnotations().hashCode(); - } - if (hasCreateTime()) { - hash = (37 * hash) + CREATE_TIME_FIELD_NUMBER; - hash = (53 * hash) + getCreateTime().hashCode(); - } - if (hasUpdateTime()) { - hash = (37 * hash) + UPDATE_TIME_FIELD_NUMBER; - hash = (53 * hash) + getUpdateTime().hashCode(); - } - if (hasDeleteTime()) { - hash = (37 * hash) + DELETE_TIME_FIELD_NUMBER; - hash = (53 * hash) + getDeleteTime().hashCode(); - } - hash = (37 * hash) + STATE_FIELD_NUMBER; - hash = (53 * hash) + state_; - hash = (37 * hash) + ETAG_FIELD_NUMBER; - hash = (53 * hash) + getEtag().hashCode(); - switch (configCase_) { - case 12: - hash = (37 * hash) + PRIVATE_POOL_V1_CONFIG_FIELD_NUMBER; - hash = (53 * hash) + getPrivatePoolV1Config().hashCode(); - break; - case 0: - default: - } - hash = (29 * hash) + getUnknownFields().hashCode(); - memoizedHashCode = hash; - return hash; - } - - public static com.google.cloudbuild.v1.WorkerPool parseFrom(java.nio.ByteBuffer data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.WorkerPool parseFrom( - java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.WorkerPool parseFrom(com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.WorkerPool parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.WorkerPool parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - - public static com.google.cloudbuild.v1.WorkerPool parseFrom( - byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - - public static com.google.cloudbuild.v1.WorkerPool parseFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.WorkerPool parseFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.WorkerPool parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.WorkerPool parseDelimitedFrom( - java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( - PARSER, input, extensionRegistry); - } - - public static com.google.cloudbuild.v1.WorkerPool parseFrom( - com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); - } - - public static com.google.cloudbuild.v1.WorkerPool parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3.parseWithIOException( - PARSER, input, extensionRegistry); - } - - @java.lang.Override - public Builder newBuilderForType() { - return newBuilder(); - } - - public static Builder newBuilder() { - return DEFAULT_INSTANCE.toBuilder(); - } - - public static Builder newBuilder(com.google.cloudbuild.v1.WorkerPool prototype) { - return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); - } - - @java.lang.Override - public Builder toBuilder() { - return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); - } - - @java.lang.Override - protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * - * - *
-   * Configuration for a `WorkerPool`.
-   * Cloud Build owns and maintains a pool of workers for general use and have no
-   * access to a project's private network. By default, builds submitted to
-   * Cloud Build will use a worker from this pool.
-   * If your build needs access to resources on a private network,
-   * create and use a `WorkerPool` to run your builds. Private `WorkerPool`s give
-   * your builds access to any single VPC network that you
-   * administer, including any on-prem resources connected to that VPC
-   * network. For an overview of private pools, see
-   * [Private pools
-   * overview](https://cloud.google.com/build/docs/private-pools/private-pools-overview).
-   * 
- * - * Protobuf type {@code google.devtools.cloudbuild.v1.WorkerPool} - */ - public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder - implements - // @@protoc_insertion_point(builder_implements:google.devtools.cloudbuild.v1.WorkerPool) - com.google.cloudbuild.v1.WorkerPoolOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_WorkerPool_descriptor; - } - - @SuppressWarnings({"rawtypes"}) - protected com.google.protobuf.MapField internalGetMapField(int number) { - switch (number) { - case 4: - return internalGetAnnotations(); - default: - throw new RuntimeException("Invalid map field number: " + number); - } - } - - @SuppressWarnings({"rawtypes"}) - protected com.google.protobuf.MapField internalGetMutableMapField(int number) { - switch (number) { - case 4: - return internalGetMutableAnnotations(); - default: - throw new RuntimeException("Invalid map field number: " + number); - } - } - - @java.lang.Override - protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable - internalGetFieldAccessorTable() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_WorkerPool_fieldAccessorTable - .ensureFieldAccessorsInitialized( - com.google.cloudbuild.v1.WorkerPool.class, - com.google.cloudbuild.v1.WorkerPool.Builder.class); - } - - // Construct using com.google.cloudbuild.v1.WorkerPool.newBuilder() - private Builder() {} - - private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { - super(parent); - } - - @java.lang.Override - public Builder clear() { - super.clear(); - name_ = ""; - - displayName_ = ""; - - uid_ = ""; - - internalGetMutableAnnotations().clear(); - if (createTimeBuilder_ == null) { - createTime_ = null; - } else { - createTime_ = null; - createTimeBuilder_ = null; - } - if (updateTimeBuilder_ == null) { - updateTime_ = null; - } else { - updateTime_ = null; - updateTimeBuilder_ = null; - } - if (deleteTimeBuilder_ == null) { - deleteTime_ = null; - } else { - deleteTime_ = null; - deleteTimeBuilder_ = null; - } - state_ = 0; - - if (privatePoolV1ConfigBuilder_ != null) { - privatePoolV1ConfigBuilder_.clear(); - } - etag_ = ""; - - configCase_ = 0; - config_ = null; - return this; - } - - @java.lang.Override - public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { - return com.google.cloudbuild.v1.Cloudbuild - .internal_static_google_devtools_cloudbuild_v1_WorkerPool_descriptor; - } - - @java.lang.Override - public com.google.cloudbuild.v1.WorkerPool getDefaultInstanceForType() { - return com.google.cloudbuild.v1.WorkerPool.getDefaultInstance(); - } - - @java.lang.Override - public com.google.cloudbuild.v1.WorkerPool build() { - com.google.cloudbuild.v1.WorkerPool result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - @java.lang.Override - public com.google.cloudbuild.v1.WorkerPool buildPartial() { - com.google.cloudbuild.v1.WorkerPool result = new com.google.cloudbuild.v1.WorkerPool(this); - int from_bitField0_ = bitField0_; - result.name_ = name_; - result.displayName_ = displayName_; - result.uid_ = uid_; - result.annotations_ = internalGetAnnotations(); - result.annotations_.makeImmutable(); - if (createTimeBuilder_ == null) { - result.createTime_ = createTime_; - } else { - result.createTime_ = createTimeBuilder_.build(); - } - if (updateTimeBuilder_ == null) { - result.updateTime_ = updateTime_; - } else { - result.updateTime_ = updateTimeBuilder_.build(); - } - if (deleteTimeBuilder_ == null) { - result.deleteTime_ = deleteTime_; - } else { - result.deleteTime_ = deleteTimeBuilder_.build(); - } - result.state_ = state_; - if (configCase_ == 12) { - if (privatePoolV1ConfigBuilder_ == null) { - result.config_ = config_; - } else { - result.config_ = privatePoolV1ConfigBuilder_.build(); - } - } - result.etag_ = etag_; - result.configCase_ = configCase_; - onBuilt(); - return result; - } - - @java.lang.Override - public Builder clone() { - return super.clone(); - } - - @java.lang.Override - public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.setField(field, value); - } - - @java.lang.Override - public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { - return super.clearField(field); - } - - @java.lang.Override - public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { - return super.clearOneof(oneof); - } - - @java.lang.Override - public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { - return super.setRepeatedField(field, index, value); - } - - @java.lang.Override - public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { - return super.addRepeatedField(field, value); - } - - @java.lang.Override - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof com.google.cloudbuild.v1.WorkerPool) { - return mergeFrom((com.google.cloudbuild.v1.WorkerPool) other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(com.google.cloudbuild.v1.WorkerPool other) { - if (other == com.google.cloudbuild.v1.WorkerPool.getDefaultInstance()) return this; - if (!other.getName().isEmpty()) { - name_ = other.name_; - onChanged(); - } - if (!other.getDisplayName().isEmpty()) { - displayName_ = other.displayName_; - onChanged(); - } - if (!other.getUid().isEmpty()) { - uid_ = other.uid_; - onChanged(); - } - internalGetMutableAnnotations().mergeFrom(other.internalGetAnnotations()); - if (other.hasCreateTime()) { - mergeCreateTime(other.getCreateTime()); - } - if (other.hasUpdateTime()) { - mergeUpdateTime(other.getUpdateTime()); - } - if (other.hasDeleteTime()) { - mergeDeleteTime(other.getDeleteTime()); - } - if (other.state_ != 0) { - setStateValue(other.getStateValue()); - } - if (!other.getEtag().isEmpty()) { - etag_ = other.etag_; - onChanged(); - } - switch (other.getConfigCase()) { - case PRIVATE_POOL_V1_CONFIG: - { - mergePrivatePoolV1Config(other.getPrivatePoolV1Config()); - break; - } - case CONFIG_NOT_SET: - { - break; - } - } - this.mergeUnknownFields(other.getUnknownFields()); - onChanged(); - return this; - } - - @java.lang.Override - public final boolean isInitialized() { - return true; - } - - @java.lang.Override - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - if (extensionRegistry == null) { - throw new java.lang.NullPointerException(); - } - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - case 10: - { - name_ = input.readStringRequireUtf8(); - - break; - } // case 10 - case 18: - { - displayName_ = input.readStringRequireUtf8(); - - break; - } // case 18 - case 26: - { - uid_ = input.readStringRequireUtf8(); - - break; - } // case 26 - case 34: - { - com.google.protobuf.MapEntry annotations__ = - input.readMessage( - AnnotationsDefaultEntryHolder.defaultEntry.getParserForType(), - extensionRegistry); - internalGetMutableAnnotations() - .getMutableMap() - .put(annotations__.getKey(), annotations__.getValue()); - break; - } // case 34 - case 42: - { - input.readMessage(getCreateTimeFieldBuilder().getBuilder(), extensionRegistry); - - break; - } // case 42 - case 50: - { - input.readMessage(getUpdateTimeFieldBuilder().getBuilder(), extensionRegistry); - - break; - } // case 50 - case 58: - { - input.readMessage(getDeleteTimeFieldBuilder().getBuilder(), extensionRegistry); - - break; - } // case 58 - case 64: - { - state_ = input.readEnum(); - - break; - } // case 64 - case 90: - { - etag_ = input.readStringRequireUtf8(); - - break; - } // case 90 - case 98: - { - input.readMessage( - getPrivatePoolV1ConfigFieldBuilder().getBuilder(), extensionRegistry); - configCase_ = 12; - break; - } // case 98 - default: - { - if (!super.parseUnknownField(input, extensionRegistry, tag)) { - done = true; // was an endgroup tag - } - break; - } // default: - } // switch (tag) - } // while (!done) - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.unwrapIOException(); - } finally { - onChanged(); - } // finally - return this; - } - - private int configCase_ = 0; - private java.lang.Object config_; - - public ConfigCase getConfigCase() { - return ConfigCase.forNumber(configCase_); - } - - public Builder clearConfig() { - configCase_ = 0; - config_ = null; - onChanged(); - return this; - } - - private int bitField0_; - - private java.lang.Object name_ = ""; - /** - * - * - *
-     * Output only. The resource name of the `WorkerPool`, with format
-     * `projects/{project}/locations/{location}/workerPools/{worker_pool}`.
-     * The value of `{worker_pool}` is provided by `worker_pool_id` in
-     * `CreateWorkerPool` request and the value of `{location}` is determined by
-     * the endpoint accessed.
-     * 
- * - * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The name. - */ - public java.lang.String getName() { - java.lang.Object ref = name_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - name_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Output only. The resource name of the `WorkerPool`, with format
-     * `projects/{project}/locations/{location}/workerPools/{worker_pool}`.
-     * The value of `{worker_pool}` is provided by `worker_pool_id` in
-     * `CreateWorkerPool` request and the value of `{location}` is determined by
-     * the endpoint accessed.
-     * 
- * - * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The bytes for name. - */ - public com.google.protobuf.ByteString getNameBytes() { - java.lang.Object ref = name_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - name_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Output only. The resource name of the `WorkerPool`, with format
-     * `projects/{project}/locations/{location}/workerPools/{worker_pool}`.
-     * The value of `{worker_pool}` is provided by `worker_pool_id` in
-     * `CreateWorkerPool` request and the value of `{location}` is determined by
-     * the endpoint accessed.
-     * 
- * - * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @param value The name to set. - * @return This builder for chaining. - */ - public Builder setName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - name_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. The resource name of the `WorkerPool`, with format
-     * `projects/{project}/locations/{location}/workerPools/{worker_pool}`.
-     * The value of `{worker_pool}` is provided by `worker_pool_id` in
-     * `CreateWorkerPool` request and the value of `{location}` is determined by
-     * the endpoint accessed.
-     * 
- * - * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return This builder for chaining. - */ - public Builder clearName() { - - name_ = getDefaultInstance().getName(); - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. The resource name of the `WorkerPool`, with format
-     * `projects/{project}/locations/{location}/workerPools/{worker_pool}`.
-     * The value of `{worker_pool}` is provided by `worker_pool_id` in
-     * `CreateWorkerPool` request and the value of `{location}` is determined by
-     * the endpoint accessed.
-     * 
- * - * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @param value The bytes for name to set. - * @return This builder for chaining. - */ - public Builder setNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - name_ = value; - onChanged(); - return this; - } - - private java.lang.Object displayName_ = ""; - /** - * - * - *
-     * A user-specified, human-readable name for the `WorkerPool`. If provided,
-     * this value must be 1-63 characters.
-     * 
- * - * string display_name = 2; - * - * @return The displayName. - */ - public java.lang.String getDisplayName() { - java.lang.Object ref = displayName_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - displayName_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * A user-specified, human-readable name for the `WorkerPool`. If provided,
-     * this value must be 1-63 characters.
-     * 
- * - * string display_name = 2; - * - * @return The bytes for displayName. - */ - public com.google.protobuf.ByteString getDisplayNameBytes() { - java.lang.Object ref = displayName_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - displayName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * A user-specified, human-readable name for the `WorkerPool`. If provided,
-     * this value must be 1-63 characters.
-     * 
- * - * string display_name = 2; - * - * @param value The displayName to set. - * @return This builder for chaining. - */ - public Builder setDisplayName(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - displayName_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * A user-specified, human-readable name for the `WorkerPool`. If provided,
-     * this value must be 1-63 characters.
-     * 
- * - * string display_name = 2; - * - * @return This builder for chaining. - */ - public Builder clearDisplayName() { - - displayName_ = getDefaultInstance().getDisplayName(); - onChanged(); - return this; - } - /** - * - * - *
-     * A user-specified, human-readable name for the `WorkerPool`. If provided,
-     * this value must be 1-63 characters.
-     * 
- * - * string display_name = 2; - * - * @param value The bytes for displayName to set. - * @return This builder for chaining. - */ - public Builder setDisplayNameBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - displayName_ = value; - onChanged(); - return this; - } - - private java.lang.Object uid_ = ""; - /** - * - * - *
-     * Output only. A unique identifier for the `WorkerPool`.
-     * 
- * - * string uid = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The uid. - */ - public java.lang.String getUid() { - java.lang.Object ref = uid_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - uid_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Output only. A unique identifier for the `WorkerPool`.
-     * 
- * - * string uid = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The bytes for uid. - */ - public com.google.protobuf.ByteString getUidBytes() { - java.lang.Object ref = uid_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - uid_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Output only. A unique identifier for the `WorkerPool`.
-     * 
- * - * string uid = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @param value The uid to set. - * @return This builder for chaining. - */ - public Builder setUid(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - uid_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. A unique identifier for the `WorkerPool`.
-     * 
- * - * string uid = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return This builder for chaining. - */ - public Builder clearUid() { - - uid_ = getDefaultInstance().getUid(); - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. A unique identifier for the `WorkerPool`.
-     * 
- * - * string uid = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @param value The bytes for uid to set. - * @return This builder for chaining. - */ - public Builder setUidBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - uid_ = value; - onChanged(); - return this; - } - - private com.google.protobuf.MapField annotations_; - - private com.google.protobuf.MapField - internalGetAnnotations() { - if (annotations_ == null) { - return com.google.protobuf.MapField.emptyMapField( - AnnotationsDefaultEntryHolder.defaultEntry); - } - return annotations_; - } - - private com.google.protobuf.MapField - internalGetMutableAnnotations() { - onChanged(); - ; - if (annotations_ == null) { - annotations_ = - com.google.protobuf.MapField.newMapField(AnnotationsDefaultEntryHolder.defaultEntry); - } - if (!annotations_.isMutable()) { - annotations_ = annotations_.copy(); - } - return annotations_; - } - - public int getAnnotationsCount() { - return internalGetAnnotations().getMap().size(); - } - /** - * - * - *
-     * User specified annotations. See https://google.aip.dev/128#annotations
-     * for more details such as format and size limitations.
-     * 
- * - * map<string, string> annotations = 4; - */ - @java.lang.Override - public boolean containsAnnotations(java.lang.String key) { - if (key == null) { - throw new NullPointerException("map key"); - } - return internalGetAnnotations().getMap().containsKey(key); - } - /** Use {@link #getAnnotationsMap()} instead. */ - @java.lang.Override - @java.lang.Deprecated - public java.util.Map getAnnotations() { - return getAnnotationsMap(); - } - /** - * - * - *
-     * User specified annotations. See https://google.aip.dev/128#annotations
-     * for more details such as format and size limitations.
-     * 
- * - * map<string, string> annotations = 4; - */ - @java.lang.Override - public java.util.Map getAnnotationsMap() { - return internalGetAnnotations().getMap(); - } - /** - * - * - *
-     * User specified annotations. See https://google.aip.dev/128#annotations
-     * for more details such as format and size limitations.
-     * 
- * - * map<string, string> annotations = 4; - */ - @java.lang.Override - public java.lang.String getAnnotationsOrDefault( - java.lang.String key, java.lang.String defaultValue) { - if (key == null) { - throw new NullPointerException("map key"); - } - java.util.Map map = internalGetAnnotations().getMap(); - return map.containsKey(key) ? map.get(key) : defaultValue; - } - /** - * - * - *
-     * User specified annotations. See https://google.aip.dev/128#annotations
-     * for more details such as format and size limitations.
-     * 
- * - * map<string, string> annotations = 4; - */ - @java.lang.Override - public java.lang.String getAnnotationsOrThrow(java.lang.String key) { - if (key == null) { - throw new NullPointerException("map key"); - } - java.util.Map map = internalGetAnnotations().getMap(); - if (!map.containsKey(key)) { - throw new java.lang.IllegalArgumentException(); - } - return map.get(key); - } - - public Builder clearAnnotations() { - internalGetMutableAnnotations().getMutableMap().clear(); - return this; - } - /** - * - * - *
-     * User specified annotations. See https://google.aip.dev/128#annotations
-     * for more details such as format and size limitations.
-     * 
- * - * map<string, string> annotations = 4; - */ - public Builder removeAnnotations(java.lang.String key) { - if (key == null) { - throw new NullPointerException("map key"); - } - internalGetMutableAnnotations().getMutableMap().remove(key); - return this; - } - /** Use alternate mutation accessors instead. */ - @java.lang.Deprecated - public java.util.Map getMutableAnnotations() { - return internalGetMutableAnnotations().getMutableMap(); - } - /** - * - * - *
-     * User specified annotations. See https://google.aip.dev/128#annotations
-     * for more details such as format and size limitations.
-     * 
- * - * map<string, string> annotations = 4; - */ - public Builder putAnnotations(java.lang.String key, java.lang.String value) { - if (key == null) { - throw new NullPointerException("map key"); - } - if (value == null) { - throw new NullPointerException("map value"); - } - - internalGetMutableAnnotations().getMutableMap().put(key, value); - return this; - } - /** - * - * - *
-     * User specified annotations. See https://google.aip.dev/128#annotations
-     * for more details such as format and size limitations.
-     * 
- * - * map<string, string> annotations = 4; - */ - public Builder putAllAnnotations(java.util.Map values) { - internalGetMutableAnnotations().getMutableMap().putAll(values); - return this; - } - - private com.google.protobuf.Timestamp createTime_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - createTimeBuilder_; - /** - * - * - *
-     * Output only. Time at which the request to create the `WorkerPool` was
-     * received.
-     * 
- * - * - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return Whether the createTime field is set. - */ - public boolean hasCreateTime() { - return createTimeBuilder_ != null || createTime_ != null; - } - /** - * - * - *
-     * Output only. Time at which the request to create the `WorkerPool` was
-     * received.
-     * 
- * - * - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The createTime. - */ - public com.google.protobuf.Timestamp getCreateTime() { - if (createTimeBuilder_ == null) { - return createTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : createTime_; - } else { - return createTimeBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Output only. Time at which the request to create the `WorkerPool` was
-     * received.
-     * 
- * - * - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder setCreateTime(com.google.protobuf.Timestamp value) { - if (createTimeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - createTime_ = value; - onChanged(); - } else { - createTimeBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * Output only. Time at which the request to create the `WorkerPool` was
-     * received.
-     * 
- * - * - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder setCreateTime(com.google.protobuf.Timestamp.Builder builderForValue) { - if (createTimeBuilder_ == null) { - createTime_ = builderForValue.build(); - onChanged(); - } else { - createTimeBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Output only. Time at which the request to create the `WorkerPool` was
-     * received.
-     * 
- * - * - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder mergeCreateTime(com.google.protobuf.Timestamp value) { - if (createTimeBuilder_ == null) { - if (createTime_ != null) { - createTime_ = - com.google.protobuf.Timestamp.newBuilder(createTime_).mergeFrom(value).buildPartial(); - } else { - createTime_ = value; - } - onChanged(); - } else { - createTimeBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * Output only. Time at which the request to create the `WorkerPool` was
-     * received.
-     * 
- * - * - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder clearCreateTime() { - if (createTimeBuilder_ == null) { - createTime_ = null; - onChanged(); - } else { - createTime_ = null; - createTimeBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Output only. Time at which the request to create the `WorkerPool` was
-     * received.
-     * 
- * - * - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public com.google.protobuf.Timestamp.Builder getCreateTimeBuilder() { - - onChanged(); - return getCreateTimeFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Output only. Time at which the request to create the `WorkerPool` was
-     * received.
-     * 
- * - * - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder() { - if (createTimeBuilder_ != null) { - return createTimeBuilder_.getMessageOrBuilder(); - } else { - return createTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : createTime_; - } - } - /** - * - * - *
-     * Output only. Time at which the request to create the `WorkerPool` was
-     * received.
-     * 
- * - * - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - getCreateTimeFieldBuilder() { - if (createTimeBuilder_ == null) { - createTimeBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder>( - getCreateTime(), getParentForChildren(), isClean()); - createTime_ = null; - } - return createTimeBuilder_; - } - - private com.google.protobuf.Timestamp updateTime_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - updateTimeBuilder_; - /** - * - * - *
-     * Output only. Time at which the request to update the `WorkerPool` was
-     * received.
-     * 
- * - * - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return Whether the updateTime field is set. - */ - public boolean hasUpdateTime() { - return updateTimeBuilder_ != null || updateTime_ != null; - } - /** - * - * - *
-     * Output only. Time at which the request to update the `WorkerPool` was
-     * received.
-     * 
- * - * - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The updateTime. - */ - public com.google.protobuf.Timestamp getUpdateTime() { - if (updateTimeBuilder_ == null) { - return updateTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : updateTime_; - } else { - return updateTimeBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Output only. Time at which the request to update the `WorkerPool` was
-     * received.
-     * 
- * - * - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder setUpdateTime(com.google.protobuf.Timestamp value) { - if (updateTimeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - updateTime_ = value; - onChanged(); - } else { - updateTimeBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * Output only. Time at which the request to update the `WorkerPool` was
-     * received.
-     * 
- * - * - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder setUpdateTime(com.google.protobuf.Timestamp.Builder builderForValue) { - if (updateTimeBuilder_ == null) { - updateTime_ = builderForValue.build(); - onChanged(); - } else { - updateTimeBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Output only. Time at which the request to update the `WorkerPool` was
-     * received.
-     * 
- * - * - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder mergeUpdateTime(com.google.protobuf.Timestamp value) { - if (updateTimeBuilder_ == null) { - if (updateTime_ != null) { - updateTime_ = - com.google.protobuf.Timestamp.newBuilder(updateTime_).mergeFrom(value).buildPartial(); - } else { - updateTime_ = value; - } - onChanged(); - } else { - updateTimeBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * Output only. Time at which the request to update the `WorkerPool` was
-     * received.
-     * 
- * - * - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder clearUpdateTime() { - if (updateTimeBuilder_ == null) { - updateTime_ = null; - onChanged(); - } else { - updateTime_ = null; - updateTimeBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Output only. Time at which the request to update the `WorkerPool` was
-     * received.
-     * 
- * - * - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public com.google.protobuf.Timestamp.Builder getUpdateTimeBuilder() { - - onChanged(); - return getUpdateTimeFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Output only. Time at which the request to update the `WorkerPool` was
-     * received.
-     * 
- * - * - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder() { - if (updateTimeBuilder_ != null) { - return updateTimeBuilder_.getMessageOrBuilder(); - } else { - return updateTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : updateTime_; - } - } - /** - * - * - *
-     * Output only. Time at which the request to update the `WorkerPool` was
-     * received.
-     * 
- * - * - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - getUpdateTimeFieldBuilder() { - if (updateTimeBuilder_ == null) { - updateTimeBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder>( - getUpdateTime(), getParentForChildren(), isClean()); - updateTime_ = null; - } - return updateTimeBuilder_; - } - - private com.google.protobuf.Timestamp deleteTime_; - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - deleteTimeBuilder_; - /** - * - * - *
-     * Output only. Time at which the request to delete the `WorkerPool` was
-     * received.
-     * 
- * - * - * .google.protobuf.Timestamp delete_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return Whether the deleteTime field is set. - */ - public boolean hasDeleteTime() { - return deleteTimeBuilder_ != null || deleteTime_ != null; - } - /** - * - * - *
-     * Output only. Time at which the request to delete the `WorkerPool` was
-     * received.
-     * 
- * - * - * .google.protobuf.Timestamp delete_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The deleteTime. - */ - public com.google.protobuf.Timestamp getDeleteTime() { - if (deleteTimeBuilder_ == null) { - return deleteTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : deleteTime_; - } else { - return deleteTimeBuilder_.getMessage(); - } - } - /** - * - * - *
-     * Output only. Time at which the request to delete the `WorkerPool` was
-     * received.
-     * 
- * - * - * .google.protobuf.Timestamp delete_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder setDeleteTime(com.google.protobuf.Timestamp value) { - if (deleteTimeBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - deleteTime_ = value; - onChanged(); - } else { - deleteTimeBuilder_.setMessage(value); - } - - return this; - } - /** - * - * - *
-     * Output only. Time at which the request to delete the `WorkerPool` was
-     * received.
-     * 
- * - * - * .google.protobuf.Timestamp delete_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder setDeleteTime(com.google.protobuf.Timestamp.Builder builderForValue) { - if (deleteTimeBuilder_ == null) { - deleteTime_ = builderForValue.build(); - onChanged(); - } else { - deleteTimeBuilder_.setMessage(builderForValue.build()); - } - - return this; - } - /** - * - * - *
-     * Output only. Time at which the request to delete the `WorkerPool` was
-     * received.
-     * 
- * - * - * .google.protobuf.Timestamp delete_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder mergeDeleteTime(com.google.protobuf.Timestamp value) { - if (deleteTimeBuilder_ == null) { - if (deleteTime_ != null) { - deleteTime_ = - com.google.protobuf.Timestamp.newBuilder(deleteTime_).mergeFrom(value).buildPartial(); - } else { - deleteTime_ = value; - } - onChanged(); - } else { - deleteTimeBuilder_.mergeFrom(value); - } - - return this; - } - /** - * - * - *
-     * Output only. Time at which the request to delete the `WorkerPool` was
-     * received.
-     * 
- * - * - * .google.protobuf.Timestamp delete_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public Builder clearDeleteTime() { - if (deleteTimeBuilder_ == null) { - deleteTime_ = null; - onChanged(); - } else { - deleteTime_ = null; - deleteTimeBuilder_ = null; - } - - return this; - } - /** - * - * - *
-     * Output only. Time at which the request to delete the `WorkerPool` was
-     * received.
-     * 
- * - * - * .google.protobuf.Timestamp delete_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public com.google.protobuf.Timestamp.Builder getDeleteTimeBuilder() { - - onChanged(); - return getDeleteTimeFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Output only. Time at which the request to delete the `WorkerPool` was
-     * received.
-     * 
- * - * - * .google.protobuf.Timestamp delete_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - public com.google.protobuf.TimestampOrBuilder getDeleteTimeOrBuilder() { - if (deleteTimeBuilder_ != null) { - return deleteTimeBuilder_.getMessageOrBuilder(); - } else { - return deleteTime_ == null - ? com.google.protobuf.Timestamp.getDefaultInstance() - : deleteTime_; - } - } - /** - * - * - *
-     * Output only. Time at which the request to delete the `WorkerPool` was
-     * received.
-     * 
- * - * - * .google.protobuf.Timestamp delete_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder> - getDeleteTimeFieldBuilder() { - if (deleteTimeBuilder_ == null) { - deleteTimeBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.protobuf.Timestamp, - com.google.protobuf.Timestamp.Builder, - com.google.protobuf.TimestampOrBuilder>( - getDeleteTime(), getParentForChildren(), isClean()); - deleteTime_ = null; - } - return deleteTimeBuilder_; - } - - private int state_ = 0; - /** - * - * - *
-     * Output only. `WorkerPool` state.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.WorkerPool.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The enum numeric value on the wire for state. - */ - @java.lang.Override - public int getStateValue() { - return state_; - } - /** - * - * - *
-     * Output only. `WorkerPool` state.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.WorkerPool.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @param value The enum numeric value on the wire for state to set. - * @return This builder for chaining. - */ - public Builder setStateValue(int value) { - - state_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. `WorkerPool` state.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.WorkerPool.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The state. - */ - @java.lang.Override - public com.google.cloudbuild.v1.WorkerPool.State getState() { - @SuppressWarnings("deprecation") - com.google.cloudbuild.v1.WorkerPool.State result = - com.google.cloudbuild.v1.WorkerPool.State.valueOf(state_); - return result == null ? com.google.cloudbuild.v1.WorkerPool.State.UNRECOGNIZED : result; - } - /** - * - * - *
-     * Output only. `WorkerPool` state.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.WorkerPool.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @param value The state to set. - * @return This builder for chaining. - */ - public Builder setState(com.google.cloudbuild.v1.WorkerPool.State value) { - if (value == null) { - throw new NullPointerException(); - } - - state_ = value.getNumber(); - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. `WorkerPool` state.
-     * 
- * - * - * .google.devtools.cloudbuild.v1.WorkerPool.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return This builder for chaining. - */ - public Builder clearState() { - - state_ = 0; - onChanged(); - return this; - } - - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.PrivatePoolV1Config, - com.google.cloudbuild.v1.PrivatePoolV1Config.Builder, - com.google.cloudbuild.v1.PrivatePoolV1ConfigOrBuilder> - privatePoolV1ConfigBuilder_; - /** - * - * - *
-     * Private Pool using a v1 configuration.
-     * 
- * - * .google.devtools.cloudbuild.v1.PrivatePoolV1Config private_pool_v1_config = 12; - * - * @return Whether the privatePoolV1Config field is set. - */ - @java.lang.Override - public boolean hasPrivatePoolV1Config() { - return configCase_ == 12; - } - /** - * - * - *
-     * Private Pool using a v1 configuration.
-     * 
- * - * .google.devtools.cloudbuild.v1.PrivatePoolV1Config private_pool_v1_config = 12; - * - * @return The privatePoolV1Config. - */ - @java.lang.Override - public com.google.cloudbuild.v1.PrivatePoolV1Config getPrivatePoolV1Config() { - if (privatePoolV1ConfigBuilder_ == null) { - if (configCase_ == 12) { - return (com.google.cloudbuild.v1.PrivatePoolV1Config) config_; - } - return com.google.cloudbuild.v1.PrivatePoolV1Config.getDefaultInstance(); - } else { - if (configCase_ == 12) { - return privatePoolV1ConfigBuilder_.getMessage(); - } - return com.google.cloudbuild.v1.PrivatePoolV1Config.getDefaultInstance(); - } - } - /** - * - * - *
-     * Private Pool using a v1 configuration.
-     * 
- * - * .google.devtools.cloudbuild.v1.PrivatePoolV1Config private_pool_v1_config = 12; - */ - public Builder setPrivatePoolV1Config(com.google.cloudbuild.v1.PrivatePoolV1Config value) { - if (privatePoolV1ConfigBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - config_ = value; - onChanged(); - } else { - privatePoolV1ConfigBuilder_.setMessage(value); - } - configCase_ = 12; - return this; - } - /** - * - * - *
-     * Private Pool using a v1 configuration.
-     * 
- * - * .google.devtools.cloudbuild.v1.PrivatePoolV1Config private_pool_v1_config = 12; - */ - public Builder setPrivatePoolV1Config( - com.google.cloudbuild.v1.PrivatePoolV1Config.Builder builderForValue) { - if (privatePoolV1ConfigBuilder_ == null) { - config_ = builderForValue.build(); - onChanged(); - } else { - privatePoolV1ConfigBuilder_.setMessage(builderForValue.build()); - } - configCase_ = 12; - return this; - } - /** - * - * - *
-     * Private Pool using a v1 configuration.
-     * 
- * - * .google.devtools.cloudbuild.v1.PrivatePoolV1Config private_pool_v1_config = 12; - */ - public Builder mergePrivatePoolV1Config(com.google.cloudbuild.v1.PrivatePoolV1Config value) { - if (privatePoolV1ConfigBuilder_ == null) { - if (configCase_ == 12 - && config_ != com.google.cloudbuild.v1.PrivatePoolV1Config.getDefaultInstance()) { - config_ = - com.google.cloudbuild.v1.PrivatePoolV1Config.newBuilder( - (com.google.cloudbuild.v1.PrivatePoolV1Config) config_) - .mergeFrom(value) - .buildPartial(); - } else { - config_ = value; - } - onChanged(); - } else { - if (configCase_ == 12) { - privatePoolV1ConfigBuilder_.mergeFrom(value); - } else { - privatePoolV1ConfigBuilder_.setMessage(value); - } - } - configCase_ = 12; - return this; - } - /** - * - * - *
-     * Private Pool using a v1 configuration.
-     * 
- * - * .google.devtools.cloudbuild.v1.PrivatePoolV1Config private_pool_v1_config = 12; - */ - public Builder clearPrivatePoolV1Config() { - if (privatePoolV1ConfigBuilder_ == null) { - if (configCase_ == 12) { - configCase_ = 0; - config_ = null; - onChanged(); - } - } else { - if (configCase_ == 12) { - configCase_ = 0; - config_ = null; - } - privatePoolV1ConfigBuilder_.clear(); - } - return this; - } - /** - * - * - *
-     * Private Pool using a v1 configuration.
-     * 
- * - * .google.devtools.cloudbuild.v1.PrivatePoolV1Config private_pool_v1_config = 12; - */ - public com.google.cloudbuild.v1.PrivatePoolV1Config.Builder getPrivatePoolV1ConfigBuilder() { - return getPrivatePoolV1ConfigFieldBuilder().getBuilder(); - } - /** - * - * - *
-     * Private Pool using a v1 configuration.
-     * 
- * - * .google.devtools.cloudbuild.v1.PrivatePoolV1Config private_pool_v1_config = 12; - */ - @java.lang.Override - public com.google.cloudbuild.v1.PrivatePoolV1ConfigOrBuilder getPrivatePoolV1ConfigOrBuilder() { - if ((configCase_ == 12) && (privatePoolV1ConfigBuilder_ != null)) { - return privatePoolV1ConfigBuilder_.getMessageOrBuilder(); - } else { - if (configCase_ == 12) { - return (com.google.cloudbuild.v1.PrivatePoolV1Config) config_; - } - return com.google.cloudbuild.v1.PrivatePoolV1Config.getDefaultInstance(); - } - } - /** - * - * - *
-     * Private Pool using a v1 configuration.
-     * 
- * - * .google.devtools.cloudbuild.v1.PrivatePoolV1Config private_pool_v1_config = 12; - */ - private com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.PrivatePoolV1Config, - com.google.cloudbuild.v1.PrivatePoolV1Config.Builder, - com.google.cloudbuild.v1.PrivatePoolV1ConfigOrBuilder> - getPrivatePoolV1ConfigFieldBuilder() { - if (privatePoolV1ConfigBuilder_ == null) { - if (!(configCase_ == 12)) { - config_ = com.google.cloudbuild.v1.PrivatePoolV1Config.getDefaultInstance(); - } - privatePoolV1ConfigBuilder_ = - new com.google.protobuf.SingleFieldBuilderV3< - com.google.cloudbuild.v1.PrivatePoolV1Config, - com.google.cloudbuild.v1.PrivatePoolV1Config.Builder, - com.google.cloudbuild.v1.PrivatePoolV1ConfigOrBuilder>( - (com.google.cloudbuild.v1.PrivatePoolV1Config) config_, - getParentForChildren(), - isClean()); - config_ = null; - } - configCase_ = 12; - onChanged(); - ; - return privatePoolV1ConfigBuilder_; - } - - private java.lang.Object etag_ = ""; - /** - * - * - *
-     * Output only. Checksum computed by the server. May be sent on update and
-     * delete requests to ensure that the client has an up-to-date value before
-     * proceeding.
-     * 
- * - * string etag = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The etag. - */ - public java.lang.String getEtag() { - java.lang.Object ref = etag_; - if (!(ref instanceof java.lang.String)) { - com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - etag_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * - * - *
-     * Output only. Checksum computed by the server. May be sent on update and
-     * delete requests to ensure that the client has an up-to-date value before
-     * proceeding.
-     * 
- * - * string etag = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The bytes for etag. - */ - public com.google.protobuf.ByteString getEtagBytes() { - java.lang.Object ref = etag_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); - etag_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * - * - *
-     * Output only. Checksum computed by the server. May be sent on update and
-     * delete requests to ensure that the client has an up-to-date value before
-     * proceeding.
-     * 
- * - * string etag = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @param value The etag to set. - * @return This builder for chaining. - */ - public Builder setEtag(java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - - etag_ = value; - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. Checksum computed by the server. May be sent on update and
-     * delete requests to ensure that the client has an up-to-date value before
-     * proceeding.
-     * 
- * - * string etag = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return This builder for chaining. - */ - public Builder clearEtag() { - - etag_ = getDefaultInstance().getEtag(); - onChanged(); - return this; - } - /** - * - * - *
-     * Output only. Checksum computed by the server. May be sent on update and
-     * delete requests to ensure that the client has an up-to-date value before
-     * proceeding.
-     * 
- * - * string etag = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @param value The bytes for etag to set. - * @return This builder for chaining. - */ - public Builder setEtagBytes(com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - - etag_ = value; - onChanged(); - return this; - } - - @java.lang.Override - public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.setUnknownFields(unknownFields); - } - - @java.lang.Override - public final Builder mergeUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { - return super.mergeUnknownFields(unknownFields); - } - - // @@protoc_insertion_point(builder_scope:google.devtools.cloudbuild.v1.WorkerPool) - } - - // @@protoc_insertion_point(class_scope:google.devtools.cloudbuild.v1.WorkerPool) - private static final com.google.cloudbuild.v1.WorkerPool DEFAULT_INSTANCE; - - static { - DEFAULT_INSTANCE = new com.google.cloudbuild.v1.WorkerPool(); - } - - public static com.google.cloudbuild.v1.WorkerPool getDefaultInstance() { - return DEFAULT_INSTANCE; - } - - private static final com.google.protobuf.Parser PARSER = - new com.google.protobuf.AbstractParser() { - @java.lang.Override - public WorkerPool parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - Builder builder = newBuilder(); - try { - builder.mergeFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(builder.buildPartial()); - } catch (com.google.protobuf.UninitializedMessageException e) { - throw e.asInvalidProtocolBufferException().setUnfinishedMessage(builder.buildPartial()); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException(e) - .setUnfinishedMessage(builder.buildPartial()); - } - return builder.buildPartial(); - } - }; - - public static com.google.protobuf.Parser parser() { - return PARSER; - } - - @java.lang.Override - public com.google.protobuf.Parser getParserForType() { - return PARSER; - } - - @java.lang.Override - public com.google.cloudbuild.v1.WorkerPool getDefaultInstanceForType() { - return DEFAULT_INSTANCE; - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/WorkerPoolName.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/WorkerPoolName.java deleted file mode 100644 index 0deab532..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/WorkerPoolName.java +++ /dev/null @@ -1,223 +0,0 @@ -/* - * Copyright 2022 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -package com.google.cloudbuild.v1; - -import com.google.api.pathtemplate.PathTemplate; -import com.google.api.resourcenames.ResourceName; -import com.google.common.base.Preconditions; -import com.google.common.collect.ImmutableMap; -import java.util.ArrayList; -import java.util.List; -import java.util.Map; -import java.util.Objects; -import javax.annotation.Generated; - -// AUTO-GENERATED DOCUMENTATION AND CLASS. -@Generated("by gapic-generator-java") -public class WorkerPoolName implements ResourceName { - private static final PathTemplate PROJECT_LOCATION_WORKER_POOL = - PathTemplate.createWithoutUrlEncoding( - "projects/{project}/locations/{location}/workerPools/{worker_pool}"); - private volatile Map fieldValuesMap; - private final String project; - private final String location; - private final String workerPool; - - @Deprecated - protected WorkerPoolName() { - project = null; - location = null; - workerPool = null; - } - - private WorkerPoolName(Builder builder) { - project = Preconditions.checkNotNull(builder.getProject()); - location = Preconditions.checkNotNull(builder.getLocation()); - workerPool = Preconditions.checkNotNull(builder.getWorkerPool()); - } - - public String getProject() { - return project; - } - - public String getLocation() { - return location; - } - - public String getWorkerPool() { - return workerPool; - } - - public static Builder newBuilder() { - return new Builder(); - } - - public Builder toBuilder() { - return new Builder(this); - } - - public static WorkerPoolName of(String project, String location, String workerPool) { - return newBuilder().setProject(project).setLocation(location).setWorkerPool(workerPool).build(); - } - - public static String format(String project, String location, String workerPool) { - return newBuilder() - .setProject(project) - .setLocation(location) - .setWorkerPool(workerPool) - .build() - .toString(); - } - - public static WorkerPoolName parse(String formattedString) { - if (formattedString.isEmpty()) { - return null; - } - Map matchMap = - PROJECT_LOCATION_WORKER_POOL.validatedMatch( - formattedString, "WorkerPoolName.parse: formattedString not in valid format"); - return of(matchMap.get("project"), matchMap.get("location"), matchMap.get("worker_pool")); - } - - public static List parseList(List formattedStrings) { - List list = new ArrayList<>(formattedStrings.size()); - for (String formattedString : formattedStrings) { - list.add(parse(formattedString)); - } - return list; - } - - public static List toStringList(List values) { - List list = new ArrayList<>(values.size()); - for (WorkerPoolName value : values) { - if (value == null) { - list.add(""); - } else { - list.add(value.toString()); - } - } - return list; - } - - public static boolean isParsableFrom(String formattedString) { - return PROJECT_LOCATION_WORKER_POOL.matches(formattedString); - } - - @Override - public Map getFieldValuesMap() { - if (fieldValuesMap == null) { - synchronized (this) { - if (fieldValuesMap == null) { - ImmutableMap.Builder fieldMapBuilder = ImmutableMap.builder(); - if (project != null) { - fieldMapBuilder.put("project", project); - } - if (location != null) { - fieldMapBuilder.put("location", location); - } - if (workerPool != null) { - fieldMapBuilder.put("worker_pool", workerPool); - } - fieldValuesMap = fieldMapBuilder.build(); - } - } - } - return fieldValuesMap; - } - - public String getFieldValue(String fieldName) { - return getFieldValuesMap().get(fieldName); - } - - @Override - public String toString() { - return PROJECT_LOCATION_WORKER_POOL.instantiate( - "project", project, "location", location, "worker_pool", workerPool); - } - - @Override - public boolean equals(Object o) { - if (o == this) { - return true; - } - if (o != null || getClass() == o.getClass()) { - WorkerPoolName that = ((WorkerPoolName) o); - return Objects.equals(this.project, that.project) - && Objects.equals(this.location, that.location) - && Objects.equals(this.workerPool, that.workerPool); - } - return false; - } - - @Override - public int hashCode() { - int h = 1; - h *= 1000003; - h ^= Objects.hashCode(project); - h *= 1000003; - h ^= Objects.hashCode(location); - h *= 1000003; - h ^= Objects.hashCode(workerPool); - return h; - } - - /** Builder for projects/{project}/locations/{location}/workerPools/{worker_pool}. */ - public static class Builder { - private String project; - private String location; - private String workerPool; - - protected Builder() {} - - public String getProject() { - return project; - } - - public String getLocation() { - return location; - } - - public String getWorkerPool() { - return workerPool; - } - - public Builder setProject(String project) { - this.project = project; - return this; - } - - public Builder setLocation(String location) { - this.location = location; - return this; - } - - public Builder setWorkerPool(String workerPool) { - this.workerPool = workerPool; - return this; - } - - private Builder(WorkerPoolName workerPoolName) { - this.project = workerPoolName.project; - this.location = workerPoolName.location; - this.workerPool = workerPoolName.workerPool; - } - - public WorkerPoolName build() { - return new WorkerPoolName(this); - } - } -} diff --git a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/WorkerPoolOrBuilder.java b/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/WorkerPoolOrBuilder.java deleted file mode 100644 index b99ab1ef..00000000 --- a/proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/WorkerPoolOrBuilder.java +++ /dev/null @@ -1,392 +0,0 @@ -/* - * Copyright 2020 Google LLC - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * https://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: google/devtools/cloudbuild/v1/cloudbuild.proto - -package com.google.cloudbuild.v1; - -public interface WorkerPoolOrBuilder - extends - // @@protoc_insertion_point(interface_extends:google.devtools.cloudbuild.v1.WorkerPool) - com.google.protobuf.MessageOrBuilder { - - /** - * - * - *
-   * Output only. The resource name of the `WorkerPool`, with format
-   * `projects/{project}/locations/{location}/workerPools/{worker_pool}`.
-   * The value of `{worker_pool}` is provided by `worker_pool_id` in
-   * `CreateWorkerPool` request and the value of `{location}` is determined by
-   * the endpoint accessed.
-   * 
- * - * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The name. - */ - java.lang.String getName(); - /** - * - * - *
-   * Output only. The resource name of the `WorkerPool`, with format
-   * `projects/{project}/locations/{location}/workerPools/{worker_pool}`.
-   * The value of `{worker_pool}` is provided by `worker_pool_id` in
-   * `CreateWorkerPool` request and the value of `{location}` is determined by
-   * the endpoint accessed.
-   * 
- * - * string name = 1 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The bytes for name. - */ - com.google.protobuf.ByteString getNameBytes(); - - /** - * - * - *
-   * A user-specified, human-readable name for the `WorkerPool`. If provided,
-   * this value must be 1-63 characters.
-   * 
- * - * string display_name = 2; - * - * @return The displayName. - */ - java.lang.String getDisplayName(); - /** - * - * - *
-   * A user-specified, human-readable name for the `WorkerPool`. If provided,
-   * this value must be 1-63 characters.
-   * 
- * - * string display_name = 2; - * - * @return The bytes for displayName. - */ - com.google.protobuf.ByteString getDisplayNameBytes(); - - /** - * - * - *
-   * Output only. A unique identifier for the `WorkerPool`.
-   * 
- * - * string uid = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The uid. - */ - java.lang.String getUid(); - /** - * - * - *
-   * Output only. A unique identifier for the `WorkerPool`.
-   * 
- * - * string uid = 3 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The bytes for uid. - */ - com.google.protobuf.ByteString getUidBytes(); - - /** - * - * - *
-   * User specified annotations. See https://google.aip.dev/128#annotations
-   * for more details such as format and size limitations.
-   * 
- * - * map<string, string> annotations = 4; - */ - int getAnnotationsCount(); - /** - * - * - *
-   * User specified annotations. See https://google.aip.dev/128#annotations
-   * for more details such as format and size limitations.
-   * 
- * - * map<string, string> annotations = 4; - */ - boolean containsAnnotations(java.lang.String key); - /** Use {@link #getAnnotationsMap()} instead. */ - @java.lang.Deprecated - java.util.Map getAnnotations(); - /** - * - * - *
-   * User specified annotations. See https://google.aip.dev/128#annotations
-   * for more details such as format and size limitations.
-   * 
- * - * map<string, string> annotations = 4; - */ - java.util.Map getAnnotationsMap(); - /** - * - * - *
-   * User specified annotations. See https://google.aip.dev/128#annotations
-   * for more details such as format and size limitations.
-   * 
- * - * map<string, string> annotations = 4; - */ - - /* nullable */ - java.lang.String getAnnotationsOrDefault( - java.lang.String key, - /* nullable */ - java.lang.String defaultValue); - /** - * - * - *
-   * User specified annotations. See https://google.aip.dev/128#annotations
-   * for more details such as format and size limitations.
-   * 
- * - * map<string, string> annotations = 4; - */ - java.lang.String getAnnotationsOrThrow(java.lang.String key); - - /** - * - * - *
-   * Output only. Time at which the request to create the `WorkerPool` was
-   * received.
-   * 
- * - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return Whether the createTime field is set. - */ - boolean hasCreateTime(); - /** - * - * - *
-   * Output only. Time at which the request to create the `WorkerPool` was
-   * received.
-   * 
- * - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The createTime. - */ - com.google.protobuf.Timestamp getCreateTime(); - /** - * - * - *
-   * Output only. Time at which the request to create the `WorkerPool` was
-   * received.
-   * 
- * - * .google.protobuf.Timestamp create_time = 5 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - com.google.protobuf.TimestampOrBuilder getCreateTimeOrBuilder(); - - /** - * - * - *
-   * Output only. Time at which the request to update the `WorkerPool` was
-   * received.
-   * 
- * - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return Whether the updateTime field is set. - */ - boolean hasUpdateTime(); - /** - * - * - *
-   * Output only. Time at which the request to update the `WorkerPool` was
-   * received.
-   * 
- * - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The updateTime. - */ - com.google.protobuf.Timestamp getUpdateTime(); - /** - * - * - *
-   * Output only. Time at which the request to update the `WorkerPool` was
-   * received.
-   * 
- * - * .google.protobuf.Timestamp update_time = 6 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - com.google.protobuf.TimestampOrBuilder getUpdateTimeOrBuilder(); - - /** - * - * - *
-   * Output only. Time at which the request to delete the `WorkerPool` was
-   * received.
-   * 
- * - * .google.protobuf.Timestamp delete_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return Whether the deleteTime field is set. - */ - boolean hasDeleteTime(); - /** - * - * - *
-   * Output only. Time at which the request to delete the `WorkerPool` was
-   * received.
-   * 
- * - * .google.protobuf.Timestamp delete_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The deleteTime. - */ - com.google.protobuf.Timestamp getDeleteTime(); - /** - * - * - *
-   * Output only. Time at which the request to delete the `WorkerPool` was
-   * received.
-   * 
- * - * .google.protobuf.Timestamp delete_time = 7 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - */ - com.google.protobuf.TimestampOrBuilder getDeleteTimeOrBuilder(); - - /** - * - * - *
-   * Output only. `WorkerPool` state.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.WorkerPool.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The enum numeric value on the wire for state. - */ - int getStateValue(); - /** - * - * - *
-   * Output only. `WorkerPool` state.
-   * 
- * - * - * .google.devtools.cloudbuild.v1.WorkerPool.State state = 8 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * - * @return The state. - */ - com.google.cloudbuild.v1.WorkerPool.State getState(); - - /** - * - * - *
-   * Private Pool using a v1 configuration.
-   * 
- * - * .google.devtools.cloudbuild.v1.PrivatePoolV1Config private_pool_v1_config = 12; - * - * @return Whether the privatePoolV1Config field is set. - */ - boolean hasPrivatePoolV1Config(); - /** - * - * - *
-   * Private Pool using a v1 configuration.
-   * 
- * - * .google.devtools.cloudbuild.v1.PrivatePoolV1Config private_pool_v1_config = 12; - * - * @return The privatePoolV1Config. - */ - com.google.cloudbuild.v1.PrivatePoolV1Config getPrivatePoolV1Config(); - /** - * - * - *
-   * Private Pool using a v1 configuration.
-   * 
- * - * .google.devtools.cloudbuild.v1.PrivatePoolV1Config private_pool_v1_config = 12; - */ - com.google.cloudbuild.v1.PrivatePoolV1ConfigOrBuilder getPrivatePoolV1ConfigOrBuilder(); - - /** - * - * - *
-   * Output only. Checksum computed by the server. May be sent on update and
-   * delete requests to ensure that the client has an up-to-date value before
-   * proceeding.
-   * 
- * - * string etag = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The etag. - */ - java.lang.String getEtag(); - /** - * - * - *
-   * Output only. Checksum computed by the server. May be sent on update and
-   * delete requests to ensure that the client has an up-to-date value before
-   * proceeding.
-   * 
- * - * string etag = 11 [(.google.api.field_behavior) = OUTPUT_ONLY]; - * - * @return The bytes for etag. - */ - com.google.protobuf.ByteString getEtagBytes(); - - public com.google.cloudbuild.v1.WorkerPool.ConfigCase getConfigCase(); -} diff --git a/proto-google-cloud-build-v1/src/main/proto/google/devtools/cloudbuild/v1/cloudbuild.proto b/proto-google-cloud-build-v1/src/main/proto/google/devtools/cloudbuild/v1/cloudbuild.proto deleted file mode 100644 index 3f980c7b..00000000 --- a/proto-google-cloud-build-v1/src/main/proto/google/devtools/cloudbuild/v1/cloudbuild.proto +++ /dev/null @@ -1,2142 +0,0 @@ -// Copyright 2021 Google LLC -// -// Licensed under the Apache License, Version 2.0 (the "License"); -// you may not use this file except in compliance with the License. -// You may obtain a copy of the License at -// -// http://www.apache.org/licenses/LICENSE-2.0 -// -// Unless required by applicable law or agreed to in writing, software -// distributed under the License is distributed on an "AS IS" BASIS, -// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -// See the License for the specific language governing permissions and -// limitations under the License. - -syntax = "proto3"; - -package google.devtools.cloudbuild.v1; - -import "google/api/annotations.proto"; -import "google/api/client.proto"; -import "google/api/field_behavior.proto"; -import "google/api/httpbody.proto"; -import "google/api/resource.proto"; -import "google/longrunning/operations.proto"; -import "google/protobuf/duration.proto"; -import "google/protobuf/empty.proto"; -import "google/protobuf/field_mask.proto"; -import "google/protobuf/timestamp.proto"; - -option csharp_namespace = "Google.Cloud.CloudBuild.V1"; -option go_package = "google.golang.org/genproto/googleapis/devtools/cloudbuild/v1;cloudbuild"; -option java_multiple_files = true; -option java_package = "com.google.cloudbuild.v1"; -option objc_class_prefix = "GCB"; -option ruby_package = "Google::Cloud::Build::V1"; -option (google.api.resource_definition) = { - type: "compute.googleapis.com/Network" - pattern: "projects/{project}/global/networks/{network}" -}; -option (google.api.resource_definition) = { - type: "iam.googleapis.com/ServiceAccount" - pattern: "projects/{project}/serviceAccounts/{service_account}" -}; -option (google.api.resource_definition) = { - type: "secretmanager.googleapis.com/Secret" - pattern: "projects/{project}/secrets/{secret}" -}; -option (google.api.resource_definition) = { - type: "secretmanager.googleapis.com/SecretVersion" - pattern: "projects/{project}/secrets/{secret}/versions/{version}" -}; -option (google.api.resource_definition) = { - type: "cloudkms.googleapis.com/CryptoKey" - pattern: "projects/{project}/locations/{location}/keyRings/{keyring}/cryptoKeys/{key}" -}; -option (google.api.resource_definition) = { - type: "pubsub.googleapis.com/Subscription" - pattern: "projects/{project}/subscriptions/{subscription}" -}; -option (google.api.resource_definition) = { - type: "pubsub.googleapis.com/Topic" - pattern: "projects/{project}/topics/{topic}" -}; - -// Creates and manages builds on Google Cloud Platform. -// -// The main concept used by this API is a `Build`, which describes the location -// of the source to build, how to build the source, and where to store the -// built artifacts, if any. -// -// A user can list previously-requested builds or get builds by their ID to -// determine the status of the build. -service CloudBuild { - option (google.api.default_host) = "cloudbuild.googleapis.com"; - option (google.api.oauth_scopes) = - "https://www.googleapis.com/auth/cloud-platform"; - - // Starts a build with the specified configuration. - // - // This method returns a long-running `Operation`, which includes the build - // ID. Pass the build ID to `GetBuild` to determine the build status (such as - // `SUCCESS` or `FAILURE`). - rpc CreateBuild(CreateBuildRequest) returns (google.longrunning.Operation) { - option (google.api.http) = { - post: "/v1/projects/{project_id}/builds" - body: "build" - additional_bindings { - post: "/v1/{parent=projects/*/locations/*}/builds" - body: "build" - } - }; - option (google.api.method_signature) = "project_id,build"; - option (google.longrunning.operation_info) = { - response_type: "Build" - metadata_type: "BuildOperationMetadata" - }; - } - - // Returns information about a previously requested build. - // - // The `Build` that is returned includes its status (such as `SUCCESS`, - // `FAILURE`, or `WORKING`), and timing information. - rpc GetBuild(GetBuildRequest) returns (Build) { - option (google.api.http) = { - get: "/v1/projects/{project_id}/builds/{id}" - additional_bindings { get: "/v1/{name=projects/*/locations/*/builds/*}" } - }; - option (google.api.method_signature) = "project_id,id"; - } - - // Lists previously requested builds. - // - // Previously requested builds may still be in-progress, or may have finished - // successfully or unsuccessfully. - rpc ListBuilds(ListBuildsRequest) returns (ListBuildsResponse) { - option (google.api.http) = { - get: "/v1/projects/{project_id}/builds" - additional_bindings { get: "/v1/{parent=projects/*/locations/*}/builds" } - }; - option (google.api.method_signature) = "project_id,filter"; - } - - // Cancels a build in progress. - rpc CancelBuild(CancelBuildRequest) returns (Build) { - option (google.api.http) = { - post: "/v1/projects/{project_id}/builds/{id}:cancel" - body: "*" - additional_bindings { - post: "/v1/{name=projects/*/locations/*/builds/*}:cancel" - body: "*" - } - }; - option (google.api.method_signature) = "project_id,id"; - } - - // Creates a new build based on the specified build. - // - // This method creates a new build using the original build request, which may - // or may not result in an identical build. - // - // For triggered builds: - // - // * Triggered builds resolve to a precise revision; therefore a retry of a - // triggered build will result in a build that uses the same revision. - // - // For non-triggered builds that specify `RepoSource`: - // - // * If the original build built from the tip of a branch, the retried build - // will build from the tip of that branch, which may not be the same revision - // as the original build. - // * If the original build specified a commit sha or revision ID, the retried - // build will use the identical source. - // - // For builds that specify `StorageSource`: - // - // * If the original build pulled source from Google Cloud Storage without - // specifying the generation of the object, the new build will use the current - // object, which may be different from the original build source. - // * If the original build pulled source from Cloud Storage and specified the - // generation of the object, the new build will attempt to use the same - // object, which may or may not be available depending on the bucket's - // lifecycle management settings. - rpc RetryBuild(RetryBuildRequest) returns (google.longrunning.Operation) { - option (google.api.http) = { - post: "/v1/projects/{project_id}/builds/{id}:retry" - body: "*" - additional_bindings { - post: "/v1/{name=projects/*/locations/*/builds/*}:retry" - body: "*" - } - }; - option (google.api.method_signature) = "project_id,id"; - option (google.longrunning.operation_info) = { - response_type: "Build" - metadata_type: "BuildOperationMetadata" - }; - } - - // Approves or rejects a pending build. - // - // If approved, the returned LRO will be analogous to the LRO returned from - // a CreateBuild call. - // - // If rejected, the returned LRO will be immediately done. - rpc ApproveBuild(ApproveBuildRequest) returns (google.longrunning.Operation) { - option (google.api.http) = { - post: "/v1/{name=projects/*/builds/*}:approve" - body: "*" - additional_bindings { - post: "/v1/{name=projects/*/locations/*/builds/*}:approve" - body: "*" - } - }; - option (google.api.method_signature) = "name,approval_result"; - option (google.longrunning.operation_info) = { - response_type: "Build" - metadata_type: "BuildOperationMetadata" - }; - } - - // Creates a new `BuildTrigger`. - // - // This API is experimental. - rpc CreateBuildTrigger(CreateBuildTriggerRequest) returns (BuildTrigger) { - option (google.api.http) = { - post: "/v1/projects/{project_id}/triggers" - body: "trigger" - additional_bindings { - post: "/v1/{parent=projects/*/locations/*}/triggers" - body: "trigger" - } - }; - option (google.api.method_signature) = "project_id,trigger"; - } - - // Returns information about a `BuildTrigger`. - // - // This API is experimental. - rpc GetBuildTrigger(GetBuildTriggerRequest) returns (BuildTrigger) { - option (google.api.http) = { - get: "/v1/projects/{project_id}/triggers/{trigger_id}" - additional_bindings { - get: "/v1/{name=projects/*/locations/*/triggers/*}" - } - }; - option (google.api.method_signature) = "project_id,trigger_id"; - } - - // Lists existing `BuildTrigger`s. - // - // This API is experimental. - rpc ListBuildTriggers(ListBuildTriggersRequest) - returns (ListBuildTriggersResponse) { - option (google.api.http) = { - get: "/v1/projects/{project_id}/triggers" - additional_bindings { - get: "/v1/{parent=projects/*/locations/*}/triggers" - } - }; - option (google.api.method_signature) = "project_id"; - } - - // Deletes a `BuildTrigger` by its project ID and trigger ID. - // - // This API is experimental. - rpc DeleteBuildTrigger(DeleteBuildTriggerRequest) - returns (google.protobuf.Empty) { - option (google.api.http) = { - delete: "/v1/projects/{project_id}/triggers/{trigger_id}" - additional_bindings { - delete: "/v1/{name=projects/*/locations/*/triggers/*}" - } - }; - option (google.api.method_signature) = "project_id,trigger_id"; - } - - // Updates a `BuildTrigger` by its project ID and trigger ID. - // - // This API is experimental. - rpc UpdateBuildTrigger(UpdateBuildTriggerRequest) returns (BuildTrigger) { - option (google.api.http) = { - patch: "/v1/projects/{project_id}/triggers/{trigger_id}" - body: "trigger" - additional_bindings { - patch: "/v1/{trigger.resource_name=projects/*/locations/*/triggers/*}" - body: "trigger" - } - }; - option (google.api.method_signature) = "project_id,trigger_id,trigger"; - } - - // Runs a `BuildTrigger` at a particular source revision. - rpc RunBuildTrigger(RunBuildTriggerRequest) - returns (google.longrunning.Operation) { - option (google.api.http) = { - post: "/v1/projects/{project_id}/triggers/{trigger_id}:run" - body: "source" - additional_bindings { - post: "/v1/{name=projects/*/locations/*/triggers/*}:run" - body: "*" - } - }; - option (google.api.method_signature) = "project_id,trigger_id,source"; - option (google.longrunning.operation_info) = { - response_type: "Build" - metadata_type: "BuildOperationMetadata" - }; - } - - // ReceiveTriggerWebhook [Experimental] is called when the API receives a - // webhook request targeted at a specific trigger. - rpc ReceiveTriggerWebhook(ReceiveTriggerWebhookRequest) - returns (ReceiveTriggerWebhookResponse) { - option (google.api.http) = { - post: "/v1/projects/{project_id}/triggers/{trigger}:webhook" - body: "body" - additional_bindings { - post: "/v1/{name=projects/*/locations/*/triggers/*}:webhook" - body: "body" - } - }; - } - - // Creates a `WorkerPool`. - rpc CreateWorkerPool(CreateWorkerPoolRequest) - returns (google.longrunning.Operation) { - option (google.api.http) = { - post: "/v1/{parent=projects/*/locations/*}/workerPools" - body: "worker_pool" - }; - option (google.api.method_signature) = "parent,worker_pool,worker_pool_id"; - option (google.longrunning.operation_info) = { - response_type: "WorkerPool" - metadata_type: "CreateWorkerPoolOperationMetadata" - }; - } - - // Returns details of a `WorkerPool`. - rpc GetWorkerPool(GetWorkerPoolRequest) returns (WorkerPool) { - option (google.api.http) = { - get: "/v1/{name=projects/*/locations/*/workerPools/*}" - }; - option (google.api.method_signature) = "name"; - } - - // Deletes a `WorkerPool`. - rpc DeleteWorkerPool(DeleteWorkerPoolRequest) - returns (google.longrunning.Operation) { - option (google.api.http) = { - delete: "/v1/{name=projects/*/locations/*/workerPools/*}" - }; - option (google.api.method_signature) = "name"; - option (google.longrunning.operation_info) = { - response_type: "google.protobuf.Empty" - metadata_type: "DeleteWorkerPoolOperationMetadata" - }; - } - - // Updates a `WorkerPool`. - rpc UpdateWorkerPool(UpdateWorkerPoolRequest) - returns (google.longrunning.Operation) { - option (google.api.http) = { - patch: "/v1/{worker_pool.name=projects/*/locations/*/workerPools/*}" - body: "worker_pool" - }; - option (google.api.method_signature) = "worker_pool,update_mask"; - option (google.longrunning.operation_info) = { - response_type: "WorkerPool" - metadata_type: "UpdateWorkerPoolOperationMetadata" - }; - } - - // Lists `WorkerPool`s. - rpc ListWorkerPools(ListWorkerPoolsRequest) - returns (ListWorkerPoolsResponse) { - option (google.api.http) = { - get: "/v1/{parent=projects/*/locations/*}/workerPools" - }; - option (google.api.method_signature) = "parent"; - } -} - -// Specifies a build to retry. -message RetryBuildRequest { - // The name of the `Build` to retry. - // Format: `projects/{project}/locations/{location}/builds/{build}` - string name = 3 [(google.api.resource_reference) = { - type: "cloudbuild.googleapis.com/Build" - }]; - - // Required. ID of the project. - string project_id = 1 [(google.api.field_behavior) = REQUIRED]; - - // Required. Build ID of the original build. - string id = 2 [(google.api.field_behavior) = REQUIRED]; -} - -// Specifies a build trigger to run and the source to use. -message RunBuildTriggerRequest { - // The name of the `Trigger` to run. - // Format: `projects/{project}/locations/{location}/triggers/{trigger}` - string name = 4 [(google.api.resource_reference) = { - type: "cloudbuild.googleapis.com/BuildTrigger" - }]; - - // Required. ID of the project. - string project_id = 1 [(google.api.field_behavior) = REQUIRED]; - - // Required. ID of the trigger. - string trigger_id = 2 [(google.api.field_behavior) = REQUIRED]; - - // Source to build against this trigger. - RepoSource source = 3; -} - -// Location of the source in an archive file in Google Cloud Storage. -message StorageSource { - // Google Cloud Storage bucket containing the source (see - // [Bucket Name - // Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)). - string bucket = 1; - - // Google Cloud Storage object containing the source. - // - // This object must be a gzipped archive file (`.tar.gz`) containing source to - // build. - string object = 2; - - // Google Cloud Storage generation for the object. If the generation is - // omitted, the latest generation will be used. - int64 generation = 3; -} - -// Location of the source in a Google Cloud Source Repository. -message RepoSource { - // ID of the project that owns the Cloud Source Repository. If omitted, the - // project ID requesting the build is assumed. - string project_id = 1; - - // Name of the Cloud Source Repository. - string repo_name = 2; - - // A revision within the Cloud Source Repository must be specified in - // one of these ways. - oneof revision { - // Regex matching branches to build. - // - // The syntax of the regular expressions accepted is the syntax accepted by - // RE2 and described at https://github.com/google/re2/wiki/Syntax - string branch_name = 3; - - // Regex matching tags to build. - // - // The syntax of the regular expressions accepted is the syntax accepted by - // RE2 and described at https://github.com/google/re2/wiki/Syntax - string tag_name = 4; - - // Explicit commit SHA to build. - string commit_sha = 5; - } - - // Directory, relative to the source root, in which to run the build. - // - // This must be a relative path. If a step's `dir` is specified and is an - // absolute path, this value is ignored for that step's execution. - string dir = 7; - - // Only trigger a build if the revision regex does NOT match the revision - // regex. - bool invert_regex = 8; - - // Substitutions to use in a triggered build. - // Should only be used with RunBuildTrigger - map substitutions = 9; -} - -// Location of the source manifest in Google Cloud Storage. -// This feature is in Preview; see description -// [here](https://github.com/GoogleCloudPlatform/cloud-builders/tree/master/gcs-fetcher). -message StorageSourceManifest { - // Google Cloud Storage bucket containing the source manifest (see [Bucket - // Name - // Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)). - string bucket = 1; - - // Google Cloud Storage object containing the source manifest. - // - // This object must be a JSON file. - string object = 2; - - // Google Cloud Storage generation for the object. If the generation is - // omitted, the latest generation will be used. - int64 generation = 3; -} - -// Location of the source in a supported storage service. -message Source { - // Location of source. - oneof source { - // If provided, get the source from this location in Google Cloud Storage. - StorageSource storage_source = 2; - - // If provided, get the source from this location in a Cloud Source - // Repository. - RepoSource repo_source = 3; - - // If provided, get the source from this manifest in Google Cloud Storage. - // This feature is in Preview; see description - // [here](https://github.com/GoogleCloudPlatform/cloud-builders/tree/master/gcs-fetcher). - StorageSourceManifest storage_source_manifest = 8; - } -} - -// An image built by the pipeline. -message BuiltImage { - // Name used to push the container image to Google Container Registry, as - // presented to `docker push`. - string name = 1; - - // Docker Registry 2.0 digest. - string digest = 3; - - // Output only. Stores timing information for pushing the specified image. - TimeSpan push_timing = 4 [(google.api.field_behavior) = OUTPUT_ONLY]; -} - -// A step in the build pipeline. -message BuildStep { - // Required. The name of the container image that will run this particular - // build step. - // - // If the image is available in the host's Docker daemon's cache, it - // will be run directly. If not, the host will attempt to pull the image - // first, using the builder service account's credentials if necessary. - // - // The Docker daemon's cache will already have the latest versions of all of - // the officially supported build steps - // ([https://github.com/GoogleCloudPlatform/cloud-builders](https://github.com/GoogleCloudPlatform/cloud-builders)). - // The Docker daemon will also have cached many of the layers for some popular - // images, like "ubuntu", "debian", but they will be refreshed at the time you - // attempt to use them. - // - // If you built an image in a previous build step, it will be stored in the - // host's Docker daemon's cache and is available to use as the name for a - // later build step. - string name = 1; - - // A list of environment variable definitions to be used when running a step. - // - // The elements are of the form "KEY=VALUE" for the environment variable "KEY" - // being given the value "VALUE". - repeated string env = 2; - - // A list of arguments that will be presented to the step when it is started. - // - // If the image used to run the step's container has an entrypoint, the `args` - // are used as arguments to that entrypoint. If the image does not define - // an entrypoint, the first element in args is used as the entrypoint, - // and the remainder will be used as arguments. - repeated string args = 3; - - // Working directory to use when running this step's container. - // - // If this value is a relative path, it is relative to the build's working - // directory. If this value is absolute, it may be outside the build's working - // directory, in which case the contents of the path may not be persisted - // across build step executions, unless a `volume` for that path is specified. - // - // If the build specifies a `RepoSource` with `dir` and a step with a `dir`, - // which specifies an absolute path, the `RepoSource` `dir` is ignored for - // the step's execution. - string dir = 4; - - // Unique identifier for this build step, used in `wait_for` to - // reference this build step as a dependency. - string id = 5; - - // The ID(s) of the step(s) that this build step depends on. - // This build step will not start until all the build steps in `wait_for` - // have completed successfully. If `wait_for` is empty, this build step will - // start when all previous build steps in the `Build.Steps` list have - // completed successfully. - repeated string wait_for = 6; - - // Entrypoint to be used instead of the build step image's default entrypoint. - // If unset, the image's default entrypoint is used. - string entrypoint = 7; - - // A list of environment variables which are encrypted using a Cloud Key - // Management Service crypto key. These values must be specified in the - // build's `Secret`. - repeated string secret_env = 8; - - // List of volumes to mount into the build step. - // - // Each volume is created as an empty volume prior to execution of the - // build step. Upon completion of the build, volumes and their contents are - // discarded. - // - // Using a named volume in only one step is not valid as it is indicative - // of a build request with an incorrect configuration. - repeated Volume volumes = 9; - - // Output only. Stores timing information for executing this build step. - TimeSpan timing = 10 [(google.api.field_behavior) = OUTPUT_ONLY]; - - // Output only. Stores timing information for pulling this build step's - // builder image only. - TimeSpan pull_timing = 13 [(google.api.field_behavior) = OUTPUT_ONLY]; - - // Time limit for executing this build step. If not defined, the step has no - // time limit and will be allowed to continue to run until either it completes - // or the build itself times out. - google.protobuf.Duration timeout = 11; - - // Output only. Status of the build step. At this time, build step status is - // only updated on build completion; step status is not updated in real-time - // as the build progresses. - Build.Status status = 12 [(google.api.field_behavior) = OUTPUT_ONLY]; - - // A shell script to be executed in the step. - // - // When script is provided, the user cannot specify the entrypoint or args. - string script = 19; -} - -// Volume describes a Docker container volume which is mounted into build steps -// in order to persist files across build step execution. -message Volume { - // Name of the volume to mount. - // - // Volume names must be unique per build step and must be valid names for - // Docker volumes. Each named volume must be used by at least two build steps. - string name = 1; - - // Path at which to mount the volume. - // - // Paths must be absolute and cannot conflict with other volume paths on the - // same build step or with certain reserved volume paths. - string path = 2; -} - -// Artifacts created by the build pipeline. -message Results { - // Container images that were built as a part of the build. - repeated BuiltImage images = 2; - - // List of build step digests, in the order corresponding to build step - // indices. - repeated string build_step_images = 3; - - // Path to the artifact manifest. Only populated when artifacts are uploaded. - string artifact_manifest = 4; - - // Number of artifacts uploaded. Only populated when artifacts are uploaded. - int64 num_artifacts = 5; - - // List of build step outputs, produced by builder images, in the order - // corresponding to build step indices. - // - // [Cloud Builders](https://cloud.google.com/cloud-build/docs/cloud-builders) - // can produce this output by writing to `$BUILDER_OUTPUT/output`. - // Only the first 4KB of data is stored. - repeated bytes build_step_outputs = 6; - - // Time to push all non-container artifacts. - TimeSpan artifact_timing = 7; -} - -// An artifact that was uploaded during a build. This -// is a single record in the artifact manifest JSON file. -message ArtifactResult { - // The path of an artifact in a Google Cloud Storage bucket, with the - // generation number. For example, - // `gs://mybucket/path/to/output.jar#generation`. - string location = 1; - - // The file hash of the artifact. - repeated FileHashes file_hash = 2; -} - -// A build resource in the Cloud Build API. -// -// At a high level, a `Build` describes where to find source code, how to build -// it (for example, the builder image to run on the source), and where to store -// the built artifacts. -// -// Fields can include the following variables, which will be expanded when the -// build is created: -// -// - $PROJECT_ID: the project ID of the build. -// - $PROJECT_NUMBER: the project number of the build. -// - $BUILD_ID: the autogenerated ID of the build. -// - $REPO_NAME: the source repository name specified by RepoSource. -// - $BRANCH_NAME: the branch name specified by RepoSource. -// - $TAG_NAME: the tag name specified by RepoSource. -// - $REVISION_ID or $COMMIT_SHA: the commit SHA specified by RepoSource or -// resolved from the specified branch or tag. -// - $SHORT_SHA: first 7 characters of $REVISION_ID or $COMMIT_SHA. -message Build { - option (google.api.resource) = { - type: "cloudbuild.googleapis.com/Build" - pattern: "projects/{project}/builds/{build}" - pattern: "projects/{project}/locations/{location}/builds/{build}" - }; - - // A non-fatal problem encountered during the execution of the build. - message Warning { - // The relative importance of this warning. - enum Priority { - // Should not be used. - PRIORITY_UNSPECIFIED = 0; - - // e.g. deprecation warnings and alternative feature highlights. - INFO = 1; - - // e.g. automated detection of possible issues with the build. - WARNING = 2; - - // e.g. alerts that a feature used in the build is pending removal - ALERT = 3; - } - - // Explanation of the warning generated. - string text = 1; - - // The priority for this warning. - Priority priority = 2; - } - - // A fatal problem encountered during the execution of the build. - message FailureInfo { - // The name of a fatal problem encountered during the execution of the - // build. - enum FailureType { - // Type unspecified - FAILURE_TYPE_UNSPECIFIED = 0; - - // Unable to push the image to the repository. - PUSH_FAILED = 1; - - // Final image not found. - PUSH_IMAGE_NOT_FOUND = 2; - - // Unauthorized push of the final image. - PUSH_NOT_AUTHORIZED = 3; - - // Backend logging failures. Should retry. - LOGGING_FAILURE = 4; - - // A build step has failed. - USER_BUILD_STEP = 5; - - // The source fetching has failed. - FETCH_SOURCE_FAILED = 6; - } - - // The name of the failure. - FailureType type = 1; - - // Explains the failure issue in more detail using hard-coded text. - string detail = 2; - } - - // Possible status of a build or build step. - enum Status { - // Status of the build is unknown. - STATUS_UNKNOWN = 0; - - // Build has been created and is pending execution and queuing. It has not - // been queued. - PENDING = 10; - - // Build or step is queued; work has not yet begun. - QUEUED = 1; - - // Build or step is being executed. - WORKING = 2; - - // Build or step finished successfully. - SUCCESS = 3; - - // Build or step failed to complete successfully. - FAILURE = 4; - - // Build or step failed due to an internal cause. - INTERNAL_ERROR = 5; - - // Build or step took longer than was allowed. - TIMEOUT = 6; - - // Build or step was canceled by a user. - CANCELLED = 7; - - // Build was enqueued for longer than the value of `queue_ttl`. - EXPIRED = 9; - } - - // Output only. The 'Build' name with format: - // `projects/{project}/locations/{location}/builds/{build}`, where {build} - // is a unique identifier generated by the service. - string name = 45 [(google.api.field_behavior) = OUTPUT_ONLY]; - - // Output only. Unique identifier of the build. - string id = 1 [(google.api.field_behavior) = OUTPUT_ONLY]; - - // Output only. ID of the project. - string project_id = 16 [(google.api.field_behavior) = OUTPUT_ONLY]; - - // Output only. Status of the build. - Status status = 2 [(google.api.field_behavior) = OUTPUT_ONLY]; - - // Output only. Customer-readable message about the current status. - string status_detail = 24 [(google.api.field_behavior) = OUTPUT_ONLY]; - - // The location of the source files to build. - Source source = 3; - - // Required. The operations to be performed on the workspace. - repeated BuildStep steps = 11; - - // Output only. Results of the build. - Results results = 10 [(google.api.field_behavior) = OUTPUT_ONLY]; - - // Output only. Time at which the request to create the build was received. - google.protobuf.Timestamp create_time = 6 - [(google.api.field_behavior) = OUTPUT_ONLY]; - - // Output only. Time at which execution of the build was started. - google.protobuf.Timestamp start_time = 7 - [(google.api.field_behavior) = OUTPUT_ONLY]; - - // Output only. Time at which execution of the build was finished. - // - // The difference between finish_time and start_time is the duration of the - // build's execution. - google.protobuf.Timestamp finish_time = 8 - [(google.api.field_behavior) = OUTPUT_ONLY]; - - // Amount of time that this build should be allowed to run, to second - // granularity. If this amount of time elapses, work on the build will cease - // and the build status will be `TIMEOUT`. - // - // `timeout` starts ticking from `startTime`. - // - // Default time is ten minutes. - google.protobuf.Duration timeout = 12; - - // A list of images to be pushed upon the successful completion of all build - // steps. - // - // The images are pushed using the builder service account's credentials. - // - // The digests of the pushed images will be stored in the `Build` resource's - // results field. - // - // If any of the images fail to be pushed, the build status is marked - // `FAILURE`. - repeated string images = 13; - - // TTL in queue for this build. If provided and the build is enqueued longer - // than this value, the build will expire and the build status will be - // `EXPIRED`. - // - // The TTL starts ticking from create_time. - google.protobuf.Duration queue_ttl = 40; - - // Artifacts produced by the build that should be uploaded upon - // successful completion of all build steps. - Artifacts artifacts = 37; - - // Google Cloud Storage bucket where logs should be written (see - // [Bucket Name - // Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)). - // Logs file names will be of the format `${logs_bucket}/log-${build_id}.txt`. - string logs_bucket = 19; - - // Output only. A permanent fixed identifier for source. - SourceProvenance source_provenance = 21 - [(google.api.field_behavior) = OUTPUT_ONLY]; - - // Output only. The ID of the `BuildTrigger` that triggered this build, if it - // was triggered automatically. - string build_trigger_id = 22 [(google.api.field_behavior) = OUTPUT_ONLY]; - - // Special options for this build. - BuildOptions options = 23; - - // Output only. URL to logs for this build in Google Cloud Console. - string log_url = 25 [(google.api.field_behavior) = OUTPUT_ONLY]; - - // Substitutions data for `Build` resource. - map substitutions = 29; - - // Tags for annotation of a `Build`. These are not docker tags. - repeated string tags = 31; - - // Secrets to decrypt using Cloud Key Management Service. - // Note: Secret Manager is the recommended technique - // for managing sensitive data with Cloud Build. Use `available_secrets` to - // configure builds to access secrets from Secret Manager. For instructions, - // see: https://cloud.google.com/cloud-build/docs/securing-builds/use-secrets - repeated Secret secrets = 32; - - // Output only. Stores timing information for phases of the build. Valid keys - // are: - // - // * BUILD: time to execute all build steps. - // * PUSH: time to push all specified images. - // * FETCHSOURCE: time to fetch source. - // * SETUPBUILD: time to set up build. - // - // If the build does not specify source or images, - // these keys will not be included. - map timing = 33 [(google.api.field_behavior) = OUTPUT_ONLY]; - - // Output only. Describes this build's approval configuration, status, - // and result. - BuildApproval approval = 44 [(google.api.field_behavior) = OUTPUT_ONLY]; - - // IAM service account whose credentials will be used at build runtime. - // Must be of the format `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT}`. - // ACCOUNT can be email address or uniqueId of the service account. - // - string service_account = 42 [(google.api.resource_reference) = { - type: "iam.googleapis.com/ServiceAccount" - }]; - - // Secrets and secret environment variables. - Secrets available_secrets = 47; - - // Output only. Non-fatal problems encountered during the execution of the - // build. - repeated Warning warnings = 49 [(google.api.field_behavior) = OUTPUT_ONLY]; - - // Output only. Contains information about the build when status=FAILURE. - FailureInfo failure_info = 51 [(google.api.field_behavior) = OUTPUT_ONLY]; -} - -// Artifacts produced by a build that should be uploaded upon -// successful completion of all build steps. -message Artifacts { - // Files in the workspace to upload to Cloud Storage upon successful - // completion of all build steps. - message ArtifactObjects { - // Cloud Storage bucket and optional object path, in the form - // "gs://bucket/path/to/somewhere/". (see [Bucket Name - // Requirements](https://cloud.google.com/storage/docs/bucket-naming#requirements)). - // - // Files in the workspace matching any path pattern will be uploaded to - // Cloud Storage with this location as a prefix. - string location = 1; - - // Path globs used to match files in the build's workspace. - repeated string paths = 2; - - // Output only. Stores timing information for pushing all artifact objects. - TimeSpan timing = 3 [(google.api.field_behavior) = OUTPUT_ONLY]; - } - - // A list of images to be pushed upon the successful completion of all build - // steps. - // - // The images will be pushed using the builder service account's credentials. - // - // The digests of the pushed images will be stored in the Build resource's - // results field. - // - // If any of the images fail to be pushed, the build is marked FAILURE. - repeated string images = 1; - - // A list of objects to be uploaded to Cloud Storage upon successful - // completion of all build steps. - // - // Files in the workspace matching specified paths globs will be uploaded to - // the specified Cloud Storage location using the builder service account's - // credentials. - // - // The location and generation of the uploaded objects will be stored in the - // Build resource's results field. - // - // If any objects fail to be pushed, the build is marked FAILURE. - ArtifactObjects objects = 2; -} - -// Start and end times for a build execution phase. -message TimeSpan { - // Start of time span. - google.protobuf.Timestamp start_time = 1; - - // End of time span. - google.protobuf.Timestamp end_time = 2; -} - -// Metadata for build operations. -message BuildOperationMetadata { - // The build that the operation is tracking. - Build build = 1; -} - -// Provenance of the source. Ways to find the original source, or verify that -// some source was used for this build. -message SourceProvenance { - // A copy of the build's `source.storage_source`, if exists, with any - // generations resolved. - StorageSource resolved_storage_source = 3; - - // A copy of the build's `source.repo_source`, if exists, with any - // revisions resolved. - RepoSource resolved_repo_source = 6; - - // A copy of the build's `source.storage_source_manifest`, if exists, with any - // revisions resolved. - // This feature is in Preview. - StorageSourceManifest resolved_storage_source_manifest = 9; - - // Output only. Hash(es) of the build source, which can be used to verify that - // the original source integrity was maintained in the build. Note that - // `FileHashes` will only be populated if `BuildOptions` has requested a - // `SourceProvenanceHash`. - // - // The keys to this map are file paths used as build source and the values - // contain the hash values for those files. - // - // If the build source came in a single package such as a gzipped tarfile - // (`.tar.gz`), the `FileHash` will be for the single path to that file. - map file_hashes = 4 - [(google.api.field_behavior) = OUTPUT_ONLY]; -} - -// Container message for hashes of byte content of files, used in -// SourceProvenance messages to verify integrity of source input to the build. -message FileHashes { - // Collection of file hashes. - repeated Hash file_hash = 1; -} - -// Container message for hash values. -message Hash { - // Specifies the hash algorithm, if any. - enum HashType { - // No hash requested. - NONE = 0; - - // Use a sha256 hash. - SHA256 = 1; - - // Use a md5 hash. - MD5 = 2; - } - - // The type of hash that was performed. - HashType type = 1; - - // The hash value. - bytes value = 2; -} - -// Secrets and secret environment variables. -message Secrets { - // Secrets in Secret Manager and associated secret environment variable. - repeated SecretManagerSecret secret_manager = 1; - - // Secrets encrypted with KMS key and the associated secret environment - // variable. - repeated InlineSecret inline = 2; -} - -// Pairs a set of secret environment variables mapped to encrypted -// values with the Cloud KMS key to use to decrypt the value. -message InlineSecret { - // Resource name of Cloud KMS crypto key to decrypt the encrypted value. - // In format: projects/*/locations/*/keyRings/*/cryptoKeys/* - string kms_key_name = 1 [(google.api.resource_reference) = { - type: "cloudkms.googleapis.com/CryptoKey" - }]; - - // Map of environment variable name to its encrypted value. - // - // Secret environment variables must be unique across all of a build's - // secrets, and must be used by at least one build step. Values can be at most - // 64 KB in size. There can be at most 100 secret values across all of a - // build's secrets. - map env_map = 2; -} - -// Pairs a secret environment variable with a SecretVersion in Secret Manager. -message SecretManagerSecret { - // Resource name of the SecretVersion. In format: - // projects/*/secrets/*/versions/* - string version_name = 1 [(google.api.resource_reference) = { - type: "secretmanager.googleapis.com/SecretVersion" - }]; - - // Environment variable name to associate with the secret. - // Secret environment variables must be unique across all of a build's - // secrets, and must be used by at least one build step. - string env = 2; -} - -// Pairs a set of secret environment variables containing encrypted -// values with the Cloud KMS key to use to decrypt the value. -// Note: Use `kmsKeyName` with `available_secrets` instead of using -// `kmsKeyName` with `secret`. For instructions see: -// https://cloud.google.com/cloud-build/docs/securing-builds/use-encrypted-credentials. -message Secret { - // Cloud KMS key name to use to decrypt these envs. - string kms_key_name = 1; - - // Map of environment variable name to its encrypted value. - // - // Secret environment variables must be unique across all of a build's - // secrets, and must be used by at least one build step. Values can be at most - // 64 KB in size. There can be at most 100 secret values across all of a - // build's secrets. - map secret_env = 3; -} - -// Request to create a new build. -message CreateBuildRequest { - // The parent resource where this build will be created. - // Format: `projects/{project}/locations/{location}` - string parent = 4 [(google.api.resource_reference) = { - child_type: "cloudbuild.googleapis.com/Build" - }]; - - // Required. ID of the project. - string project_id = 1 [(google.api.field_behavior) = REQUIRED]; - - // Required. Build resource to create. - Build build = 2 [(google.api.field_behavior) = REQUIRED]; -} - -// Request to get a build. -message GetBuildRequest { - // The name of the `Build` to retrieve. - // Format: `projects/{project}/locations/{location}/builds/{build}` - string name = 4 [(google.api.resource_reference) = { - type: "cloudbuild.googleapis.com/Build" - }]; - - // Required. ID of the project. - string project_id = 1 [(google.api.field_behavior) = REQUIRED]; - - // Required. ID of the build. - string id = 2 [(google.api.field_behavior) = REQUIRED]; -} - -// Request to list builds. -message ListBuildsRequest { - // The parent of the collection of `Builds`. - // Format: `projects/{project}/locations/location` - string parent = 9 [(google.api.resource_reference) = { - child_type: "cloudbuild.googleapis.com/Build" - }]; - - // Required. ID of the project. - string project_id = 1 [(google.api.field_behavior) = REQUIRED]; - - // Number of results to return in the list. - int32 page_size = 2; - - // The page token for the next page of Builds. - // - // If unspecified, the first page of results is returned. - // - // If the token is rejected for any reason, INVALID_ARGUMENT will be thrown. - // In this case, the token should be discarded, and pagination should be - // restarted from the first page of results. - // - // See https://google.aip.dev/158 for more. - string page_token = 3; - - // The raw filter text to constrain the results. - string filter = 8; -} - -// Response including listed builds. -message ListBuildsResponse { - // Builds will be sorted by `create_time`, descending. - repeated Build builds = 1; - - // Token to receive the next page of results. - // This will be absent if the end of the response list has been reached. - string next_page_token = 2; -} - -// Request to cancel an ongoing build. -message CancelBuildRequest { - // The name of the `Build` to cancel. - // Format: `projects/{project}/locations/{location}/builds/{build}` - string name = 4 [(google.api.resource_reference) = { - type: "cloudbuild.googleapis.com/Build" - }]; - - // Required. ID of the project. - string project_id = 1 [(google.api.field_behavior) = REQUIRED]; - - // Required. ID of the build. - string id = 2 [(google.api.field_behavior) = REQUIRED]; -} - -// Request to approve or reject a pending build. -message ApproveBuildRequest { - // Required. Name of the target build. - // For example: "projects/{$project_id}/builds/{$build_id}" - string name = 1 [(google.api.field_behavior) = REQUIRED]; - - // Approval decision and metadata. - ApprovalResult approval_result = 2; -} - -// BuildApproval describes a build's approval configuration, state, and -// result. -message BuildApproval { - // Specifies the current state of a build's approval. - enum State { - // Default enum type. This should not be used. - STATE_UNSPECIFIED = 0; - - // Build approval is pending. - PENDING = 1; - - // Build approval has been approved. - APPROVED = 2; - - // Build approval has been rejected. - REJECTED = 3; - - // Build was cancelled while it was still pending approval. - CANCELLED = 5; - } - - // Output only. The state of this build's approval. - State state = 1 [(google.api.field_behavior) = OUTPUT_ONLY]; - - // Output only. Configuration for manual approval of this build. - ApprovalConfig config = 2 [(google.api.field_behavior) = OUTPUT_ONLY]; - - // Output only. Result of manual approval for this Build. - ApprovalResult result = 3 [(google.api.field_behavior) = OUTPUT_ONLY]; -} - -// ApprovalConfig describes configuration for manual approval of a build. -message ApprovalConfig { - // Whether or not approval is needed. If this is set on a build, it will - // become pending when created, and will need to be explicitly approved - // to start. - bool approval_required = 1; -} - -// ApprovalResult describes the decision and associated metadata of a manual -// approval of a build. -message ApprovalResult { - // Specifies whether or not this manual approval result is to approve - // or reject a build. - enum Decision { - // Default enum type. This should not be used. - DECISION_UNSPECIFIED = 0; - - // Build is approved. - APPROVED = 1; - - // Build is rejected. - REJECTED = 2; - } - - // Output only. Email of the user that called the ApproveBuild API to - // approve or reject a build at the time that the API was called. - string approver_account = 2 [(google.api.field_behavior) = OUTPUT_ONLY]; - - // Output only. The time when the approval decision was made. - google.protobuf.Timestamp approval_time = 3 - [(google.api.field_behavior) = OUTPUT_ONLY]; - - // Required. The decision of this manual approval. - Decision decision = 4 [(google.api.field_behavior) = REQUIRED]; - - // Optional. An optional comment for this manual approval result. - string comment = 5 [(google.api.field_behavior) = OPTIONAL]; - - // Optional. An optional URL tied to this manual approval result. This field - // is essentially the same as comment, except that it will be rendered by the - // UI differently. An example use case is a link to an external job that - // approved this Build. - string url = 6 [(google.api.field_behavior) = OPTIONAL]; -} - -// Configuration for an automated build in response to source repository -// changes. -message BuildTrigger { - option (google.api.resource) = { - type: "cloudbuild.googleapis.com/BuildTrigger" - plural: "triggers" - singular: "trigger" - pattern: "projects/{project}/triggers/{trigger}" - pattern: "projects/{project}/locations/{location}/triggers/{trigger}" - }; - - // The `Trigger` name with format: - // `projects/{project}/locations/{location}/triggers/{trigger}`, where - // {trigger} is a unique identifier generated by the service. - string resource_name = 34; - - // Output only. Unique identifier of the trigger. - string id = 1 [(google.api.field_behavior) = OUTPUT_ONLY]; - - // Human-readable description of this trigger. - string description = 10; - - // User-assigned name of the trigger. Must be unique within the project. - // Trigger names must meet the following requirements: - // - // + They must contain only alphanumeric characters and dashes. - // + They can be 1-64 characters long. - // + They must begin and end with an alphanumeric character. - string name = 21; - - // Tags for annotation of a `BuildTrigger` - repeated string tags = 19; - - // Template describing the types of source changes to trigger a build. - // - // Branch and tag names in trigger templates are interpreted as regular - // expressions. Any branch or tag change that matches that regular expression - // will trigger a build. - // - // Mutually exclusive with `github`. - RepoSource trigger_template = 7; - - // GitHubEventsConfig describes the configuration of a trigger that creates - // a build whenever a GitHub event is received. - // - // Mutually exclusive with `trigger_template`. - GitHubEventsConfig github = 13; - - // PubsubConfig describes the configuration of a trigger that - // creates a build whenever a Pub/Sub message is published. - PubsubConfig pubsub_config = 29; - - // WebhookConfig describes the configuration of a trigger that - // creates a build whenever a webhook is sent to a trigger's webhook URL. - WebhookConfig webhook_config = 31; - - // Template describing the Build request to make when the trigger is matched. - oneof build_template { - // Autodetect build configuration. The following precedence is used (case - // insensitive): - // - // 1. cloudbuild.yaml - // 2. cloudbuild.yml - // 3. cloudbuild.json - // 4. Dockerfile - // - // Currently only available for GitHub App Triggers. - bool autodetect = 18; - - // Contents of the build template. - Build build = 4; - - // Path, from the source root, to the build configuration file - // (i.e. cloudbuild.yaml). - string filename = 8; - } - - // Output only. Time when the trigger was created. - google.protobuf.Timestamp create_time = 5 - [(google.api.field_behavior) = OUTPUT_ONLY]; - - // If true, the trigger will never automatically execute a build. - bool disabled = 9; - - // Substitutions for Build resource. The keys must match the following - // regular expression: `^_[A-Z0-9_]+$`. - map substitutions = 11; - - // ignored_files and included_files are file glob matches using - // https://golang.org/pkg/path/filepath/#Match extended with support for "**". - // - // If ignored_files and changed files are both empty, then they are - // not used to determine whether or not to trigger a build. - // - // If ignored_files is not empty, then we ignore any files that match - // any of the ignored_file globs. If the change has no files that are - // outside of the ignored_files globs, then we do not trigger a build. - repeated string ignored_files = 15; - - // If any of the files altered in the commit pass the ignored_files - // filter and included_files is empty, then as far as this filter is - // concerned, we should trigger the build. - // - // If any of the files altered in the commit pass the ignored_files - // filter and included_files is not empty, then we make sure that at - // least one of those files matches a included_files glob. If not, - // then we do not trigger a build. - repeated string included_files = 16; - - // Optional. A Common Expression Language string. - string filter = 30 [(google.api.field_behavior) = OPTIONAL]; - - // The service account used for all user-controlled operations including - // UpdateBuildTrigger, RunBuildTrigger, CreateBuild, and CancelBuild. - // If no service account is set, then the standard Cloud Build service account - // ([PROJECT_NUM]@system.gserviceaccount.com) will be used instead. - // Format: `projects/{PROJECT_ID}/serviceAccounts/{ACCOUNT_ID_OR_EMAIL}` - string service_account = 33 [(google.api.resource_reference) = { - type: "iam.googleapis.com/ServiceAccount" - }]; -} - -// GitHubEventsConfig describes the configuration of a trigger that creates a -// build whenever a GitHub event is received. -// -// This message is experimental. -message GitHubEventsConfig { - // The installationID that emits the GitHub event. - int64 installation_id = 1 [deprecated = true]; - - // Owner of the repository. For example: The owner for - // https://github.com/googlecloudplatform/cloud-builders is - // "googlecloudplatform". - string owner = 6; - - // Name of the repository. For example: The name for - // https://github.com/googlecloudplatform/cloud-builders is "cloud-builders". - string name = 7; - - // Filter describing the types of events to trigger a build. - // Currently supported event types: push, pull_request. - oneof event { - // filter to match changes in pull requests. - PullRequestFilter pull_request = 4; - - // filter to match changes in refs like branches, tags. - PushFilter push = 5; - } -} - -// PubsubConfig describes the configuration of a trigger that -// creates a build whenever a Pub/Sub message is published. -message PubsubConfig { - // Enumerates potential issues with the underlying Pub/Sub subscription - // configuration. - enum State { - // The subscription configuration has not been checked. - STATE_UNSPECIFIED = 0; - - // The Pub/Sub subscription is properly configured. - OK = 1; - - // The subscription has been deleted. - SUBSCRIPTION_DELETED = 2; - - // The topic has been deleted. - TOPIC_DELETED = 3; - - // Some of the subscription's field are misconfigured. - SUBSCRIPTION_MISCONFIGURED = 4; - } - - // Output only. Name of the subscription. Format is - // `projects/{project}/subscriptions/{subscription}`. - string subscription = 1 [ - (google.api.field_behavior) = OUTPUT_ONLY, - (google.api.resource_reference) = { - type: "pubsub.googleapis.com/Subscription" - } - ]; - - // The name of the topic from which this subscription is receiving messages. - // Format is `projects/{project}/topics/{topic}`. - string topic = 2 [ - (google.api.resource_reference) = { type: "pubsub.googleapis.com/Topic" } - ]; - - // Service account that will make the push request. - string service_account_email = 3 [(google.api.resource_reference) = { - type: "iam.googleapis.com/ServiceAccount" - }]; - - // Potential issues with the underlying Pub/Sub subscription configuration. - // Only populated on get requests. - State state = 4; -} - -// WebhookConfig describes the configuration of a trigger that -// creates a build whenever a webhook is sent to a trigger's webhook URL. -message WebhookConfig { - // Enumerates potential issues with the Secret Manager secret provided by the - // user. - enum State { - // The webhook auth configuration not been checked. - STATE_UNSPECIFIED = 0; - - // The auth configuration is properly setup. - OK = 1; - - // The secret provided in auth_method has been deleted. - SECRET_DELETED = 2; - } - - // Auth method specifies how the webhook authenticates with GCP. - oneof auth_method { - // Required. Resource name for the secret required as a URL parameter. - string secret = 3 [ - (google.api.field_behavior) = REQUIRED, - (google.api.resource_reference) = { - type: "secretmanager.googleapis.com/SecretVersion" - } - ]; - } - - // Potential issues with the underlying Pub/Sub subscription configuration. - // Only populated on get requests. - State state = 4; -} - -// PullRequestFilter contains filter properties for matching GitHub Pull -// Requests. -message PullRequestFilter { - // Controls behavior of Pull Request comments. - enum CommentControl { - // Do not require comments on Pull Requests before builds are triggered. - COMMENTS_DISABLED = 0; - - // Enforce that repository owners or collaborators must comment on Pull - // Requests before builds are triggered. - COMMENTS_ENABLED = 1; - - // Enforce that repository owners or collaborators must comment on external - // contributors' Pull Requests before builds are triggered. - COMMENTS_ENABLED_FOR_EXTERNAL_CONTRIBUTORS_ONLY = 2; - } - - // Target refs to match. - // A target ref is the git reference where the pull request will be applied. - oneof git_ref { - // Regex of branches to match. - // - // The syntax of the regular expressions accepted is the syntax accepted by - // RE2 and described at https://github.com/google/re2/wiki/Syntax - string branch = 2; - } - - // Configure builds to run whether a repository owner or collaborator need to - // comment `/gcbrun`. - CommentControl comment_control = 5; - - // If true, branches that do NOT match the git_ref will trigger a build. - bool invert_regex = 6; -} - -// Push contains filter properties for matching GitHub git pushes. -message PushFilter { - // Modified refs to match. - // A modified refs are the refs modified by a git push operation. - oneof git_ref { - // Regexes matching branches to build. - // - // The syntax of the regular expressions accepted is the syntax accepted by - // RE2 and described at https://github.com/google/re2/wiki/Syntax - string branch = 2; - - // Regexes matching tags to build. - // - // The syntax of the regular expressions accepted is the syntax accepted by - // RE2 and described at https://github.com/google/re2/wiki/Syntax - string tag = 3; - } - - // When true, only trigger a build if the revision regex does NOT match the - // git_ref regex. - bool invert_regex = 4; -} - -// Request to create a new `BuildTrigger`. -message CreateBuildTriggerRequest { - // The parent resource where this trigger will be created. - // Format: `projects/{project}/locations/{location}` - string parent = 3 [(google.api.resource_reference) = { - child_type: "cloudbuild.googleapis.com/BuildTrigger" - }]; - - // Required. ID of the project for which to configure automatic builds. - string project_id = 1 [(google.api.field_behavior) = REQUIRED]; - - // Required. `BuildTrigger` to create. - BuildTrigger trigger = 2 [(google.api.field_behavior) = REQUIRED]; -} - -// Returns the `BuildTrigger` with the specified ID. -message GetBuildTriggerRequest { - // The name of the `Trigger` to retrieve. - // Format: `projects/{project}/locations/{location}/triggers/{trigger}` - string name = 3 [(google.api.resource_reference) = { - type: "cloudbuild.googleapis.com/BuildTrigger" - }]; - - // Required. ID of the project that owns the trigger. - string project_id = 1 [(google.api.field_behavior) = REQUIRED]; - - // Required. Identifier (`id` or `name`) of the `BuildTrigger` to get. - string trigger_id = 2 [(google.api.field_behavior) = REQUIRED]; -} - -// Request to list existing `BuildTriggers`. -message ListBuildTriggersRequest { - // The parent of the collection of `Triggers`. - // Format: `projects/{project}/locations/{location}` - string parent = 4 [(google.api.resource_reference) = { - child_type: "cloudbuild.googleapis.com/BuildTrigger" - }]; - - // Required. ID of the project for which to list BuildTriggers. - string project_id = 1 [(google.api.field_behavior) = REQUIRED]; - - // Number of results to return in the list. - int32 page_size = 2; - - // Token to provide to skip to a particular spot in the list. - string page_token = 3; -} - -// Response containing existing `BuildTriggers`. -message ListBuildTriggersResponse { - // `BuildTriggers` for the project, sorted by `create_time` descending. - repeated BuildTrigger triggers = 1; - - // Token to receive the next page of results. - string next_page_token = 2; -} - -// Request to delete a `BuildTrigger`. -message DeleteBuildTriggerRequest { - // The name of the `Trigger` to delete. - // Format: `projects/{project}/locations/{location}/triggers/{trigger}` - string name = 3 [(google.api.resource_reference) = { - type: "cloudbuild.googleapis.com/BuildTrigger" - }]; - - // Required. ID of the project that owns the trigger. - string project_id = 1 [(google.api.field_behavior) = REQUIRED]; - - // Required. ID of the `BuildTrigger` to delete. - string trigger_id = 2 [(google.api.field_behavior) = REQUIRED]; -} - -// Request to update an existing `BuildTrigger`. -message UpdateBuildTriggerRequest { - // Required. ID of the project that owns the trigger. - string project_id = 1 [(google.api.field_behavior) = REQUIRED]; - - // Required. ID of the `BuildTrigger` to update. - string trigger_id = 2 [(google.api.field_behavior) = REQUIRED]; - - // Required. `BuildTrigger` to update. - BuildTrigger trigger = 3 [(google.api.field_behavior) = REQUIRED]; -} - -// Optional arguments to enable specific features of builds. -message BuildOptions { - // Details about how a build should be executed on a `WorkerPool`. - // - // See [running builds in a private - // pool](https://cloud.google.com/build/docs/private-pools/run-builds-in-private-pool) - // for more information. - message PoolOption { - // The `WorkerPool` resource to execute the build on. - // You must have `cloudbuild.workerpools.use` on the project hosting the - // WorkerPool. - // - // Format projects/{project}/locations/{location}/workerPools/{workerPoolId} - string name = 1 [(google.api.resource_reference) = { - type: "cloudbuild.googleapis.com/WorkerPool" - }]; - } - - // Specifies the manner in which the build should be verified, if at all. - enum VerifyOption { - // Not a verifiable build. (default) - NOT_VERIFIED = 0; - - // Verified build. - VERIFIED = 1; - } - - // Supported Compute Engine machine types. - // For more information, see [Machine - // types](https://cloud.google.com/compute/docs/machine-types). - enum MachineType { - // Standard machine type. - UNSPECIFIED = 0; - - // Highcpu machine with 8 CPUs. - N1_HIGHCPU_8 = 1; - - // Highcpu machine with 32 CPUs. - N1_HIGHCPU_32 = 2; - - // Highcpu e2 machine with 8 CPUs. - E2_HIGHCPU_8 = 5; - - // Highcpu e2 machine with 32 CPUs. - E2_HIGHCPU_32 = 6; - } - - // Specifies the behavior when there is an error in the substitution checks. - enum SubstitutionOption { - // Fails the build if error in substitutions checks, like missing - // a substitution in the template or in the map. - MUST_MATCH = 0; - - // Do not fail the build if error in substitutions checks. - ALLOW_LOOSE = 1; - } - - // Specifies the behavior when writing build logs to Google Cloud Storage. - enum LogStreamingOption { - // Service may automatically determine build log streaming behavior. - STREAM_DEFAULT = 0; - - // Build logs should be streamed to Google Cloud Storage. - STREAM_ON = 1; - - // Build logs should not be streamed to Google Cloud Storage; they will be - // written when the build is completed. - STREAM_OFF = 2; - } - - // Specifies the logging mode. - enum LoggingMode { - // The service determines the logging mode. The default is `LEGACY`. Do not - // rely on the default logging behavior as it may change in the future. - LOGGING_UNSPECIFIED = 0; - - // Cloud Logging and Cloud Storage logging are enabled. - LEGACY = 1; - - // Only Cloud Storage logging is enabled. - GCS_ONLY = 2; - - // This option is the same as CLOUD_LOGGING_ONLY. - STACKDRIVER_ONLY = 3 [deprecated = true]; - - // Only Cloud Logging is enabled. Note that logs for both the Cloud Console - // UI and Cloud SDK are based on Cloud Storage logs, so neither will provide - // logs if this option is chosen. - CLOUD_LOGGING_ONLY = 5; - - // Turn off all logging. No build logs will be captured. - NONE = 4; - } - - // Requested hash for SourceProvenance. - repeated Hash.HashType source_provenance_hash = 1; - - // Requested verifiability options. - VerifyOption requested_verify_option = 2; - - // Compute Engine machine type on which to run the build. - MachineType machine_type = 3; - - // Requested disk size for the VM that runs the build. Note that this is *NOT* - // "disk free"; some of the space will be used by the operating system and - // build utilities. Also note that this is the minimum disk size that will be - // allocated for the build -- the build may run with a larger disk than - // requested. At present, the maximum disk size is 1000GB; builds that request - // more than the maximum are rejected with an error. - int64 disk_size_gb = 6; - - // Option to specify behavior when there is an error in the substitution - // checks. - // - // NOTE: this is always set to ALLOW_LOOSE for triggered builds and cannot - // be overridden in the build configuration file. - SubstitutionOption substitution_option = 4; - - // Option to specify whether or not to apply bash style string - // operations to the substitutions. - // - // NOTE: this is always enabled for triggered builds and cannot be - // overridden in the build configuration file. - bool dynamic_substitutions = 17; - - // Option to define build log streaming behavior to Google Cloud - // Storage. - LogStreamingOption log_streaming_option = 5; - - // This field deprecated; please use `pool.name` instead. - string worker_pool = 7 [deprecated = true]; - - // Optional. Specification for execution on a `WorkerPool`. - // - // See [running builds in a private - // pool](https://cloud.google.com/build/docs/private-pools/run-builds-in-private-pool) - // for more information. - PoolOption pool = 19 [(google.api.field_behavior) = OPTIONAL]; - - // Option to specify the logging mode, which determines if and where build - // logs are stored. - LoggingMode logging = 11; - - // A list of global environment variable definitions that will exist for all - // build steps in this build. If a variable is defined in both globally and in - // a build step, the variable will use the build step value. - // - // The elements are of the form "KEY=VALUE" for the environment variable "KEY" - // being given the value "VALUE". - repeated string env = 12; - - // A list of global environment variables, which are encrypted using a Cloud - // Key Management Service crypto key. These values must be specified in the - // build's `Secret`. These variables will be available to all build steps - // in this build. - repeated string secret_env = 13; - - // Global list of volumes to mount for ALL build steps - // - // Each volume is created as an empty volume prior to starting the build - // process. Upon completion of the build, volumes and their contents are - // discarded. Global volume names and paths cannot conflict with the volumes - // defined a build step. - // - // Using a global volume in a build with only one step is not valid as - // it is indicative of a build request with an incorrect configuration. - repeated Volume volumes = 14; -} - -// ReceiveTriggerWebhookRequest [Experimental] is the request object accepted by -// the ReceiveTriggerWebhook method. -message ReceiveTriggerWebhookRequest { - // The name of the `ReceiveTriggerWebhook` to retrieve. - // Format: `projects/{project}/locations/{location}/triggers/{trigger}` - string name = 5; - - // HTTP request body. - google.api.HttpBody body = 1; - - // Project in which the specified trigger lives - string project_id = 2; - - // Name of the trigger to run the payload against - string trigger = 3; - - // Secret token used for authorization if an OAuth token isn't provided. - string secret = 4; -} - -// ReceiveTriggerWebhookResponse [Experimental] is the response object for the -// ReceiveTriggerWebhook method. -message ReceiveTriggerWebhookResponse {} - -// Configuration for a `WorkerPool`. -// -// Cloud Build owns and maintains a pool of workers for general use and have no -// access to a project's private network. By default, builds submitted to -// Cloud Build will use a worker from this pool. -// -// If your build needs access to resources on a private network, -// create and use a `WorkerPool` to run your builds. Private `WorkerPool`s give -// your builds access to any single VPC network that you -// administer, including any on-prem resources connected to that VPC -// network. For an overview of private pools, see -// [Private pools -// overview](https://cloud.google.com/build/docs/private-pools/private-pools-overview). -message WorkerPool { - option (google.api.resource) = { - type: "cloudbuild.googleapis.com/WorkerPool" - pattern: "projects/{project}/locations/{location}/workerPools/{worker_pool}" - plural: "workerPools" - singular: "workerPool" - style: DECLARATIVE_FRIENDLY - }; - - // State of the `WorkerPool`. - enum State { - // State of the `WorkerPool` is unknown. - STATE_UNSPECIFIED = 0; - - // `WorkerPool` is being created. - CREATING = 1; - - // `WorkerPool` is running. - RUNNING = 2; - - // `WorkerPool` is being deleted: cancelling builds and draining workers. - DELETING = 3; - - // `WorkerPool` is deleted. - DELETED = 4; - } - - // Output only. The resource name of the `WorkerPool`, with format - // `projects/{project}/locations/{location}/workerPools/{worker_pool}`. - // The value of `{worker_pool}` is provided by `worker_pool_id` in - // `CreateWorkerPool` request and the value of `{location}` is determined by - // the endpoint accessed. - string name = 1 [(google.api.field_behavior) = OUTPUT_ONLY]; - - // A user-specified, human-readable name for the `WorkerPool`. If provided, - // this value must be 1-63 characters. - string display_name = 2; - - // Output only. A unique identifier for the `WorkerPool`. - string uid = 3 [(google.api.field_behavior) = OUTPUT_ONLY]; - - // User specified annotations. See https://google.aip.dev/128#annotations - // for more details such as format and size limitations. - map annotations = 4; - - // Output only. Time at which the request to create the `WorkerPool` was - // received. - google.protobuf.Timestamp create_time = 5 - [(google.api.field_behavior) = OUTPUT_ONLY]; - - // Output only. Time at which the request to update the `WorkerPool` was - // received. - google.protobuf.Timestamp update_time = 6 - [(google.api.field_behavior) = OUTPUT_ONLY]; - - // Output only. Time at which the request to delete the `WorkerPool` was - // received. - google.protobuf.Timestamp delete_time = 7 - [(google.api.field_behavior) = OUTPUT_ONLY]; - - // Output only. `WorkerPool` state. - State state = 8 [(google.api.field_behavior) = OUTPUT_ONLY]; - - // Private Pool configuration for the `WorkerPool`. - oneof config { - // Private Pool using a v1 configuration. - PrivatePoolV1Config private_pool_v1_config = 12; - } - - // Output only. Checksum computed by the server. May be sent on update and - // delete requests to ensure that the client has an up-to-date value before - // proceeding. - string etag = 11 [(google.api.field_behavior) = OUTPUT_ONLY]; -} - -// Configuration for a V1 `PrivatePool`. -message PrivatePoolV1Config { - // Defines the configuration to be used for creating workers in - // the pool. - message WorkerConfig { - // Machine type of a worker, such as `e2-medium`. - // See [Worker pool config - // file](https://cloud.google.com/build/docs/private-pools/worker-pool-config-file-schema). - // If left blank, Cloud Build will use a sensible default. - string machine_type = 1; - - // Size of the disk attached to the worker, in GB. - // See [Worker pool config - // file](https://cloud.google.com/build/docs/private-pools/worker-pool-config-file-schema). - // Specify a value of up to 1000. If `0` is specified, Cloud Build will use - // a standard disk size. - int64 disk_size_gb = 2; - } - - // Defines the network configuration for the pool. - message NetworkConfig { - // Defines the egress option for the pool. - enum EgressOption { - // If set, defaults to PUBLIC_EGRESS. - EGRESS_OPTION_UNSPECIFIED = 0; - - // If set, workers are created without any public address, which prevents - // network egress to public IPs unless a network proxy is configured. - NO_PUBLIC_EGRESS = 1; - - // If set, workers are created with a public address which allows for - // public internet egress. - PUBLIC_EGRESS = 2; - } - - // Required. Immutable. The network definition that the workers are peered - // to. If this section is left empty, the workers will be peered to - // `WorkerPool.project_id` on the service producer network. Must be in the - // format `projects/{project}/global/networks/{network}`, where `{project}` - // is a project number, such as `12345`, and `{network}` is the name of a - // VPC network in the project. See - // [Understanding network configuration - // options](https://cloud.google.com/build/docs/private-pools/set-up-private-pool-environment) - string peered_network = 1 [ - (google.api.field_behavior) = IMMUTABLE, - (google.api.field_behavior) = REQUIRED, - (google.api.resource_reference) = { - type: "compute.googleapis.com/Network" - } - ]; - - // Option to configure network egress for the workers. - EgressOption egress_option = 2; - } - - // Machine configuration for the workers in the pool. - WorkerConfig worker_config = 1; - - // Network configuration for the pool. - NetworkConfig network_config = 2; -} - -// Request to create a new `WorkerPool`. -message CreateWorkerPoolRequest { - // Required. The parent resource where this worker pool will be created. - // Format: `projects/{project}/locations/{location}`. - string parent = 1 [ - (google.api.field_behavior) = REQUIRED, - (google.api.resource_reference) = { - type: "locations.googleapis.com/Location" - } - ]; - - // Required. `WorkerPool` resource to create. - WorkerPool worker_pool = 2 [(google.api.field_behavior) = REQUIRED]; - - // Required. Immutable. The ID to use for the `WorkerPool`, which will become - // the final component of the resource name. - // - // This value should be 1-63 characters, and valid characters - // are /[a-z][0-9]-/. - string worker_pool_id = 3 [ - (google.api.field_behavior) = IMMUTABLE, - (google.api.field_behavior) = REQUIRED - ]; - - // If set, validate the request and preview the response, but do not actually - // post it. - bool validate_only = 4; -} - -// Request to get a `WorkerPool` with the specified name. -message GetWorkerPoolRequest { - // Required. The name of the `WorkerPool` to retrieve. - // Format: `projects/{project}/locations/{location}/workerPools/{workerPool}`. - string name = 1 [ - (google.api.field_behavior) = REQUIRED, - (google.api.resource_reference) = { - type: "cloudbuild.googleapis.com/WorkerPool" - } - ]; -} - -// Request to delete a `WorkerPool`. -message DeleteWorkerPoolRequest { - // Required. The name of the `WorkerPool` to delete. - // Format: - // `projects/{project}/locations/{workerPool}/workerPools/{workerPool}`. - string name = 1 [ - (google.api.field_behavior) = REQUIRED, - (google.api.resource_reference) = { - type: "cloudbuild.googleapis.com/WorkerPool" - } - ]; - - // Optional. If this is provided, it must match the server's etag on the - // workerpool for the request to be processed. - string etag = 2; - - // If set to true, and the `WorkerPool` is not found, the request will succeed - // but no action will be taken on the server. - bool allow_missing = 3; - - // If set, validate the request and preview the response, but do not actually - // post it. - bool validate_only = 4; -} - -// Request to update a `WorkerPool`. -message UpdateWorkerPoolRequest { - // Required. The `WorkerPool` to update. - // - // The `name` field is used to identify the `WorkerPool` to update. - // Format: `projects/{project}/locations/{location}/workerPools/{workerPool}`. - WorkerPool worker_pool = 1 [(google.api.field_behavior) = REQUIRED]; - - // A mask specifying which fields in `worker_pool` to update. - google.protobuf.FieldMask update_mask = 2; - - // If set, validate the request and preview the response, but do not actually - // post it. - bool validate_only = 4; -} - -// Request to list `WorkerPool`s. -message ListWorkerPoolsRequest { - // Required. The parent of the collection of `WorkerPools`. - // Format: `projects/{project}/locations/{location}`. - string parent = 1 [ - (google.api.field_behavior) = REQUIRED, - (google.api.resource_reference) = { - type: "locations.googleapis.com/Location" - } - ]; - - // The maximum number of `WorkerPool`s to return. The service may return - // fewer than this value. If omitted, the server will use a sensible default. - int32 page_size = 2; - - // A page token, received from a previous `ListWorkerPools` call. Provide this - // to retrieve the subsequent page. - string page_token = 3; -} - -// Response containing existing `WorkerPools`. -message ListWorkerPoolsResponse { - // `WorkerPools` for the specified project. - repeated WorkerPool worker_pools = 1; - - // Continuation token used to page through large result sets. Provide this - // value in a subsequent ListWorkerPoolsRequest to return the next page of - // results. - string next_page_token = 2; -} - -// Metadata for the `CreateWorkerPool` operation. -message CreateWorkerPoolOperationMetadata { - // The resource name of the `WorkerPool` to create. - // Format: - // `projects/{project}/locations/{location}/workerPools/{worker_pool}`. - string worker_pool = 1 [(google.api.resource_reference) = { - type: "cloudbuild.googleapis.com/WorkerPool" - }]; - - // Time the operation was created. - google.protobuf.Timestamp create_time = 2; - - // Time the operation was completed. - google.protobuf.Timestamp complete_time = 3; -} - -// Metadata for the `UpdateWorkerPool` operation. -message UpdateWorkerPoolOperationMetadata { - // The resource name of the `WorkerPool` being updated. - // Format: - // `projects/{project}/locations/{location}/workerPools/{worker_pool}`. - string worker_pool = 1 [(google.api.resource_reference) = { - type: "cloudbuild.googleapis.com/WorkerPool" - }]; - - // Time the operation was created. - google.protobuf.Timestamp create_time = 2; - - // Time the operation was completed. - google.protobuf.Timestamp complete_time = 3; -} - -// Metadata for the `DeleteWorkerPool` operation. -message DeleteWorkerPoolOperationMetadata { - // The resource name of the `WorkerPool` being deleted. - // Format: - // `projects/{project}/locations/{location}/workerPools/{worker_pool}`. - string worker_pool = 1 [(google.api.resource_reference) = { - type: "cloudbuild.googleapis.com/WorkerPool" - }]; - - // Time the operation was created. - google.protobuf.Timestamp create_time = 2; - - // Time the operation was completed. - google.protobuf.Timestamp complete_time = 3; -} diff --git a/renovate.json b/renovate.json deleted file mode 100644 index 4870face..00000000 --- a/renovate.json +++ /dev/null @@ -1,76 +0,0 @@ -{ - "enabled": false, - "extends": [ - ":separateMajorReleases", - ":combinePatchMinorReleases", - ":ignoreUnstable", - ":prImmediately", - ":updateNotScheduled", - ":automergeDisabled", - ":ignoreModulesAndTests", - ":maintainLockFilesDisabled", - ":autodetectPinVersions" - ], - "ignorePaths": [".kokoro/requirements.txt"], - "packageRules": [ - { - "packagePatterns": [ - "^com.google.guava:" - ], - "versionScheme": "docker" - }, - { - "packagePatterns": [ - "*" - ], - "semanticCommitType": "deps", - "semanticCommitScope": null - }, - { - "packagePatterns": [ - "^org.apache.maven", - "^org.jacoco:", - "^org.codehaus.mojo:", - "^org.sonatype.plugins:", - "^com.coveo:", - "^com.google.cloud:google-cloud-shared-config" - ], - "semanticCommitType": "build", - "semanticCommitScope": "deps" - }, - { - "packagePatterns": [ - "^com.google.cloud:google-cloud-build", - "^com.google.cloud:libraries-bom", - "^com.google.cloud.samples:shared-configuration" - ], - "semanticCommitType": "chore", - "semanticCommitScope": "deps" - }, - { - "packagePatterns": [ - "^junit:junit", - "^com.google.truth:truth", - "^org.mockito:mockito-core", - "^org.objenesis:objenesis", - "^com.google.cloud:google-cloud-conformance-tests" - ], - "semanticCommitType": "test", - "semanticCommitScope": "deps" - }, - { - "packagePatterns": [ - "^com.google.cloud:google-cloud-" - ], - "ignoreUnstable": false - }, - { - "packagePatterns": [ - "^com.fasterxml.jackson.core" - ], - "groupName": "jackson dependencies" - } - ], - "semanticCommits": true, - "dependencyDashboard": true -} diff --git a/samples/install-without-bom/pom.xml b/samples/install-without-bom/pom.xml deleted file mode 100644 index a92099c8..00000000 --- a/samples/install-without-bom/pom.xml +++ /dev/null @@ -1,84 +0,0 @@ - - - 4.0.0 - com.google.cloud - build-install-without-bom - jar - Google Cloud Build Install Without Bom - https://github.com/googleapis/java-cloudbuild - - - - com.google.cloud.samples - shared-configuration - 1.2.0 - - - - 1.8 - 1.8 - UTF-8 - - - - - - - com.google.cloud - google-cloud-build - 3.5.6 - - - - - junit - junit - 4.13.2 - test - - - com.google.truth - truth - 1.1.3 - test - - - - - - - - org.codehaus.mojo - build-helper-maven-plugin - 3.3.0 - - - add-snippets-source - - add-source - - - - ../snippets/src/main/java - - - - - add-snippets-tests - - add-test-source - - - - ../snippets/src/test/java - - - - - - - - diff --git a/samples/pom.xml b/samples/pom.xml deleted file mode 100644 index 52108f0f..00000000 --- a/samples/pom.xml +++ /dev/null @@ -1,56 +0,0 @@ - - - 4.0.0 - com.google.cloud - google-cloud-build-samples - 0.0.1-SNAPSHOT - pom - Google Cloud Build Samples Parent - https://github.com/googleapis/java-cloudbuild - - Java idiomatic client for Google Cloud Platform services. - - - - - com.google.cloud.samples - shared-configuration - 1.2.0 - - - - 1.8 - 1.8 - UTF-8 - - - - install-without-bom - snapshot - snippets - - - - - - org.apache.maven.plugins - maven-deploy-plugin - 3.0.0 - - true - - - - org.sonatype.plugins - nexus-staging-maven-plugin - 1.6.13 - - true - - - - - diff --git a/samples/snapshot/pom.xml b/samples/snapshot/pom.xml deleted file mode 100644 index 4b558282..00000000 --- a/samples/snapshot/pom.xml +++ /dev/null @@ -1,83 +0,0 @@ - - - 4.0.0 - com.google.cloud - build-snapshot - jar - Google Cloud Build Snapshot Samples - https://github.com/googleapis/java-cloudbuild - - - - com.google.cloud.samples - shared-configuration - 1.2.0 - - - - 1.8 - 1.8 - UTF-8 - - - - - - com.google.cloud - google-cloud-build - 3.5.6 - - - - junit - junit - 4.13.2 - test - - - com.google.truth - truth - 1.1.3 - test - - - - - - - - - org.codehaus.mojo - build-helper-maven-plugin - 3.3.0 - - - add-snippets-source - - add-source - - - - ../snippets/src/main/java - - - - - add-snippets-tests - - add-test-source - - - - ../snippets/src/test/java - - - - - - - - \ No newline at end of file diff --git a/samples/snippets/pom.xml b/samples/snippets/pom.xml deleted file mode 100644 index 1085e997..00000000 --- a/samples/snippets/pom.xml +++ /dev/null @@ -1,60 +0,0 @@ - - - 4.0.0 - com.google.cloud - build-snippets - jar - Google Cloud Build Snippets - https://github.com/googleapis/java-cloudbuild - - - - com.google.cloud.samples - shared-configuration - 1.2.0 - - - - 1.8 - 1.8 - UTF-8 - - - - - - - - com.google.cloud - libraries-bom - 26.1.3 - pom - import - - - - - - - com.google.cloud - google-cloud-build - - - - - junit - junit - 4.13.2 - test - - - com.google.truth - truth - 1.1.3 - test - - - diff --git a/synth.metadata b/synth.metadata deleted file mode 100644 index 7111fb5c..00000000 --- a/synth.metadata +++ /dev/null @@ -1,243 +0,0 @@ -{ - "sources": [ - { - "generator": { - "name": "artman", - "version": "2.4.4", - "dockerImage": "googleapis/artman@sha256:0da97ae2ac274adc8ee147fd1eb6736f8186d1684b0f58bce91f4295797a5dcd" - } - }, - { - "git": { - "name": ".", - "remote": "https://github.com/googleapis/java-cloudbuild.git", - "sha": "1a7559c226e87cadac0117f1681901e04750b6ed" - } - }, - { - "git": { - "name": "googleapis", - "remote": "https://github.com/googleapis/googleapis.git", - "sha": "08c4eeb531c01ad031134dca94b18e3f7dd35902", - "internalRef": "378718217" - } - }, - { - "git": { - "name": "synthtool", - "remote": "https://github.com/googleapis/synthtool.git", - "sha": "8eae0234a16b26c2ff616d305dbd9786c8b10a47" - } - } - ], - "destinations": [ - { - "client": { - "source": "googleapis", - "apiName": "devtools-cloudbuild", - "apiVersion": "v1", - "language": "java", - "generator": "bazel" - } - } - ], - "generatedFiles": [ - ".github/CODEOWNERS", - ".github/ISSUE_TEMPLATE/bug_report.md", - ".github/ISSUE_TEMPLATE/feature_request.md", - ".github/ISSUE_TEMPLATE/support_request.md", - ".github/PULL_REQUEST_TEMPLATE.md", - ".github/blunderbuss.yml", - ".github/generated-files-bot.yml", - ".github/readme/synth.py", - ".github/release-please.yml", - ".github/snippet-bot.yml", - ".github/sync-repo-settings.yaml", - ".github/trusted-contribution.yml", - ".github/workflows/approve-readme.yaml", - ".github/workflows/auto-release.yaml", - ".github/workflows/ci.yaml", - ".github/workflows/samples.yaml", - ".kokoro/build.bat", - ".kokoro/build.sh", - ".kokoro/coerce_logs.sh", - ".kokoro/common.cfg", - ".kokoro/common.sh", - ".kokoro/continuous/common.cfg", - ".kokoro/continuous/java8.cfg", - ".kokoro/continuous/readme.cfg", - ".kokoro/dependencies.sh", - ".kokoro/nightly/common.cfg", - ".kokoro/nightly/integration.cfg", - ".kokoro/nightly/java11.cfg", - ".kokoro/nightly/java7.cfg", - ".kokoro/nightly/java8-osx.cfg", - ".kokoro/nightly/java8-win.cfg", - ".kokoro/nightly/java8.cfg", - ".kokoro/nightly/samples.cfg", - ".kokoro/populate-secrets.sh", - ".kokoro/presubmit/clirr.cfg", - ".kokoro/presubmit/common.cfg", - ".kokoro/presubmit/dependencies.cfg", - ".kokoro/presubmit/integration.cfg", - ".kokoro/presubmit/java11.cfg", - ".kokoro/presubmit/java7.cfg", - ".kokoro/presubmit/java8-osx.cfg", - ".kokoro/presubmit/java8-win.cfg", - ".kokoro/presubmit/java8.cfg", - ".kokoro/presubmit/linkage-monitor.cfg", - ".kokoro/presubmit/lint.cfg", - ".kokoro/presubmit/samples.cfg", - ".kokoro/readme.sh", - ".kokoro/release/bump_snapshot.cfg", - ".kokoro/release/common.cfg", - ".kokoro/release/common.sh", - ".kokoro/release/drop.cfg", - ".kokoro/release/drop.sh", - ".kokoro/release/promote.cfg", - ".kokoro/release/promote.sh", - ".kokoro/release/publish_javadoc.cfg", - ".kokoro/release/publish_javadoc.sh", - ".kokoro/release/publish_javadoc11.cfg", - ".kokoro/release/publish_javadoc11.sh", - ".kokoro/release/snapshot.cfg", - ".kokoro/release/snapshot.sh", - ".kokoro/release/stage.cfg", - ".kokoro/release/stage.sh", - ".kokoro/trampoline.sh", - "CODE_OF_CONDUCT.md", - "CONTRIBUTING.md", - "LICENSE", - "codecov.yaml", - "google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/CloudBuildClient.java", - "google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/CloudBuildSettings.java", - "google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/gapic_metadata.json", - "google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/package-info.java", - "google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/stub/CloudBuildStub.java", - "google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/stub/CloudBuildStubSettings.java", - "google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/stub/GrpcCloudBuildCallableFactory.java", - "google-cloud-build/src/main/java/com/google/cloud/devtools/cloudbuild/v1/stub/GrpcCloudBuildStub.java", - "google-cloud-build/src/test/java/com/google/cloud/devtools/cloudbuild/v1/CloudBuildClientTest.java", - "google-cloud-build/src/test/java/com/google/cloud/devtools/cloudbuild/v1/MockCloudBuild.java", - "google-cloud-build/src/test/java/com/google/cloud/devtools/cloudbuild/v1/MockCloudBuildImpl.java", - "grpc-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CloudBuildGrpc.java", - "java.header", - "license-checks.xml", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ArtifactResult.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ArtifactResultOrBuilder.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Artifacts.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ArtifactsOrBuilder.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Build.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildName.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildOperationMetadata.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildOperationMetadataOrBuilder.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildOptions.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildOptionsOrBuilder.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildOrBuilder.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildStep.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildStepOrBuilder.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildTrigger.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildTriggerName.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuildTriggerOrBuilder.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuiltImage.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/BuiltImageOrBuilder.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CancelBuildRequest.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CancelBuildRequestOrBuilder.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Cloudbuild.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CreateBuildRequest.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CreateBuildRequestOrBuilder.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CreateBuildTriggerRequest.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CreateBuildTriggerRequestOrBuilder.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CreateWorkerPoolRequest.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CreateWorkerPoolRequestOrBuilder.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/CryptoKeyName.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/DeleteBuildTriggerRequest.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/DeleteBuildTriggerRequestOrBuilder.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/DeleteWorkerPoolRequest.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/DeleteWorkerPoolRequestOrBuilder.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/FileHashes.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/FileHashesOrBuilder.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GetBuildRequest.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GetBuildRequestOrBuilder.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GetBuildTriggerRequest.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GetBuildTriggerRequestOrBuilder.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GetWorkerPoolRequest.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GetWorkerPoolRequestOrBuilder.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GitHubEventsConfig.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/GitHubEventsConfigOrBuilder.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Hash.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/HashOrBuilder.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/InlineSecret.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/InlineSecretOrBuilder.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildTriggersRequest.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildTriggersRequestOrBuilder.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildTriggersResponse.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildTriggersResponseOrBuilder.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildsRequest.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildsRequestOrBuilder.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildsResponse.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListBuildsResponseOrBuilder.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListWorkerPoolsRequest.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListWorkerPoolsRequestOrBuilder.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListWorkerPoolsResponse.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ListWorkerPoolsResponseOrBuilder.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/LocationName.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Network.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/NetworkOrBuilder.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ProjectName.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/PubsubConfig.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/PubsubConfigOrBuilder.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/PullRequestFilter.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/PullRequestFilterOrBuilder.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/PushFilter.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/PushFilterOrBuilder.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ReceiveTriggerWebhookRequest.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ReceiveTriggerWebhookRequestOrBuilder.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ReceiveTriggerWebhookResponse.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ReceiveTriggerWebhookResponseOrBuilder.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/RepoSource.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/RepoSourceOrBuilder.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Results.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ResultsOrBuilder.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/RetryBuildRequest.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/RetryBuildRequestOrBuilder.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/RunBuildTriggerRequest.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/RunBuildTriggerRequestOrBuilder.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Secret.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/SecretManagerSecret.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/SecretManagerSecretOrBuilder.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/SecretOrBuilder.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/SecretVersionName.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Secrets.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/SecretsOrBuilder.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/ServiceAccountName.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Source.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/SourceOrBuilder.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/SourceProvenance.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/SourceProvenanceOrBuilder.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/StorageSource.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/StorageSourceManifest.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/StorageSourceManifestOrBuilder.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/StorageSourceOrBuilder.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/SubscriptionName.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/TimeSpan.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/TimeSpanOrBuilder.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/TopicName.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/UpdateBuildTriggerRequest.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/UpdateBuildTriggerRequestOrBuilder.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/UpdateWorkerPoolRequest.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/UpdateWorkerPoolRequestOrBuilder.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/Volume.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/VolumeOrBuilder.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/WorkerConfig.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/WorkerConfigOrBuilder.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/WorkerPool.java", - "proto-google-cloud-build-v1/src/main/java/com/google/cloudbuild/v1/WorkerPoolOrBuilder.java", - "proto-google-cloud-build-v1/src/main/proto/google/devtools/cloudbuild/v1/cloudbuild.proto", - "renovate.json", - "samples/install-without-bom/pom.xml", - "samples/pom.xml", - "samples/snapshot/pom.xml", - "samples/snippets/pom.xml" - ] -} \ No newline at end of file diff --git a/versions.txt b/versions.txt deleted file mode 100644 index da84c6d1..00000000 --- a/versions.txt +++ /dev/null @@ -1,6 +0,0 @@ -# Format: -# module:released-version:current-version - -google-cloud-build:3.5.6:3.5.7-SNAPSHOT -grpc-google-cloud-build-v1:3.5.6:3.5.7-SNAPSHOT -proto-google-cloud-build-v1:3.5.6:3.5.7-SNAPSHOT