From 97d433f9215aa141e5c002752be599fb8bf20df8 Mon Sep 17 00:00:00 2001 From: Jeff Ching Date: Tue, 5 May 2020 07:31:08 -0700 Subject: [PATCH 01/15] chore: make repo releasable (#1) --- .github/ISSUE_TEMPLATE/bug_report.md | 51 ++ .github/ISSUE_TEMPLATE/feature_request.md | 21 + .github/ISSUE_TEMPLATE/support_request.md | 7 + .github/PULL_REQUEST_TEMPLATE.md | 7 + .github/release-please.yml | 2 + .github/trusted-contribution.yml | 2 + .gitignore | 15 + .kokoro/build.bat | 3 + .kokoro/build.sh | 113 +++ .kokoro/coerce_logs.sh | 38 + .kokoro/common.cfg | 13 + .kokoro/common.sh | 59 ++ .kokoro/continuous/common.cfg | 25 + .kokoro/continuous/dependencies.cfg | 12 + .kokoro/continuous/integration.cfg | 7 + .kokoro/continuous/java11.cfg | 7 + .kokoro/continuous/java7.cfg | 7 + .kokoro/continuous/java8-osx.cfg | 3 + .kokoro/continuous/java8-win.cfg | 3 + .kokoro/continuous/java8.cfg | 12 + .kokoro/continuous/lint.cfg | 13 + .kokoro/continuous/propose_release.cfg | 53 ++ .kokoro/continuous/samples.cfg | 31 + .kokoro/dependencies.sh | 86 ++ .kokoro/linkage-monitor.sh | 46 + .kokoro/nightly/common.cfg | 25 + .kokoro/nightly/dependencies.cfg | 12 + .kokoro/nightly/integration.cfg | 41 + .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/lint.cfg | 13 + .kokoro/nightly/samples.cfg | 42 + .kokoro/presubmit/clirr.cfg | 13 + .kokoro/presubmit/common.cfg | 34 + .kokoro/presubmit/dependencies.cfg | 12 + .kokoro/presubmit/integration.cfg | 37 + .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 | 37 + .kokoro/release/bump_snapshot.cfg | 53 ++ .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 | 19 + .kokoro/release/publish_javadoc.sh | 55 ++ .kokoro/release/snapshot.cfg | 6 + .kokoro/release/snapshot.sh | 33 + .kokoro/release/stage.cfg | 44 + .kokoro/release/stage.sh | 42 + .kokoro/trampoline.sh | 24 + .repo-metadata.json | 14 + CODE_OF_CONDUCT.md | 93 ++ CONTRIBUTING.md | 130 +++ LICENSE | 227 ++++- README.md | 71 ++ codecov.yaml | 4 + .../clirr-ignored-differences.xml | 10 + grpc-google-iam-v1/pom.xml | 66 ++ .../java/com/google/iam/v1/IAMPolicyGrpc.java | 526 ++++++----- java.header | 15 + license-checks.xml | 10 + pom.xml | 188 ++++ proto-google-iam-v1/pom.xml | 34 + .../com/google/iam/v1/AuditConfigDelta.java | 838 ++++++++++-------- .../iam/v1/AuditConfigDeltaOrBuilder.java | 67 +- .../main/java/com/google/iam/v1/Binding.java | 681 ++++++++------ .../java/com/google/iam/v1/BindingDelta.java | 800 ++++++++++------- .../google/iam/v1/BindingDeltaOrBuilder.java | 64 +- .../com/google/iam/v1/BindingOrBuilder.java | 67 +- .../google/iam/v1/GetIamPolicyRequest.java | 604 +++++++------ .../iam/v1/GetIamPolicyRequestOrBuilder.java | 53 +- .../com/google/iam/v1/GetPolicyOptions.java | 380 ++++---- .../iam/v1/GetPolicyOptionsOrBuilder.java | 22 +- .../com/google/iam/v1/IamPolicyProto.java | 199 +++-- .../java/com/google/iam/v1/OptionsProto.java | 87 +- .../main/java/com/google/iam/v1/Policy.java | 624 +++++++------ .../java/com/google/iam/v1/PolicyDelta.java | 618 ++++++++----- .../google/iam/v1/PolicyDeltaOrBuilder.java | 59 +- .../com/google/iam/v1/PolicyOrBuilder.java | 58 +- .../java/com/google/iam/v1/PolicyProto.java | 192 ++-- .../google/iam/v1/SetIamPolicyRequest.java | 625 +++++++------ .../iam/v1/SetIamPolicyRequestOrBuilder.java | 59 +- .../iam/v1/TestIamPermissionsRequest.java | 671 ++++++++------ .../TestIamPermissionsRequestOrBuilder.java | 73 +- .../iam/v1/TestIamPermissionsResponse.java | 480 ++++++---- .../TestIamPermissionsResponseOrBuilder.java | 44 +- .../com/google/iam/v1/logging/AuditData.java | 444 ++++++---- .../iam/v1/logging/AuditDataOrBuilder.java | 28 +- .../google/iam/v1/logging/AuditDataProto.java | 93 +- renovate.json | 80 ++ synth.metadata | 37 + synth.py | 68 ++ versions.txt | 4 + 104 files changed, 7547 insertions(+), 3404 deletions(-) create mode 100644 .github/ISSUE_TEMPLATE/bug_report.md create mode 100644 .github/ISSUE_TEMPLATE/feature_request.md create mode 100644 .github/ISSUE_TEMPLATE/support_request.md create mode 100644 .github/PULL_REQUEST_TEMPLATE.md create mode 100644 .github/release-please.yml create mode 100644 .github/trusted-contribution.yml create mode 100644 .gitignore create mode 100644 .kokoro/build.bat create mode 100755 .kokoro/build.sh create mode 100755 .kokoro/coerce_logs.sh create mode 100644 .kokoro/common.cfg create mode 100644 .kokoro/common.sh create mode 100644 .kokoro/continuous/common.cfg create mode 100644 .kokoro/continuous/dependencies.cfg create mode 100644 .kokoro/continuous/integration.cfg create mode 100644 .kokoro/continuous/java11.cfg create mode 100644 .kokoro/continuous/java7.cfg create mode 100644 .kokoro/continuous/java8-osx.cfg create mode 100644 .kokoro/continuous/java8-win.cfg create mode 100644 .kokoro/continuous/java8.cfg create mode 100644 .kokoro/continuous/lint.cfg create mode 100644 .kokoro/continuous/propose_release.cfg create mode 100644 .kokoro/continuous/samples.cfg create mode 100755 .kokoro/dependencies.sh create mode 100755 .kokoro/linkage-monitor.sh create mode 100644 .kokoro/nightly/common.cfg create mode 100644 .kokoro/nightly/dependencies.cfg create mode 100644 .kokoro/nightly/integration.cfg create mode 100644 .kokoro/nightly/java11.cfg create mode 100644 .kokoro/nightly/java7.cfg create mode 100644 .kokoro/nightly/java8-osx.cfg create mode 100644 .kokoro/nightly/java8-win.cfg create mode 100644 .kokoro/nightly/java8.cfg create mode 100644 .kokoro/nightly/lint.cfg create mode 100644 .kokoro/nightly/samples.cfg create mode 100644 .kokoro/presubmit/clirr.cfg create mode 100644 .kokoro/presubmit/common.cfg create mode 100644 .kokoro/presubmit/dependencies.cfg create mode 100644 .kokoro/presubmit/integration.cfg create mode 100644 .kokoro/presubmit/java11.cfg create mode 100644 .kokoro/presubmit/java7.cfg create mode 100644 .kokoro/presubmit/java8-osx.cfg create mode 100644 .kokoro/presubmit/java8-win.cfg create mode 100644 .kokoro/presubmit/java8.cfg create mode 100644 .kokoro/presubmit/linkage-monitor.cfg create mode 100644 .kokoro/presubmit/lint.cfg create mode 100644 .kokoro/presubmit/samples.cfg create mode 100644 .kokoro/release/bump_snapshot.cfg create mode 100644 .kokoro/release/common.cfg create mode 100755 .kokoro/release/common.sh create mode 100644 .kokoro/release/drop.cfg create mode 100755 .kokoro/release/drop.sh create mode 100644 .kokoro/release/promote.cfg create mode 100755 .kokoro/release/promote.sh create mode 100644 .kokoro/release/publish_javadoc.cfg create mode 100755 .kokoro/release/publish_javadoc.sh create mode 100644 .kokoro/release/snapshot.cfg create mode 100755 .kokoro/release/snapshot.sh create mode 100644 .kokoro/release/stage.cfg create mode 100755 .kokoro/release/stage.sh create mode 100644 .kokoro/trampoline.sh create mode 100644 .repo-metadata.json create mode 100644 CODE_OF_CONDUCT.md create mode 100644 CONTRIBUTING.md create mode 100644 README.md create mode 100644 codecov.yaml create mode 100644 grpc-google-iam-v1/clirr-ignored-differences.xml create mode 100644 grpc-google-iam-v1/pom.xml create mode 100644 java.header create mode 100644 license-checks.xml create mode 100644 pom.xml create mode 100644 proto-google-iam-v1/pom.xml create mode 100644 renovate.json create mode 100644 synth.metadata create mode 100644 synth.py create mode 100644 versions.txt diff --git a/.github/ISSUE_TEMPLATE/bug_report.md b/.github/ISSUE_TEMPLATE/bug_report.md new file mode 100644 index 00000000..ca40492f --- /dev/null +++ b/.github/ISSUE_TEMPLATE/bug_report.md @@ -0,0 +1,51 @@ +--- +name: Bug report +about: Create a report to help us improve + +--- + +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-iam/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. iam 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 new file mode 100644 index 00000000..754e30c6 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/feature_request.md @@ -0,0 +1,21 @@ +--- +name: Feature request +about: Suggest an idea for this library + +--- + +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 new file mode 100644 index 00000000..99586903 --- /dev/null +++ b/.github/ISSUE_TEMPLATE/support_request.md @@ -0,0 +1,7 @@ +--- +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 new file mode 100644 index 00000000..dc7bb2ce --- /dev/null +++ b/.github/PULL_REQUEST_TEMPLATE.md @@ -0,0 +1,7 @@ +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-iam/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 # ☕️ diff --git a/.github/release-please.yml b/.github/release-please.yml new file mode 100644 index 00000000..dce2c845 --- /dev/null +++ b/.github/release-please.yml @@ -0,0 +1,2 @@ +releaseType: java-yoshi +bumpMinorPreMajor: true \ No newline at end of file diff --git a/.github/trusted-contribution.yml b/.github/trusted-contribution.yml new file mode 100644 index 00000000..f247d5c7 --- /dev/null +++ b/.github/trusted-contribution.yml @@ -0,0 +1,2 @@ +trustedContributors: +- renovate-bot \ No newline at end of file diff --git a/.gitignore b/.gitignore new file mode 100644 index 00000000..fadd6afc --- /dev/null +++ b/.gitignore @@ -0,0 +1,15 @@ +# Maven +target/ + +# Eclipse +.classpath +.project +.settings + +# Intellij +*.iml +.idea/ + +# python utilities +*.pyc +__pycache__ diff --git a/.kokoro/build.bat b/.kokoro/build.bat new file mode 100644 index 00000000..5af7c27e --- /dev/null +++ b/.kokoro/build.bat @@ -0,0 +1,3 @@ +:: See documentation in type-shell-output.bat + +"C:\Program Files\Git\bin\bash.exe" github/java-iam/.kokoro/build.sh diff --git a/.kokoro/build.sh b/.kokoro/build.sh new file mode 100755 index 00000000..d4d2592d --- /dev/null +++ b/.kokoro/build.sh @@ -0,0 +1,113 @@ +#!/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 Java version +java -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 \ + -DskipTests=true \ + -Dclirr.skip=true \ + -Denforcer.skip=true \ + -Dmaven.javadoc.skip=true \ + -Dgcloud.download.skip=true \ + -T 1C + +# if GOOGLE_APPLICATION_CREDIENTIALS 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_ROOT}/src/${GOOGLE_APPLICATION_CREDENTIALS}) +fi + +RETURN_CODE=0 +set +e + +case ${JOB_TYPE} in +test) + mvn test -B -Dclirr.skip=true -Denforcer.skip=true + RETURN_CODE=$? + ;; +lint) + mvn \ + -Penable-samples \ + com.coveo:fmt-maven-plugin:check + RETURN_CODE=$? + ;; +javadoc) + mvn javadoc:javadoc javadoc:test-javadoc + RETURN_CODE=$? + ;; +integration) + mvn -B ${INTEGRATION_TEST_ARGS} \ + -Penable-integration-tests \ + -DtrimStackTrace=false \ + -Dclirr.skip=true \ + -Denforcer.skip=true \ + -fae \ + verify + RETURN_CODE=$? + ;; +samples) + if [[ -f samples/pom.xml ]] + then + pushd samples + mvn -B \ + -Penable-samples \ + -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 -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_BUILD_COP}" == "true" ]] +then + chmod +x ${KOKORO_GFILE_DIR}/linux_amd64/buildcop + ${KOKORO_GFILE_DIR}/linux_amd64/buildcop -repo=googleapis/java-iam +fi + +echo "exiting with ${RETURN_CODE}" +exit ${RETURN_CODE} diff --git a/.kokoro/coerce_logs.sh b/.kokoro/coerce_logs.sh new file mode 100755 index 00000000..5cf7ba49 --- /dev/null +++ b/.kokoro/coerce_logs.sh @@ -0,0 +1,38 @@ +#!/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 + echo "processing ${xml}" + 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 new file mode 100644 index 00000000..349dd92a --- /dev/null +++ b/.kokoro/common.cfg @@ -0,0 +1,13 @@ +# 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-iam/.kokoro/trampoline.sh" + +# Tell the trampoline which build file to use. +env_vars: { + key: "TRAMPOLINE_BUILD_FILE" + value: "github/java-iam/.kokoro/build.sh" +} diff --git a/.kokoro/common.sh b/.kokoro/common.sh new file mode 100644 index 00000000..a8d0ea04 --- /dev/null +++ b/.kokoro/common.sh @@ -0,0 +1,59 @@ +#!/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 + echo "${command}" + ${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) $*"; } \ No newline at end of file diff --git a/.kokoro/continuous/common.cfg b/.kokoro/continuous/common.cfg new file mode 100644 index 00000000..90c639ac --- /dev/null +++ b/.kokoro/continuous/common.cfg @@ -0,0 +1,25 @@ +# 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-iam/.kokoro/trampoline.sh" + +env_vars: { + key: "TRAMPOLINE_BUILD_FILE" + value: "github/java-iam/.kokoro/build.sh" +} + +env_vars: { + key: "JOB_TYPE" + value: "test" +} diff --git a/.kokoro/continuous/dependencies.cfg b/.kokoro/continuous/dependencies.cfg new file mode 100644 index 00000000..fda7101a --- /dev/null +++ b/.kokoro/continuous/dependencies.cfg @@ -0,0 +1,12 @@ +# 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-iam/.kokoro/dependencies.sh" +} diff --git a/.kokoro/continuous/integration.cfg b/.kokoro/continuous/integration.cfg new file mode 100644 index 00000000..3b017fc8 --- /dev/null +++ b/.kokoro/continuous/integration.cfg @@ -0,0 +1,7 @@ +# 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" +} diff --git a/.kokoro/continuous/java11.cfg b/.kokoro/continuous/java11.cfg new file mode 100644 index 00000000..709f2b4c --- /dev/null +++ b/.kokoro/continuous/java11.cfg @@ -0,0 +1,7 @@ +# 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/continuous/java7.cfg b/.kokoro/continuous/java7.cfg new file mode 100644 index 00000000..cb24f44e --- /dev/null +++ b/.kokoro/continuous/java7.cfg @@ -0,0 +1,7 @@ +# 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/continuous/java8-osx.cfg b/.kokoro/continuous/java8-osx.cfg new file mode 100644 index 00000000..1affbbe4 --- /dev/null +++ b/.kokoro/continuous/java8-osx.cfg @@ -0,0 +1,3 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +build_file: "java-iam/.kokoro/build.sh" diff --git a/.kokoro/continuous/java8-win.cfg b/.kokoro/continuous/java8-win.cfg new file mode 100644 index 00000000..4c8e051a --- /dev/null +++ b/.kokoro/continuous/java8-win.cfg @@ -0,0 +1,3 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +build_file: "java-iam/.kokoro/build.bat" diff --git a/.kokoro/continuous/java8.cfg b/.kokoro/continuous/java8.cfg new file mode 100644 index 00000000..495cc7ba --- /dev/null +++ b/.kokoro/continuous/java8.cfg @@ -0,0 +1,12 @@ +# 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/lint.cfg b/.kokoro/continuous/lint.cfg new file mode 100644 index 00000000..6d323c8a --- /dev/null +++ b/.kokoro/continuous/lint.cfg @@ -0,0 +1,13 @@ +# 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/continuous/propose_release.cfg b/.kokoro/continuous/propose_release.cfg new file mode 100644 index 00000000..4df19cc2 --- /dev/null +++ b/.kokoro/continuous/propose_release.cfg @@ -0,0 +1,53 @@ +# 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-iam/.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-iam/.kokoro/continuous/propose_release.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/continuous/samples.cfg b/.kokoro/continuous/samples.cfg new file mode 100644 index 00000000..fa7b493d --- /dev/null +++ b/.kokoro/continuous/samples.cfg @@ -0,0 +1,31 @@ +# 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" +} + +env_vars: { + key: "GCLOUD_PROJECT" + value: "gcloud-devel" +} + +env_vars: { + key: "GOOGLE_APPLICATION_CREDENTIALS" + value: "keystore/73713_java_it_service_account" +} + +before_action { + fetch_keystore { + keystore_resource { + keystore_config_id: 73713 + keyname: "java_it_service_account" + } + } +} diff --git a/.kokoro/dependencies.sh b/.kokoro/dependencies.sh new file mode 100755 index 00000000..cf3bb434 --- /dev/null +++ b/.kokoro/dependencies.sh @@ -0,0 +1,86 @@ +#!/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 Java +java -version +echo $JOB_TYPE + +export MAVEN_OPTS="-Xmx1024m -XX:MaxPermSize=128m" + +# this should run maven enforcer +retry_with_backoff 3 10 \ + mvn install -B -V \ + -DskipTests=true \ + -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 + msg "Generating dependency list using original pom..." + mvn dependency:list -f pom.xml -Dsort=true | grep '\[INFO] .*:.*:.*:.*:.*' | grep -v ':test$' >.org-list.txt + + # Output dep list generated using the flattened pom (test scope deps are ommitted) + msg "Generating dependency list using flattened pom..." + mvn dependency:list -f .flattened-pom.xml -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 $(find -name ".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/linkage-monitor.sh b/.kokoro/linkage-monitor.sh new file mode 100755 index 00000000..759ab4e2 --- /dev/null +++ b/.kokoro/linkage-monitor.sh @@ -0,0 +1,46 @@ +#!/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 +# Display commands being run. +set -x + +## 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 version +java -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 \ + -DskipTests=true \ + -Dclirr.skip=true \ + -Denforcer.skip=true \ + -Dmaven.javadoc.skip=true \ + -Dgcloud.download.skip=true + +# Kokoro job cloud-opensource-java/ubuntu/linkage-monitor-gcs creates this JAR +JAR=linkage-monitor-latest-all-deps.jar +curl -v -O "https://storage.googleapis.com/cloud-opensource-java-linkage-monitor/${JAR}" + +# Fails if there's new linkage errors compared with baseline +java -jar ${JAR} com.google.cloud:libraries-bom diff --git a/.kokoro/nightly/common.cfg b/.kokoro/nightly/common.cfg new file mode 100644 index 00000000..90c639ac --- /dev/null +++ b/.kokoro/nightly/common.cfg @@ -0,0 +1,25 @@ +# 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-iam/.kokoro/trampoline.sh" + +env_vars: { + key: "TRAMPOLINE_BUILD_FILE" + value: "github/java-iam/.kokoro/build.sh" +} + +env_vars: { + key: "JOB_TYPE" + value: "test" +} diff --git a/.kokoro/nightly/dependencies.cfg b/.kokoro/nightly/dependencies.cfg new file mode 100644 index 00000000..fda7101a --- /dev/null +++ b/.kokoro/nightly/dependencies.cfg @@ -0,0 +1,12 @@ +# 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-iam/.kokoro/dependencies.sh" +} diff --git a/.kokoro/nightly/integration.cfg b/.kokoro/nightly/integration.cfg new file mode 100644 index 00000000..40c4abb7 --- /dev/null +++ b/.kokoro/nightly/integration.cfg @@ -0,0 +1,41 @@ +# 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: "ENABLE_BUILD_COP" + value: "true" +} + +env_vars: { + key: "GOOGLE_APPLICATION_CREDENTIALS" + value: "keystore/73713_java_it_service_account" +} + +before_action { + fetch_keystore { + keystore_resource { + keystore_config_id: 73713 + keyname: "java_it_service_account" + } + } +} diff --git a/.kokoro/nightly/java11.cfg b/.kokoro/nightly/java11.cfg new file mode 100644 index 00000000..709f2b4c --- /dev/null +++ b/.kokoro/nightly/java11.cfg @@ -0,0 +1,7 @@ +# 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 new file mode 100644 index 00000000..cb24f44e --- /dev/null +++ b/.kokoro/nightly/java7.cfg @@ -0,0 +1,7 @@ +# 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 new file mode 100644 index 00000000..1affbbe4 --- /dev/null +++ b/.kokoro/nightly/java8-osx.cfg @@ -0,0 +1,3 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +build_file: "java-iam/.kokoro/build.sh" diff --git a/.kokoro/nightly/java8-win.cfg b/.kokoro/nightly/java8-win.cfg new file mode 100644 index 00000000..4c8e051a --- /dev/null +++ b/.kokoro/nightly/java8-win.cfg @@ -0,0 +1,3 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +build_file: "java-iam/.kokoro/build.bat" diff --git a/.kokoro/nightly/java8.cfg b/.kokoro/nightly/java8.cfg new file mode 100644 index 00000000..495cc7ba --- /dev/null +++ b/.kokoro/nightly/java8.cfg @@ -0,0 +1,12 @@ +# 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/lint.cfg b/.kokoro/nightly/lint.cfg new file mode 100644 index 00000000..6d323c8a --- /dev/null +++ b/.kokoro/nightly/lint.cfg @@ -0,0 +1,13 @@ +# 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/nightly/samples.cfg b/.kokoro/nightly/samples.cfg new file mode 100644 index 00000000..20aabd55 --- /dev/null +++ b/.kokoro/nightly/samples.cfg @@ -0,0 +1,42 @@ +# 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: "keystore/73713_java_it_service_account" +} + +env_vars: { + key: "ENABLE_BUILD_COP" + value: "true" +} + +before_action { + fetch_keystore { + keystore_resource { + keystore_config_id: 73713 + keyname: "java_it_service_account" + } + } +} diff --git a/.kokoro/presubmit/clirr.cfg b/.kokoro/presubmit/clirr.cfg new file mode 100644 index 00000000..ec572442 --- /dev/null +++ b/.kokoro/presubmit/clirr.cfg @@ -0,0 +1,13 @@ +# 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 new file mode 100644 index 00000000..5bce0b64 --- /dev/null +++ b/.kokoro/presubmit/common.cfg @@ -0,0 +1,34 @@ +# 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-iam/.kokoro/trampoline.sh" + +env_vars: { + key: "TRAMPOLINE_BUILD_FILE" + value: "github/java-iam/.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 new file mode 100644 index 00000000..fda7101a --- /dev/null +++ b/.kokoro/presubmit/dependencies.cfg @@ -0,0 +1,12 @@ +# 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-iam/.kokoro/dependencies.sh" +} diff --git a/.kokoro/presubmit/integration.cfg b/.kokoro/presubmit/integration.cfg new file mode 100644 index 00000000..522e5b10 --- /dev/null +++ b/.kokoro/presubmit/integration.cfg @@ -0,0 +1,37 @@ +# 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: "keystore/73713_java_it_service_account" +} + +before_action { + fetch_keystore { + keystore_resource { + keystore_config_id: 73713 + keyname: "java_it_service_account" + } + } +} diff --git a/.kokoro/presubmit/java11.cfg b/.kokoro/presubmit/java11.cfg new file mode 100644 index 00000000..709f2b4c --- /dev/null +++ b/.kokoro/presubmit/java11.cfg @@ -0,0 +1,7 @@ +# 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 new file mode 100644 index 00000000..cb24f44e --- /dev/null +++ b/.kokoro/presubmit/java7.cfg @@ -0,0 +1,7 @@ +# 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 new file mode 100644 index 00000000..1affbbe4 --- /dev/null +++ b/.kokoro/presubmit/java8-osx.cfg @@ -0,0 +1,3 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +build_file: "java-iam/.kokoro/build.sh" diff --git a/.kokoro/presubmit/java8-win.cfg b/.kokoro/presubmit/java8-win.cfg new file mode 100644 index 00000000..4c8e051a --- /dev/null +++ b/.kokoro/presubmit/java8-win.cfg @@ -0,0 +1,3 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +build_file: "java-iam/.kokoro/build.bat" diff --git a/.kokoro/presubmit/java8.cfg b/.kokoro/presubmit/java8.cfg new file mode 100644 index 00000000..495cc7ba --- /dev/null +++ b/.kokoro/presubmit/java8.cfg @@ -0,0 +1,12 @@ +# 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 new file mode 100644 index 00000000..7af8810a --- /dev/null +++ b/.kokoro/presubmit/linkage-monitor.cfg @@ -0,0 +1,12 @@ +# 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-iam/.kokoro/linkage-monitor.sh" +} \ No newline at end of file diff --git a/.kokoro/presubmit/lint.cfg b/.kokoro/presubmit/lint.cfg new file mode 100644 index 00000000..6d323c8a --- /dev/null +++ b/.kokoro/presubmit/lint.cfg @@ -0,0 +1,13 @@ +# 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 new file mode 100644 index 00000000..1171aead --- /dev/null +++ b/.kokoro/presubmit/samples.cfg @@ -0,0 +1,37 @@ +# 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: "keystore/73713_java_it_service_account" +} + +before_action { + fetch_keystore { + keystore_resource { + keystore_config_id: 73713 + keyname: "java_it_service_account" + } + } +} diff --git a/.kokoro/release/bump_snapshot.cfg b/.kokoro/release/bump_snapshot.cfg new file mode 100644 index 00000000..1e28b5ed --- /dev/null +++ b/.kokoro/release/bump_snapshot.cfg @@ -0,0 +1,53 @@ +# 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-iam/.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-iam/.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/common.cfg b/.kokoro/release/common.cfg new file mode 100644 index 00000000..9428634a --- /dev/null +++ b/.kokoro/release/common.cfg @@ -0,0 +1,49 @@ +# 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-iam/.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 new file mode 100755 index 00000000..6e3f6599 --- /dev/null +++ b/.kokoro/release/common.sh @@ -0,0 +1,50 @@ +#!/bin/bash +# Copyright 2018 Google Inc. +# +# 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 new file mode 100644 index 00000000..85fcca33 --- /dev/null +++ b/.kokoro/release/drop.cfg @@ -0,0 +1,6 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +env_vars: { + key: "TRAMPOLINE_BUILD_FILE" + value: "github/java-iam/.kokoro/release/drop.sh" +} diff --git a/.kokoro/release/drop.sh b/.kokoro/release/drop.sh new file mode 100755 index 00000000..5c4551ef --- /dev/null +++ b/.kokoro/release/drop.sh @@ -0,0 +1,32 @@ +#!/bin/bash +# Copyright 2018 Google Inc. +# +# 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 new file mode 100644 index 00000000..de997603 --- /dev/null +++ b/.kokoro/release/promote.cfg @@ -0,0 +1,6 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +env_vars: { + key: "TRAMPOLINE_BUILD_FILE" + value: "github/java-iam/.kokoro/release/promote.sh" +} diff --git a/.kokoro/release/promote.sh b/.kokoro/release/promote.sh new file mode 100755 index 00000000..1fa95fa5 --- /dev/null +++ b/.kokoro/release/promote.sh @@ -0,0 +1,34 @@ +#!/bin/bash +# Copyright 2018 Google Inc. +# +# 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 new file mode 100644 index 00000000..f18e3d1d --- /dev/null +++ b/.kokoro/release/publish_javadoc.cfg @@ -0,0 +1,19 @@ +# Format: //devtools/kokoro/config/proto/build.proto +env_vars: { + key: "STAGING_BUCKET" + value: "docs-staging" +} + +env_vars: { + key: "TRAMPOLINE_BUILD_FILE" + value: "github/java-iam/.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 new file mode 100755 index 00000000..9542b0ee --- /dev/null +++ b/.kokoro/release/publish_javadoc.sh @@ -0,0 +1,55 @@ +#!/bin/bash +# Copyright 2019 Google Inc. +# +# 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 gcp-docuploader + +# compile all packages +mvn clean install -B -DskipTests=true + +NAME=proto-google-iam-v1 +VERSION=$(grep ${NAME}: versions.txt | cut -d: -f3) + +# build the docs +mvn site -B + +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} + +popd diff --git a/.kokoro/release/snapshot.cfg b/.kokoro/release/snapshot.cfg new file mode 100644 index 00000000..2a39f44f --- /dev/null +++ b/.kokoro/release/snapshot.cfg @@ -0,0 +1,6 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +env_vars: { + key: "TRAMPOLINE_BUILD_FILE" + value: "github/java-iam/.kokoro/release/snapshot.sh" +} \ No newline at end of file diff --git a/.kokoro/release/snapshot.sh b/.kokoro/release/snapshot.sh new file mode 100755 index 00000000..098168a7 --- /dev/null +++ b/.kokoro/release/snapshot.sh @@ -0,0 +1,33 @@ +#!/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 install 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 new file mode 100644 index 00000000..ba7799f2 --- /dev/null +++ b/.kokoro/release/stage.cfg @@ -0,0 +1,44 @@ +# Format: //devtools/kokoro/config/proto/build.proto + +env_vars: { + key: "TRAMPOLINE_BUILD_FILE" + value: "github/java-iam/.kokoro/release/stage.sh" +} + +# Need to save the properties file +action { + define_artifacts { + regex: "github/java-iam/target/nexus-staging/staging/*.properties" + strip_prefix: "github/java-iam" + } +} + +# Fetch the token needed for reporting release status to GitHub +before_action { + fetch_keystore { + keystore_resource { + keystore_config_id: 73713 + keyname: "yoshi-automation-github-key" + } + } +} + +# Fetch magictoken to use with Magic Github Proxy +before_action { + fetch_keystore { + keystore_resource { + keystore_config_id: 73713 + keyname: "releasetool-magictoken" + } + } +} + +# Fetch api key to use with Magic Github Proxy +before_action { + fetch_keystore { + keystore_resource { + keystore_config_id: 73713 + keyname: "magic-github-proxy-api-key" + } + } +} diff --git a/.kokoro/release/stage.sh b/.kokoro/release/stage.sh new file mode 100755 index 00000000..3c482cbc --- /dev/null +++ b/.kokoro/release/stage.sh @@ -0,0 +1,42 @@ +#!/bin/bash +# Copyright 2018 Google Inc. +# +# 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 +python3 -m pip install gcp-releasetool +python3 -m releasetool publish-reporter-script > /tmp/publisher-script; source /tmp/publisher-script + +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" + +mvn clean install deploy -B \ + --settings ${MAVEN_SETTINGS_FILE} \ + -DskipTests=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 \ No newline at end of file diff --git a/.kokoro/trampoline.sh b/.kokoro/trampoline.sh new file mode 100644 index 00000000..ba17ce01 --- /dev/null +++ b/.kokoro/trampoline.sh @@ -0,0 +1,24 @@ +#!/bin/bash +# Copyright 2018 Google Inc. +# +# 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 +python3 "${KOKORO_GFILE_DIR}/trampoline_v1.py" diff --git a/.repo-metadata.json b/.repo-metadata.json new file mode 100644 index 00000000..ac0e0203 --- /dev/null +++ b/.repo-metadata.json @@ -0,0 +1,14 @@ +{ + "name": "iam", + "name_pretty": "IAM", + "product_documentation": "n/a", + "api_description": "n/a", + "client_documentation": "https://googleapis.dev/java/proto-google-iam-v1/latest/index.html", + "release_level": "beta", + "transport": "grpc", + "requires_billing": true, + "language": "java", + "repo": "googleapis/java-iam", + "repo_short": "java-iam", + "distribution_name": "com.google.api.grpc:proto-google-iam-v1" +} diff --git a/CODE_OF_CONDUCT.md b/CODE_OF_CONDUCT.md new file mode 100644 index 00000000..6b2238bb --- /dev/null +++ b/CODE_OF_CONDUCT.md @@ -0,0 +1,93 @@ +# Code of Conduct + +## Our Pledge + +In the interest of fostering an open and welcoming environment, we as +contributors and maintainers pledge to making participation in our project and +our community a harassment-free experience for everyone, regardless of age, body +size, disability, ethnicity, gender identity and expression, level of +experience, education, socio-economic status, nationality, personal appearance, +race, religion, or sexual identity and orientation. + +## Our Standards + +Examples of behavior that contributes to creating a positive environment +include: + +* Using welcoming and inclusive language +* Being respectful of differing viewpoints and experiences +* Gracefully accepting constructive criticism +* Focusing on what is best for the community +* Showing empathy towards other community members + +Examples of unacceptable behavior by participants include: + +* The use of sexualized language or imagery and unwelcome sexual attention or + advances +* Trolling, insulting/derogatory comments, and personal or political attacks +* Public or private harassment +* Publishing others' private information, such as a physical or electronic + address, without explicit permission +* Other conduct which could reasonably be considered inappropriate in a + professional setting + +## Our Responsibilities + +Project maintainers are responsible for clarifying the standards of acceptable +behavior and are expected to take appropriate and fair corrective action in +response to any instances of unacceptable behavior. + +Project maintainers have the right and responsibility to remove, edit, or reject +comments, commits, code, wiki edits, issues, and other contributions that are +not aligned to this Code of Conduct, or to ban temporarily or permanently any +contributor for other behaviors that they deem inappropriate, threatening, +offensive, or harmful. + +## Scope + +This Code of Conduct applies both within project spaces and in public spaces +when an individual is representing the project or its community. Examples of +representing a project or community include using an official project e-mail +address, posting via an official social media account, or acting as an appointed +representative at an online or offline event. Representation of a project may be +further defined and clarified by project maintainers. + +This Code of Conduct also applies outside the project spaces when the Project +Steward has a reasonable belief that an individual's behavior may have a +negative impact on the project or its community. + +## Conflict Resolution + +We do not believe that all conflict is bad; healthy debate and disagreement +often yield positive results. However, it is never okay to be disrespectful or +to engage in behavior that violates the project’s code of conduct. + +If you see someone violating the code of conduct, you are encouraged to address +the behavior directly with those involved. Many issues can be resolved quickly +and easily, and this gives people more control over the outcome of their +dispute. If you are unable to resolve the matter for any reason, or if the +behavior is threatening or harassing, report it. We are dedicated to providing +an environment where participants feel welcome and safe. + +Reports should be directed to *[PROJECT STEWARD NAME(s) AND EMAIL(s)]*, the +Project Steward(s) for *[PROJECT NAME]*. It is the Project Steward’s duty to +receive and address reported violations of the code of conduct. They will then +work with a committee consisting of representatives from the Open Source +Programs Office and the Google Open Source Strategy team. If for any reason you +are uncomfortable reaching out the Project Steward, please email +opensource@google.com. + +We will investigate every complaint, but you may not receive a direct response. +We will use our discretion in determining when and how to follow up on reported +incidents, which may range from not taking action to permanent expulsion from +the project and project-sponsored spaces. We will notify the accused of the +report and provide them an opportunity to discuss it before any action is taken. +The identity of the reporter will be omitted from the details of the report +supplied to the accused. In potentially harmful situations, such as ongoing +harassment or threats to anyone's safety, we may take action without notice. + +## Attribution + +This Code of Conduct is adapted from the Contributor Covenant, version 1.4, +available at +https://www.contributor-covenant.org/version/1/4/code-of-conduct.html \ No newline at end of file diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md new file mode 100644 index 00000000..085021dd --- /dev/null +++ b/CONTRIBUTING.md @@ -0,0 +1,130 @@ +# How to Contribute + +We'd love to accept your patches and contributions to this project. There are +just a few small guidelines you need to follow. + +## Contributor License Agreement + +Contributions to this project must be accompanied by a Contributor License +Agreement. You (or your employer) retain the copyright to your contribution; +this simply gives us permission to use and redistribute your contributions as +part of the project. Head over to to see +your current agreements on file or to sign a new one. + +You generally only need to submit a CLA once, so if you've already submitted one +(even if it was for a different project), you probably don't need to do it +again. + +## Code reviews + +All submissions, including submissions by project members, require review. We +use GitHub pull requests for this purpose. Consult +[GitHub Help](https://help.github.com/articles/about-pull-requests/) for more +information on using pull requests. + +## Community Guidelines + +This project follows +[Google's Open Source Community Guidelines](https://opensource.google.com/conduct/). + +## Building the project + +To build, package, and run all unit tests run the command + +``` +mvn clean verify +``` + +### Running Integration tests + +To include integration tests when building the project, you need access to +a GCP Project with a valid service account. + +For instructions on how to generate a service account and corresponding +credentials JSON see: [Creating a Service Account][1]. + +Then run the following to build, package, run all unit tests and run all +integration tests. + +```bash +export GOOGLE_APPLICATION_CREDENTIALS=/path/to/service/account.json +mvn -Penable-integration-tests clean verify +``` + +## Code Samples + +Code Samples must be bundled in separate Maven modules, and guarded by a +Maven profile with the name `enable-samples`. + +The samples must be separate from the primary project for a few reasons: +1. Primary projects have a minimum Java version of Java 7 whereas samples have + a minimum Java version of Java 8. Due to this we need the ability to + selectively exclude samples from a build run. +2. Many code samples depend on external GCP services and need + credentials to access the service. +3. Code samples are not released as Maven artifacts and must be excluded from + release builds. + +### Building + +```bash +mvn -Penable-samples clean verify +``` + +Some samples require access to GCP services and require a service account: + +```bash +export GOOGLE_APPLICATION_CREDENTIALS=/path/to/service/account.json +mvn -Penable-samples clean verify +``` + +### Profile Config + +1. To add samples in a profile to your Maven project, add the following to your +`pom.xml` + + ```xml + + [...] + + + enable-samples + + sample + + + + [...] + + ``` + +2. [Activate](#profile-activation) the profile. +3. Define your samples in a normal Maven project in the `samples/` directory + +### Profile Activation + +To include code samples when building and testing the project, enable the +`enable-samples` Maven profile. + +#### Command line + +To activate the Maven profile on the command line add `-Penable-samples` to your +Maven command. + +#### Maven `settings.xml` + +To activate the Maven profile in your `~/.m2/settings.xml` add an entry of +`enable-samples` following the instructions in [Active Profiles][2]. + +This method has the benefit of applying to all projects you build (and is +respected by IntelliJ IDEA) and is recommended if you are going to be +contributing samples to several projects. + +#### IntelliJ IDEA + +To activate the Maven Profile inside IntelliJ IDEA, follow the instructions in +[Activate Maven profiles][3] to activate `enable-samples`. + +[1]: https://cloud.google.com/docs/authentication/getting-started#creating_a_service_account +[2]: https://maven.apache.org/settings.html#Active_Profiles +[3]: https://www.jetbrains.com/help/idea/work-with-maven-profiles.html#activate_maven_profiles diff --git a/LICENSE b/LICENSE index 1839ff93..d6456956 100644 --- a/LICENSE +++ b/LICENSE @@ -1,25 +1,202 @@ -Copyright 2016, Google Inc. -All rights reserved. -Redistribution and use in source and binary forms, with or without -modification, are permitted provided that the following conditions are -met: - * Redistributions of source code must retain the above copyright -notice, this list of conditions and the following disclaimer. - * Redistributions in binary form must reproduce the above -copyright notice, this list of conditions and the following disclaimer -in the documentation and/or other materials provided with the -distribution. - * Neither the name of Google Inc. nor the names of its -contributors may be used to endorse or promote products derived from -this software without specific prior written permission. -THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -"AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + + Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS + + APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "[]" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + + Copyright [yyyy] [name of copyright owner] + + 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. diff --git a/README.md b/README.md new file mode 100644 index 00000000..463fd7cb --- /dev/null +++ b/README.md @@ -0,0 +1,71 @@ +# Google IAM Policy Protos + +Java protobuf classes for IAM Policy. + +[![Maven][maven-version-image]][maven-version-link] +![Stability][stability-image] + +- [Client Library Documentation][javadocs] + +> Note: This client is a work-in-progress, and may occasionally +> make backwards-incompatible changes. + +## Java Versions + +Java 7 or above is required for using this client. + +## Versioning + +This library follows [Semantic Versioning](http://semver.org/). + +It is currently in major version zero (`0.y.z`), which means that anything may change at any time +and the public API should not be considered stable. + +## Contributing + +Contributions to this library are always welcome and highly encouraged. + +See [CONTRIBUTING][contributing] for more information how to get started. + +Please note that this project is released with a Contributor Code of Conduct. By participating in +this project you agree to abide by its terms. See [Code of Conduct][code-of-conduct] for more +information. + +## License + +Apache 2.0 - See [LICENSE][license] for more information. + +## CI Status + +| Java Version | Status | +| -------------- | --------------------------------------------------------- | +| Java 7 | [![Kokoro CI][kokoro-badge-image-1]][kokoro-badge-link-1] | +| Java 8 | [![Kokoro CI][kokoro-badge-image-2]][kokoro-badge-link-2] | +| Java 8 OSX | [![Kokoro CI][kokoro-badge-image-3]][kokoro-badge-link-3] | +| Java 8 Windows | [![Kokoro CI][kokoro-badge-image-4]][kokoro-badge-link-4] | +| Java 11 | [![Kokoro CI][kokoro-badge-image-5]][kokoro-badge-link-5] | + +[javadocs]: https://googleapis.dev/java/google-iam/latest/index.html +[kokoro-badge-image-1]: http://storage.googleapis.com/cloud-devrel-public/java/badges/java-iam/java7.svg +[kokoro-badge-link-1]: http://storage.googleapis.com/cloud-devrel-public/java/badges/java-iam/java7.html +[kokoro-badge-image-2]: http://storage.googleapis.com/cloud-devrel-public/java/badges/java-iam/java8.svg +[kokoro-badge-link-2]: http://storage.googleapis.com/cloud-devrel-public/java/badges/java-iam/java8.html +[kokoro-badge-image-3]: http://storage.googleapis.com/cloud-devrel-public/java/badges/java-iam/java8-osx.svg +[kokoro-badge-link-3]: http://storage.googleapis.com/cloud-devrel-public/java/badges/java-iam/java8-osx.html +[kokoro-badge-image-4]: http://storage.googleapis.com/cloud-devrel-public/java/badges/java-iam/java8-win.svg +[kokoro-badge-link-4]: http://storage.googleapis.com/cloud-devrel-public/java/badges/java-iam/java8-win.html +[kokoro-badge-image-5]: http://storage.googleapis.com/cloud-devrel-public/java/badges/java-iam/java11.svg +[kokoro-badge-link-5]: http://storage.googleapis.com/cloud-devrel-public/java/badges/java-iam/java11.html +[stability-image]: https://img.shields.io/badge/stability-beta-yellow +[maven-version-image]: https://img.shields.io/maven-central/v/com.google.api.grpc/proto-google-iam-v1.svg +[maven-version-link]: https://search.maven.org/search?q=g:com.google.api.grpc%20AND%20a:proto-google-iam-v1&core=gav +[authentication]: https://github.com/googleapis/google-cloud-java#authentication +[developer-console]: https://console.developers.google.com/ +[create-project]: https://cloud.google.com/resource-manager/docs/creating-managing-projects +[cloud-sdk]: https://cloud.google.com/sdk/ +[troubleshooting]: https://github.com/googleapis/google-cloud-common/blob/master/troubleshooting/readme.md#troubleshooting +[contributing]: https://github.com/googleapis/java-iam/blob/master/CONTRIBUTING.md +[code-of-conduct]: https://github.com/googleapis/java-iam/blob/master/CODE_OF_CONDUCT.md#contributor-code-of-conduct +[license]: https://github.com/googleapis/java-iam/blob/master/LICENSE +[enable-billing]: https://cloud.google.com/apis/docs/getting-started#enabling_billing +[libraries-bom]: https://github.com/GoogleCloudPlatform/cloud-opensource-java/wiki/The-Google-Cloud-Platform-Libraries-BOM diff --git a/codecov.yaml b/codecov.yaml new file mode 100644 index 00000000..5724ea94 --- /dev/null +++ b/codecov.yaml @@ -0,0 +1,4 @@ +--- +codecov: + ci: + - source.cloud.google.com diff --git a/grpc-google-iam-v1/clirr-ignored-differences.xml b/grpc-google-iam-v1/clirr-ignored-differences.xml new file mode 100644 index 00000000..c50256c7 --- /dev/null +++ b/grpc-google-iam-v1/clirr-ignored-differences.xml @@ -0,0 +1,10 @@ + + + + + + 6001 + com/google/iam/v1/IAMPolicyGrpc + METHOD_* + + \ No newline at end of file diff --git a/grpc-google-iam-v1/pom.xml b/grpc-google-iam-v1/pom.xml new file mode 100644 index 00000000..4948f365 --- /dev/null +++ b/grpc-google-iam-v1/pom.xml @@ -0,0 +1,66 @@ + + 4.0.0 + com.google.api.grpc + grpc-google-iam-v1 + 0.13.1-SNAPSHOT + grpc-google-iam-v1 + GRPC library for grpc-google-iam-v1 + + com.google.cloud + google-iam-parent + 0.13.1-SNAPSHOT + + + + io.grpc + grpc-api + + + io.grpc + grpc-stub + + + io.grpc + grpc-protobuf + + + com.google.protobuf + protobuf-java + + + com.google.guava + guava + + + com.google.api.grpc + proto-google-iam-v1 + + + + + + + org.codehaus.mojo + flatten-maven-plugin + + + + + + + java9 + + [9,) + + + + javax.annotation + javax.annotation-api + 1.3.2 + + + + + \ No newline at end of file diff --git a/grpc-google-iam-v1/src/main/java/com/google/iam/v1/IAMPolicyGrpc.java b/grpc-google-iam-v1/src/main/java/com/google/iam/v1/IAMPolicyGrpc.java index 8e676b3e..55edd904 100644 --- a/grpc-google-iam-v1/src/main/java/com/google/iam/v1/IAMPolicyGrpc.java +++ b/grpc-google-iam-v1/src/main/java/com/google/iam/v1/IAMPolicyGrpc.java @@ -1,21 +1,30 @@ +/* + * 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.iam.v1; import static io.grpc.MethodDescriptor.generateFullMethodName; -import static io.grpc.stub.ClientCalls.asyncBidiStreamingCall; -import static io.grpc.stub.ClientCalls.asyncClientStreamingCall; -import static io.grpc.stub.ClientCalls.asyncServerStreamingCall; import static io.grpc.stub.ClientCalls.asyncUnaryCall; -import static io.grpc.stub.ClientCalls.blockingServerStreamingCall; import static io.grpc.stub.ClientCalls.blockingUnaryCall; import static io.grpc.stub.ClientCalls.futureUnaryCall; -import static io.grpc.stub.ServerCalls.asyncBidiStreamingCall; -import static io.grpc.stub.ServerCalls.asyncClientStreamingCall; -import static io.grpc.stub.ServerCalls.asyncServerStreamingCall; import static io.grpc.stub.ServerCalls.asyncUnaryCall; -import static io.grpc.stub.ServerCalls.asyncUnimplementedStreamingCall; import static io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall; /** + * + * *
  * ## API Overview
  * Manages Identity and Access Management (IAM) policies.
@@ -38,7 +47,7 @@
  * 
*/ @javax.annotation.Generated( - value = "by gRPC proto compiler (version 1.10.0)", + value = "by gRPC proto compiler", comments = "Source: google/iam/v1/iam_policy.proto") public final class IAMPolicyGrpc { @@ -47,142 +56,168 @@ private IAMPolicyGrpc() {} public static final String SERVICE_NAME = "google.iam.v1.IAMPolicy"; // Static method descriptors that strictly reflect the proto. - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - @Deprecated // Use {@link #getSetIamPolicyMethod()} instead. - public static final io.grpc.MethodDescriptor METHOD_SET_IAM_POLICY = getSetIamPolicyMethodHelper(); - - private static volatile io.grpc.MethodDescriptor getSetIamPolicyMethod; - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - public static io.grpc.MethodDescriptor getSetIamPolicyMethod() { - return getSetIamPolicyMethodHelper(); - } - - private static io.grpc.MethodDescriptor getSetIamPolicyMethodHelper() { - io.grpc.MethodDescriptor getSetIamPolicyMethod; + private static volatile io.grpc.MethodDescriptor< + com.google.iam.v1.SetIamPolicyRequest, com.google.iam.v1.Policy> + getSetIamPolicyMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "SetIamPolicy", + requestType = com.google.iam.v1.SetIamPolicyRequest.class, + responseType = com.google.iam.v1.Policy.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.iam.v1.SetIamPolicyRequest, com.google.iam.v1.Policy> + getSetIamPolicyMethod() { + io.grpc.MethodDescriptor + getSetIamPolicyMethod; if ((getSetIamPolicyMethod = IAMPolicyGrpc.getSetIamPolicyMethod) == null) { synchronized (IAMPolicyGrpc.class) { if ((getSetIamPolicyMethod = IAMPolicyGrpc.getSetIamPolicyMethod) == null) { - IAMPolicyGrpc.getSetIamPolicyMethod = getSetIamPolicyMethod = - io.grpc.MethodDescriptor.newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName(generateFullMethodName( - "google.iam.v1.IAMPolicy", "SetIamPolicy")) - .setSampledToLocalTracing(true) - .setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - SetIamPolicyRequest.getDefaultInstance())) - .setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - Policy.getDefaultInstance())) - .setSchemaDescriptor(new IAMPolicyMethodDescriptorSupplier("SetIamPolicy")) - .build(); - } + IAMPolicyGrpc.getSetIamPolicyMethod = + getSetIamPolicyMethod = + io.grpc.MethodDescriptor + .newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "SetIamPolicy")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.iam.v1.SetIamPolicyRequest.getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.iam.v1.Policy.getDefaultInstance())) + .setSchemaDescriptor(new IAMPolicyMethodDescriptorSupplier("SetIamPolicy")) + .build(); } - } - return getSetIamPolicyMethod; - } - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - @Deprecated // Use {@link #getGetIamPolicyMethod()} instead. - public static final io.grpc.MethodDescriptor METHOD_GET_IAM_POLICY = getGetIamPolicyMethodHelper(); - - private static volatile io.grpc.MethodDescriptor getGetIamPolicyMethod; - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - public static io.grpc.MethodDescriptor getGetIamPolicyMethod() { - return getGetIamPolicyMethodHelper(); + } + } + return getSetIamPolicyMethod; } - private static io.grpc.MethodDescriptor getGetIamPolicyMethodHelper() { - io.grpc.MethodDescriptor getGetIamPolicyMethod; + private static volatile io.grpc.MethodDescriptor< + com.google.iam.v1.GetIamPolicyRequest, com.google.iam.v1.Policy> + getGetIamPolicyMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "GetIamPolicy", + requestType = com.google.iam.v1.GetIamPolicyRequest.class, + responseType = com.google.iam.v1.Policy.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.iam.v1.GetIamPolicyRequest, com.google.iam.v1.Policy> + getGetIamPolicyMethod() { + io.grpc.MethodDescriptor + getGetIamPolicyMethod; if ((getGetIamPolicyMethod = IAMPolicyGrpc.getGetIamPolicyMethod) == null) { synchronized (IAMPolicyGrpc.class) { if ((getGetIamPolicyMethod = IAMPolicyGrpc.getGetIamPolicyMethod) == null) { - IAMPolicyGrpc.getGetIamPolicyMethod = getGetIamPolicyMethod = - io.grpc.MethodDescriptor.newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName(generateFullMethodName( - "google.iam.v1.IAMPolicy", "GetIamPolicy")) - .setSampledToLocalTracing(true) - .setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - GetIamPolicyRequest.getDefaultInstance())) - .setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - Policy.getDefaultInstance())) - .setSchemaDescriptor(new IAMPolicyMethodDescriptorSupplier("GetIamPolicy")) - .build(); - } + IAMPolicyGrpc.getGetIamPolicyMethod = + getGetIamPolicyMethod = + io.grpc.MethodDescriptor + .newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "GetIamPolicy")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.iam.v1.GetIamPolicyRequest.getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.iam.v1.Policy.getDefaultInstance())) + .setSchemaDescriptor(new IAMPolicyMethodDescriptorSupplier("GetIamPolicy")) + .build(); } - } - return getGetIamPolicyMethod; - } - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - @Deprecated // Use {@link #getTestIamPermissionsMethod()} instead. - public static final io.grpc.MethodDescriptor METHOD_TEST_IAM_PERMISSIONS = getTestIamPermissionsMethodHelper(); - - private static volatile io.grpc.MethodDescriptor getTestIamPermissionsMethod; - - @io.grpc.ExperimentalApi("https://github.com/grpc/grpc-java/issues/1901") - public static io.grpc.MethodDescriptor getTestIamPermissionsMethod() { - return getTestIamPermissionsMethodHelper(); + } + } + return getGetIamPolicyMethod; } - private static io.grpc.MethodDescriptor getTestIamPermissionsMethodHelper() { - io.grpc.MethodDescriptor getTestIamPermissionsMethod; + private static volatile io.grpc.MethodDescriptor< + com.google.iam.v1.TestIamPermissionsRequest, com.google.iam.v1.TestIamPermissionsResponse> + getTestIamPermissionsMethod; + + @io.grpc.stub.annotations.RpcMethod( + fullMethodName = SERVICE_NAME + '/' + "TestIamPermissions", + requestType = com.google.iam.v1.TestIamPermissionsRequest.class, + responseType = com.google.iam.v1.TestIamPermissionsResponse.class, + methodType = io.grpc.MethodDescriptor.MethodType.UNARY) + public static io.grpc.MethodDescriptor< + com.google.iam.v1.TestIamPermissionsRequest, com.google.iam.v1.TestIamPermissionsResponse> + getTestIamPermissionsMethod() { + io.grpc.MethodDescriptor< + com.google.iam.v1.TestIamPermissionsRequest, + com.google.iam.v1.TestIamPermissionsResponse> + getTestIamPermissionsMethod; if ((getTestIamPermissionsMethod = IAMPolicyGrpc.getTestIamPermissionsMethod) == null) { synchronized (IAMPolicyGrpc.class) { if ((getTestIamPermissionsMethod = IAMPolicyGrpc.getTestIamPermissionsMethod) == null) { - IAMPolicyGrpc.getTestIamPermissionsMethod = getTestIamPermissionsMethod = - io.grpc.MethodDescriptor.newBuilder() - .setType(io.grpc.MethodDescriptor.MethodType.UNARY) - .setFullMethodName(generateFullMethodName( - "google.iam.v1.IAMPolicy", "TestIamPermissions")) - .setSampledToLocalTracing(true) - .setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - TestIamPermissionsRequest.getDefaultInstance())) - .setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( - TestIamPermissionsResponse.getDefaultInstance())) - .setSchemaDescriptor(new IAMPolicyMethodDescriptorSupplier("TestIamPermissions")) - .build(); - } + IAMPolicyGrpc.getTestIamPermissionsMethod = + getTestIamPermissionsMethod = + io.grpc.MethodDescriptor + . + newBuilder() + .setType(io.grpc.MethodDescriptor.MethodType.UNARY) + .setFullMethodName(generateFullMethodName(SERVICE_NAME, "TestIamPermissions")) + .setSampledToLocalTracing(true) + .setRequestMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.iam.v1.TestIamPermissionsRequest.getDefaultInstance())) + .setResponseMarshaller( + io.grpc.protobuf.ProtoUtils.marshaller( + com.google.iam.v1.TestIamPermissionsResponse.getDefaultInstance())) + .setSchemaDescriptor( + new IAMPolicyMethodDescriptorSupplier("TestIamPermissions")) + .build(); } - } - return getTestIamPermissionsMethod; + } + } + return getTestIamPermissionsMethod; } - /** - * Creates a new async stub that supports all call types for the service - */ + /** Creates a new async stub that supports all call types for the service */ public static IAMPolicyStub newStub(io.grpc.Channel channel) { - return new IAMPolicyStub(channel); + io.grpc.stub.AbstractStub.StubFactory factory = + new io.grpc.stub.AbstractStub.StubFactory() { + @java.lang.Override + public IAMPolicyStub newStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new IAMPolicyStub(channel, callOptions); + } + }; + return IAMPolicyStub.newStub(factory, channel); } /** * Creates a new blocking-style stub that supports unary and streaming output calls on the service */ - public static IAMPolicyBlockingStub newBlockingStub( - io.grpc.Channel channel) { - return new IAMPolicyBlockingStub(channel); + public static IAMPolicyBlockingStub newBlockingStub(io.grpc.Channel channel) { + io.grpc.stub.AbstractStub.StubFactory factory = + new io.grpc.stub.AbstractStub.StubFactory() { + @java.lang.Override + public IAMPolicyBlockingStub newStub( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new IAMPolicyBlockingStub(channel, callOptions); + } + }; + return IAMPolicyBlockingStub.newStub(factory, channel); } - /** - * Creates a new ListenableFuture-style stub that supports unary calls on the service - */ - public static IAMPolicyFutureStub newFutureStub( - io.grpc.Channel channel) { - return new IAMPolicyFutureStub(channel); + /** Creates a new ListenableFuture-style stub that supports unary calls on the service */ + public static IAMPolicyFutureStub newFutureStub(io.grpc.Channel channel) { + io.grpc.stub.AbstractStub.StubFactory factory = + new io.grpc.stub.AbstractStub.StubFactory() { + @java.lang.Override + public IAMPolicyFutureStub newStub( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { + return new IAMPolicyFutureStub(channel, callOptions); + } + }; + return IAMPolicyFutureStub.newStub(factory, channel); } /** + * + * *
    * ## API Overview
    * Manages Identity and Access Management (IAM) policies.
@@ -204,32 +239,40 @@ public static IAMPolicyFutureStub newFutureStub(
    * attached.
    * 
*/ - public static abstract class IAMPolicyImplBase implements io.grpc.BindableService { + public abstract static class IAMPolicyImplBase implements io.grpc.BindableService { /** + * + * *
      * Sets the access control policy on the specified resource. Replaces any
      * existing policy.
      * 
*/ - public void setIamPolicy(SetIamPolicyRequest request, - io.grpc.stub.StreamObserver responseObserver) { - asyncUnimplementedUnaryCall(getSetIamPolicyMethodHelper(), responseObserver); + public void setIamPolicy( + com.google.iam.v1.SetIamPolicyRequest request, + io.grpc.stub.StreamObserver responseObserver) { + asyncUnimplementedUnaryCall(getSetIamPolicyMethod(), responseObserver); } /** + * + * *
      * Gets the access control policy for a resource.
      * Returns an empty policy if the resource exists and does not have a policy
      * set.
      * 
*/ - public void getIamPolicy(GetIamPolicyRequest request, - io.grpc.stub.StreamObserver responseObserver) { - asyncUnimplementedUnaryCall(getGetIamPolicyMethodHelper(), responseObserver); + public void getIamPolicy( + com.google.iam.v1.GetIamPolicyRequest request, + io.grpc.stub.StreamObserver responseObserver) { + asyncUnimplementedUnaryCall(getGetIamPolicyMethod(), responseObserver); } /** + * + * *
      * Returns permissions that a caller has on the specified resource.
      * If the resource does not exist, this will return an empty set of
@@ -239,39 +282,42 @@ public void getIamPolicy(GetIamPolicyRequest request,
      * may "fail open" without warning.
      * 
*/ - public void testIamPermissions(TestIamPermissionsRequest request, - io.grpc.stub.StreamObserver responseObserver) { - asyncUnimplementedUnaryCall(getTestIamPermissionsMethodHelper(), responseObserver); + public void testIamPermissions( + com.google.iam.v1.TestIamPermissionsRequest request, + io.grpc.stub.StreamObserver + responseObserver) { + asyncUnimplementedUnaryCall(getTestIamPermissionsMethod(), responseObserver); } - @Override public final io.grpc.ServerServiceDefinition bindService() { + @java.lang.Override + public final io.grpc.ServerServiceDefinition bindService() { return io.grpc.ServerServiceDefinition.builder(getServiceDescriptor()) .addMethod( - getSetIamPolicyMethodHelper(), - asyncUnaryCall( - new MethodHandlers< - SetIamPolicyRequest, - Policy>( - this, METHODID_SET_IAM_POLICY))) + getSetIamPolicyMethod(), + asyncUnaryCall( + new MethodHandlers< + com.google.iam.v1.SetIamPolicyRequest, com.google.iam.v1.Policy>( + this, METHODID_SET_IAM_POLICY))) .addMethod( - getGetIamPolicyMethodHelper(), - asyncUnaryCall( - new MethodHandlers< - GetIamPolicyRequest, - Policy>( - this, METHODID_GET_IAM_POLICY))) + getGetIamPolicyMethod(), + asyncUnaryCall( + new MethodHandlers< + com.google.iam.v1.GetIamPolicyRequest, com.google.iam.v1.Policy>( + this, METHODID_GET_IAM_POLICY))) .addMethod( - getTestIamPermissionsMethodHelper(), - asyncUnaryCall( - new MethodHandlers< - TestIamPermissionsRequest, - TestIamPermissionsResponse>( - this, METHODID_TEST_IAM_PERMISSIONS))) + getTestIamPermissionsMethod(), + asyncUnaryCall( + new MethodHandlers< + com.google.iam.v1.TestIamPermissionsRequest, + com.google.iam.v1.TestIamPermissionsResponse>( + this, METHODID_TEST_IAM_PERMISSIONS))) .build(); } } /** + * + * *
    * ## API Overview
    * Manages Identity and Access Management (IAM) policies.
@@ -293,48 +339,54 @@ public void testIamPermissions(TestIamPermissionsRequest request,
    * attached.
    * 
*/ - public static final class IAMPolicyStub extends io.grpc.stub.AbstractStub { - private IAMPolicyStub(io.grpc.Channel channel) { - super(channel); - } - - private IAMPolicyStub(io.grpc.Channel channel, - io.grpc.CallOptions callOptions) { + public static final class IAMPolicyStub extends io.grpc.stub.AbstractAsyncStub { + private IAMPolicyStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { super(channel, callOptions); } - @Override - protected IAMPolicyStub build(io.grpc.Channel channel, - io.grpc.CallOptions callOptions) { + @java.lang.Override + protected IAMPolicyStub build(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { return new IAMPolicyStub(channel, callOptions); } /** + * + * *
      * Sets the access control policy on the specified resource. Replaces any
      * existing policy.
      * 
*/ - public void setIamPolicy(SetIamPolicyRequest request, - io.grpc.stub.StreamObserver responseObserver) { + public void setIamPolicy( + com.google.iam.v1.SetIamPolicyRequest request, + io.grpc.stub.StreamObserver responseObserver) { asyncUnaryCall( - getChannel().newCall(getSetIamPolicyMethodHelper(), getCallOptions()), request, responseObserver); + getChannel().newCall(getSetIamPolicyMethod(), getCallOptions()), + request, + responseObserver); } /** + * + * *
      * Gets the access control policy for a resource.
      * Returns an empty policy if the resource exists and does not have a policy
      * set.
      * 
*/ - public void getIamPolicy(GetIamPolicyRequest request, - io.grpc.stub.StreamObserver responseObserver) { + public void getIamPolicy( + com.google.iam.v1.GetIamPolicyRequest request, + io.grpc.stub.StreamObserver responseObserver) { asyncUnaryCall( - getChannel().newCall(getGetIamPolicyMethodHelper(), getCallOptions()), request, responseObserver); + getChannel().newCall(getGetIamPolicyMethod(), getCallOptions()), + request, + responseObserver); } /** + * + * *
      * Returns permissions that a caller has on the specified resource.
      * If the resource does not exist, this will return an empty set of
@@ -344,14 +396,20 @@ public void getIamPolicy(GetIamPolicyRequest request,
      * may "fail open" without warning.
      * 
*/ - public void testIamPermissions(TestIamPermissionsRequest request, - io.grpc.stub.StreamObserver responseObserver) { + public void testIamPermissions( + com.google.iam.v1.TestIamPermissionsRequest request, + io.grpc.stub.StreamObserver + responseObserver) { asyncUnaryCall( - getChannel().newCall(getTestIamPermissionsMethodHelper(), getCallOptions()), request, responseObserver); + getChannel().newCall(getTestIamPermissionsMethod(), getCallOptions()), + request, + responseObserver); } } /** + * + * *
    * ## API Overview
    * Manages Identity and Access Management (IAM) policies.
@@ -373,46 +431,46 @@ public void testIamPermissions(TestIamPermissionsRequest request,
    * attached.
    * 
*/ - public static final class IAMPolicyBlockingStub extends io.grpc.stub.AbstractStub { - private IAMPolicyBlockingStub(io.grpc.Channel channel) { - super(channel); - } - - private IAMPolicyBlockingStub(io.grpc.Channel channel, - io.grpc.CallOptions callOptions) { + public static final class IAMPolicyBlockingStub + extends io.grpc.stub.AbstractBlockingStub { + private IAMPolicyBlockingStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { super(channel, callOptions); } - @Override - protected IAMPolicyBlockingStub build(io.grpc.Channel channel, - io.grpc.CallOptions callOptions) { + @java.lang.Override + protected IAMPolicyBlockingStub build( + io.grpc.Channel channel, io.grpc.CallOptions callOptions) { return new IAMPolicyBlockingStub(channel, callOptions); } /** + * + * *
      * Sets the access control policy on the specified resource. Replaces any
      * existing policy.
      * 
*/ - public Policy setIamPolicy(SetIamPolicyRequest request) { - return blockingUnaryCall( - getChannel(), getSetIamPolicyMethodHelper(), getCallOptions(), request); + public com.google.iam.v1.Policy setIamPolicy(com.google.iam.v1.SetIamPolicyRequest request) { + return blockingUnaryCall(getChannel(), getSetIamPolicyMethod(), getCallOptions(), request); } /** + * + * *
      * Gets the access control policy for a resource.
      * Returns an empty policy if the resource exists and does not have a policy
      * set.
      * 
*/ - public Policy getIamPolicy(GetIamPolicyRequest request) { - return blockingUnaryCall( - getChannel(), getGetIamPolicyMethodHelper(), getCallOptions(), request); + public com.google.iam.v1.Policy getIamPolicy(com.google.iam.v1.GetIamPolicyRequest request) { + return blockingUnaryCall(getChannel(), getGetIamPolicyMethod(), getCallOptions(), request); } /** + * + * *
      * Returns permissions that a caller has on the specified resource.
      * If the resource does not exist, this will return an empty set of
@@ -422,13 +480,16 @@ public Policy getIamPolicy(GetIamPolicyRequest request) {
      * may "fail open" without warning.
      * 
*/ - public TestIamPermissionsResponse testIamPermissions(TestIamPermissionsRequest request) { + public com.google.iam.v1.TestIamPermissionsResponse testIamPermissions( + com.google.iam.v1.TestIamPermissionsRequest request) { return blockingUnaryCall( - getChannel(), getTestIamPermissionsMethodHelper(), getCallOptions(), request); + getChannel(), getTestIamPermissionsMethod(), getCallOptions(), request); } } /** + * + * *
    * ## API Overview
    * Manages Identity and Access Management (IAM) policies.
@@ -450,48 +511,49 @@ public TestIamPermissionsResponse testIamPermissions(TestIamPermissionsRequest r
    * attached.
    * 
*/ - public static final class IAMPolicyFutureStub extends io.grpc.stub.AbstractStub { - private IAMPolicyFutureStub(io.grpc.Channel channel) { - super(channel); - } - - private IAMPolicyFutureStub(io.grpc.Channel channel, - io.grpc.CallOptions callOptions) { + public static final class IAMPolicyFutureStub + extends io.grpc.stub.AbstractFutureStub { + private IAMPolicyFutureStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { super(channel, callOptions); } - @Override - protected IAMPolicyFutureStub build(io.grpc.Channel channel, - io.grpc.CallOptions callOptions) { + @java.lang.Override + protected IAMPolicyFutureStub build(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { return new IAMPolicyFutureStub(channel, callOptions); } /** + * + * *
      * Sets the access control policy on the specified resource. Replaces any
      * existing policy.
      * 
*/ - public com.google.common.util.concurrent.ListenableFuture setIamPolicy( - SetIamPolicyRequest request) { + public com.google.common.util.concurrent.ListenableFuture + setIamPolicy(com.google.iam.v1.SetIamPolicyRequest request) { return futureUnaryCall( - getChannel().newCall(getSetIamPolicyMethodHelper(), getCallOptions()), request); + getChannel().newCall(getSetIamPolicyMethod(), getCallOptions()), request); } /** + * + * *
      * Gets the access control policy for a resource.
      * Returns an empty policy if the resource exists and does not have a policy
      * set.
      * 
*/ - public com.google.common.util.concurrent.ListenableFuture getIamPolicy( - GetIamPolicyRequest request) { + public com.google.common.util.concurrent.ListenableFuture + getIamPolicy(com.google.iam.v1.GetIamPolicyRequest request) { return futureUnaryCall( - getChannel().newCall(getGetIamPolicyMethodHelper(), getCallOptions()), request); + getChannel().newCall(getGetIamPolicyMethod(), getCallOptions()), request); } /** + * + * *
      * Returns permissions that a caller has on the specified resource.
      * If the resource does not exist, this will return an empty set of
@@ -501,10 +563,11 @@ public com.google.common.util.concurrent.ListenableFuture getIamPolicy(
      * may "fail open" without warning.
      * 
*/ - public com.google.common.util.concurrent.ListenableFuture testIamPermissions( - TestIamPermissionsRequest request) { + public com.google.common.util.concurrent.ListenableFuture< + com.google.iam.v1.TestIamPermissionsResponse> + testIamPermissions(com.google.iam.v1.TestIamPermissionsRequest request) { return futureUnaryCall( - getChannel().newCall(getTestIamPermissionsMethodHelper(), getCallOptions()), request); + getChannel().newCall(getTestIamPermissionsMethod(), getCallOptions()), request); } } @@ -512,11 +575,11 @@ public com.google.common.util.concurrent.ListenableFuture implements - io.grpc.stub.ServerCalls.UnaryMethod, - io.grpc.stub.ServerCalls.ServerStreamingMethod, - io.grpc.stub.ServerCalls.ClientStreamingMethod, - io.grpc.stub.ServerCalls.BidiStreamingMethod { + 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 IAMPolicyImplBase serviceImpl; private final int methodId; @@ -525,29 +588,33 @@ private static final class MethodHandlers implements this.methodId = methodId; } - @Override - @SuppressWarnings("unchecked") + @java.lang.Override + @java.lang.SuppressWarnings("unchecked") public void invoke(Req request, io.grpc.stub.StreamObserver responseObserver) { switch (methodId) { case METHODID_SET_IAM_POLICY: - serviceImpl.setIamPolicy((SetIamPolicyRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); + serviceImpl.setIamPolicy( + (com.google.iam.v1.SetIamPolicyRequest) request, + (io.grpc.stub.StreamObserver) responseObserver); break; case METHODID_GET_IAM_POLICY: - serviceImpl.getIamPolicy((GetIamPolicyRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); + serviceImpl.getIamPolicy( + (com.google.iam.v1.GetIamPolicyRequest) request, + (io.grpc.stub.StreamObserver) responseObserver); break; case METHODID_TEST_IAM_PERMISSIONS: - serviceImpl.testIamPermissions((TestIamPermissionsRequest) request, - (io.grpc.stub.StreamObserver) responseObserver); + serviceImpl.testIamPermissions( + (com.google.iam.v1.TestIamPermissionsRequest) request, + (io.grpc.stub.StreamObserver) + responseObserver); break; default: throw new AssertionError(); } } - @Override - @SuppressWarnings("unchecked") + @java.lang.Override + @java.lang.SuppressWarnings("unchecked") public io.grpc.stub.StreamObserver invoke( io.grpc.stub.StreamObserver responseObserver) { switch (methodId) { @@ -557,16 +624,17 @@ public io.grpc.stub.StreamObserver invoke( } } - private static abstract class IAMPolicyBaseDescriptorSupplier - implements io.grpc.protobuf.ProtoFileDescriptorSupplier, io.grpc.protobuf.ProtoServiceDescriptorSupplier { + private abstract static class IAMPolicyBaseDescriptorSupplier + implements io.grpc.protobuf.ProtoFileDescriptorSupplier, + io.grpc.protobuf.ProtoServiceDescriptorSupplier { IAMPolicyBaseDescriptorSupplier() {} - @Override + @java.lang.Override public com.google.protobuf.Descriptors.FileDescriptor getFileDescriptor() { - return IamPolicyProto.getDescriptor(); + return com.google.iam.v1.IamPolicyProto.getDescriptor(); } - @Override + @java.lang.Override public com.google.protobuf.Descriptors.ServiceDescriptor getServiceDescriptor() { return getFileDescriptor().findServiceByName("IAMPolicy"); } @@ -586,7 +654,7 @@ private static final class IAMPolicyMethodDescriptorSupplier this.methodName = methodName; } - @Override + @java.lang.Override public com.google.protobuf.Descriptors.MethodDescriptor getMethodDescriptor() { return getServiceDescriptor().findMethodByName(methodName); } @@ -600,12 +668,14 @@ public static io.grpc.ServiceDescriptor getServiceDescriptor() { synchronized (IAMPolicyGrpc.class) { result = serviceDescriptor; if (result == null) { - serviceDescriptor = result = io.grpc.ServiceDescriptor.newBuilder(SERVICE_NAME) - .setSchemaDescriptor(new IAMPolicyFileDescriptorSupplier()) - .addMethod(getSetIamPolicyMethodHelper()) - .addMethod(getGetIamPolicyMethodHelper()) - .addMethod(getTestIamPermissionsMethodHelper()) - .build(); + serviceDescriptor = + result = + io.grpc.ServiceDescriptor.newBuilder(SERVICE_NAME) + .setSchemaDescriptor(new IAMPolicyFileDescriptorSupplier()) + .addMethod(getSetIamPolicyMethod()) + .addMethod(getGetIamPolicyMethod()) + .addMethod(getTestIamPermissionsMethod()) + .build(); } } } diff --git a/java.header b/java.header new file mode 100644 index 00000000..3a9b503a --- /dev/null +++ b/java.header @@ -0,0 +1,15 @@ +^/\*$ +^ \* Copyright \d\d\d\d,? Google (Inc\.|LLC)( All [rR]ights [rR]eserved\.)?$ +^ \*$ +^ \* 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 new file mode 100644 index 00000000..6597fced --- /dev/null +++ b/license-checks.xml @@ -0,0 +1,10 @@ + + + + + + + + diff --git a/pom.xml b/pom.xml new file mode 100644 index 00000000..bf23f4f1 --- /dev/null +++ b/pom.xml @@ -0,0 +1,188 @@ + + + 4.0.0 + com.google.cloud + google-iam-parent + pom + 0.13.1-SNAPSHOT + Google IAM Parent + https://github.com/googleapis/java-iam + + Java idiomatic client for Google Cloud Platform services. + + + + com.google.cloud + google-cloud-shared-config + 0.5.0 + + + + + chingor + Jeff Ching + chingor@google.com + Google + + Developer + + + + + Google LLC + + + scm:git:git@github.com:googleapis/java-iam.git + scm:git:git@github.com:googleapis/java-iam.git + https://github.com/googleapis/java-iam + HEAD + + + https://github.com/googleapis/java-iam/issues + GitHub Issues + + + + sonatype-nexus-snapshots + https://oss.sonatype.org/content/repositories/snapshots + + + sonatype-nexus-staging + https://oss.sonatype.org/service/local/staging/deploy/maven2/ + + + + + Apache-2.0 + https://www.apache.org/licenses/LICENSE-2.0.txt + + + + + UTF-8 + UTF-8 + github + google-iam-parent + 1.17.0 + 3.11.4 + 4.13 + 1.29.0 + 29.0-android + + + + + + com.google.protobuf + protobuf-bom + ${protobuf.version} + pom + import + + + io.grpc + grpc-bom + ${grpc.version} + pom + import + + + com.google.api.grpc + proto-google-common-protos + ${google.common-protos.version} + + + com.google.guava + guava + ${guava.version} + + + com.google.api.grpc + proto-google-iam-v1 + 0.13.1-SNAPSHOT + + + + junit + junit + ${junit.version} + test + + + + + + proto-google-iam-v1 + grpc-google-iam-v1 + + + + + + org.apache.maven.plugins + maven-project-info-reports-plugin + 3.0.0 + + + + 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.2.0 + + + 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/${google.api-common.version}/apidocs/ + + + + + + diff --git a/proto-google-iam-v1/pom.xml b/proto-google-iam-v1/pom.xml new file mode 100644 index 00000000..1a9506c8 --- /dev/null +++ b/proto-google-iam-v1/pom.xml @@ -0,0 +1,34 @@ + + 4.0.0 + com.google.api.grpc + proto-google-iam-v1 + 0.13.1-SNAPSHOT + proto-google-iam-v1 + PROTO library for proto-google-iam-v1 + + com.google.cloud + google-iam-parent + 0.13.1-SNAPSHOT + + + + com.google.protobuf + protobuf-java + + + com.google.api.grpc + proto-google-common-protos + + + + + + + org.codehaus.mojo + flatten-maven-plugin + + + + \ No newline at end of file diff --git a/proto-google-iam-v1/src/main/java/com/google/iam/v1/AuditConfigDelta.java b/proto-google-iam-v1/src/main/java/com/google/iam/v1/AuditConfigDelta.java index 63cb54df..ad57814b 100644 --- a/proto-google-iam-v1/src/main/java/com/google/iam/v1/AuditConfigDelta.java +++ b/proto-google-iam-v1/src/main/java/com/google/iam/v1/AuditConfigDelta.java @@ -1,9 +1,26 @@ +/* + * 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/iam/v1/policy.proto package com.google.iam.v1; /** + * + * *
  * One delta entry for AuditConfig. Each individual change (only one
  * exempted_member in each entry) to a AuditConfig will be a separate entry.
@@ -11,15 +28,16 @@
  *
  * Protobuf type {@code google.iam.v1.AuditConfigDelta}
  */
-public  final class AuditConfigDelta extends
-    com.google.protobuf.GeneratedMessageV3 implements
+public final class AuditConfigDelta extends com.google.protobuf.GeneratedMessageV3
+    implements
     // @@protoc_insertion_point(message_implements:google.iam.v1.AuditConfigDelta)
     AuditConfigDeltaOrBuilder {
-private static final long serialVersionUID = 0L;
+  private static final long serialVersionUID = 0L;
   // Use AuditConfigDelta.newBuilder() to construct.
   private AuditConfigDelta(com.google.protobuf.GeneratedMessageV3.Builder builder) {
     super(builder);
   }
+
   private AuditConfigDelta() {
     action_ = 0;
     service_ = "";
@@ -27,20 +45,25 @@ private AuditConfigDelta() {
     logType_ = "";
   }
 
-  @Override
-  public final com.google.protobuf.UnknownFieldSet
-  getUnknownFields() {
+  @java.lang.Override
+  @SuppressWarnings({"unused"})
+  protected java.lang.Object newInstance(UnusedPrivateParameter unused) {
+    return new AuditConfigDelta();
+  }
+
+  @java.lang.Override
+  public final com.google.protobuf.UnknownFieldSet getUnknownFields() {
     return this.unknownFields;
   }
+
   private AuditConfigDelta(
       com.google.protobuf.CodedInputStream input,
       com.google.protobuf.ExtensionRegistryLite extensionRegistry)
       throws com.google.protobuf.InvalidProtocolBufferException {
     this();
     if (extensionRegistry == null) {
-      throw new NullPointerException();
+      throw new java.lang.NullPointerException();
     }
-    int mutable_bitField0_ = 0;
     com.google.protobuf.UnknownFieldSet.Builder unknownFields =
         com.google.protobuf.UnknownFieldSet.newBuilder();
     try {
@@ -51,72 +74,80 @@ private AuditConfigDelta(
           case 0:
             done = true;
             break;
-          case 8: {
-            int rawValue = input.readEnum();
+          case 8:
+            {
+              int rawValue = input.readEnum();
 
-            action_ = rawValue;
-            break;
-          }
-          case 18: {
-            String s = input.readStringRequireUtf8();
+              action_ = rawValue;
+              break;
+            }
+          case 18:
+            {
+              java.lang.String s = input.readStringRequireUtf8();
 
-            service_ = s;
-            break;
-          }
-          case 26: {
-            String s = input.readStringRequireUtf8();
+              service_ = s;
+              break;
+            }
+          case 26:
+            {
+              java.lang.String s = input.readStringRequireUtf8();
 
-            exemptedMember_ = s;
-            break;
-          }
-          case 34: {
-            String s = input.readStringRequireUtf8();
+              exemptedMember_ = s;
+              break;
+            }
+          case 34:
+            {
+              java.lang.String s = input.readStringRequireUtf8();
 
-            logType_ = s;
-            break;
-          }
-          default: {
-            if (!parseUnknownField(
-                input, unknownFields, extensionRegistry, tag)) {
-              done = true;
+              logType_ = s;
+              break;
+            }
+          default:
+            {
+              if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) {
+                done = true;
+              }
+              break;
             }
-            break;
-          }
         }
       }
     } catch (com.google.protobuf.InvalidProtocolBufferException e) {
       throw e.setUnfinishedMessage(this);
     } catch (java.io.IOException e) {
-      throw new com.google.protobuf.InvalidProtocolBufferException(
-          e).setUnfinishedMessage(this);
+      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 PolicyProto.internal_static_google_iam_v1_AuditConfigDelta_descriptor;
+
+  public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() {
+    return com.google.iam.v1.PolicyProto.internal_static_google_iam_v1_AuditConfigDelta_descriptor;
   }
 
-  @Override
-  protected FieldAccessorTable
+  @java.lang.Override
+  protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
       internalGetFieldAccessorTable() {
-    return PolicyProto.internal_static_google_iam_v1_AuditConfigDelta_fieldAccessorTable
+    return com.google.iam.v1.PolicyProto
+        .internal_static_google_iam_v1_AuditConfigDelta_fieldAccessorTable
         .ensureFieldAccessorsInitialized(
-            AuditConfigDelta.class, Builder.class);
+            com.google.iam.v1.AuditConfigDelta.class,
+            com.google.iam.v1.AuditConfigDelta.Builder.class);
   }
 
   /**
+   *
+   *
    * 
    * The type of action performed on an audit configuration in a policy.
    * 
* * Protobuf enum {@code google.iam.v1.AuditConfigDelta.Action} */ - public enum Action - implements com.google.protobuf.ProtocolMessageEnum { + public enum Action implements com.google.protobuf.ProtocolMessageEnum { /** + * + * *
      * Unspecified.
      * 
@@ -125,6 +156,8 @@ public enum Action */ ACTION_UNSPECIFIED(0), /** + * + * *
      * Addition of an audit configuration.
      * 
@@ -133,6 +166,8 @@ public enum Action */ ADD(1), /** + * + * *
      * Removal of an audit configuration.
      * 
@@ -144,6 +179,8 @@ public enum Action ; /** + * + * *
      * Unspecified.
      * 
@@ -152,6 +189,8 @@ public enum Action */ public static final int ACTION_UNSPECIFIED_VALUE = 0; /** + * + * *
      * Addition of an audit configuration.
      * 
@@ -160,6 +199,8 @@ public enum Action */ public static final int ADD_VALUE = 1; /** + * + * *
      * Removal of an audit configuration.
      * 
@@ -168,64 +209,69 @@ public enum Action */ public static final int REMOVE_VALUE = 2; - public final int getNumber() { if (this == UNRECOGNIZED) { - throw new IllegalArgumentException( + 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. */ - @Deprecated + @java.lang.Deprecated public static Action 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 Action forNumber(int value) { switch (value) { - case 0: return ACTION_UNSPECIFIED; - case 1: return ADD; - case 2: return REMOVE; - default: return null; + case 0: + return ACTION_UNSPECIFIED; + case 1: + return ADD; + case 2: + return REMOVE; + default: + return null; } } - public static com.google.protobuf.Internal.EnumLiteMap - internalGetValueMap() { + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { return internalValueMap; } - private static final com.google.protobuf.Internal.EnumLiteMap< - Action> internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public Action findValueByNumber(int number) { - return Action.forNumber(number); - } - }; - public final com.google.protobuf.Descriptors.EnumValueDescriptor - getValueDescriptor() { + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public Action findValueByNumber(int number) { + return Action.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { return getDescriptor().getValues().get(ordinal()); } - public final com.google.protobuf.Descriptors.EnumDescriptor - getDescriptorForType() { + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { return getDescriptor(); } - public static final com.google.protobuf.Descriptors.EnumDescriptor - getDescriptor() { - return AuditConfigDelta.getDescriptor().getEnumTypes().get(0); + + public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.iam.v1.AuditConfigDelta.getDescriptor().getEnumTypes().get(0); } private static final Action[] VALUES = values(); - public static Action valueOf( - com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + public static Action valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { if (desc.getType() != getDescriptor()) { - throw new IllegalArgumentException( - "EnumValueDescriptor is not for this type."); + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); } if (desc.getIndex() == -1) { return UNRECOGNIZED; @@ -245,33 +291,44 @@ private Action(int value) { public static final int ACTION_FIELD_NUMBER = 1; private int action_; /** + * + * *
    * The action that was performed on an audit configuration in a policy.
    * Required
    * 
* * .google.iam.v1.AuditConfigDelta.Action action = 1; + * + * @return The enum numeric value on the wire for action. */ public int getActionValue() { return action_; } /** + * + * *
    * The action that was performed on an audit configuration in a policy.
    * Required
    * 
* * .google.iam.v1.AuditConfigDelta.Action action = 1; + * + * @return The action. */ - public Action getAction() { + public com.google.iam.v1.AuditConfigDelta.Action getAction() { @SuppressWarnings("deprecation") - Action result = Action.valueOf(action_); - return result == null ? Action.UNRECOGNIZED : result; + com.google.iam.v1.AuditConfigDelta.Action result = + com.google.iam.v1.AuditConfigDelta.Action.valueOf(action_); + return result == null ? com.google.iam.v1.AuditConfigDelta.Action.UNRECOGNIZED : result; } public static final int SERVICE_FIELD_NUMBER = 2; - private volatile Object service_; + private volatile java.lang.Object service_; /** + * + * *
    * Specifies a service that was configured for Cloud Audit Logging.
    * For example, `storage.googleapis.com`, `cloudsql.googleapis.com`.
@@ -280,20 +337,23 @@ public Action getAction() {
    * 
* * string service = 2; + * + * @return The service. */ - public String getService() { - Object ref = service_; - if (ref instanceof String) { - return (String) ref; + public java.lang.String getService() { + java.lang.Object ref = service_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - String s = bs.toStringUtf8(); + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); service_ = s; return s; } } /** + * + * *
    * Specifies a service that was configured for Cloud Audit Logging.
    * For example, `storage.googleapis.com`, `cloudsql.googleapis.com`.
@@ -302,14 +362,14 @@ public String getService() {
    * 
* * string service = 2; + * + * @return The bytes for service. */ - public com.google.protobuf.ByteString - getServiceBytes() { - Object ref = service_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (String) ref); + public com.google.protobuf.ByteString getServiceBytes() { + java.lang.Object ref = service_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); service_ = b; return b; } else { @@ -318,8 +378,10 @@ public String getService() { } public static final int EXEMPTED_MEMBER_FIELD_NUMBER = 3; - private volatile Object exemptedMember_; + private volatile java.lang.Object exemptedMember_; /** + * + * *
    * A single identity that is exempted from "data access" audit
    * logging for the `service` specified above.
@@ -327,20 +389,23 @@ public String getService() {
    * 
* * string exempted_member = 3; + * + * @return The exemptedMember. */ - public String getExemptedMember() { - Object ref = exemptedMember_; - if (ref instanceof String) { - return (String) ref; + public java.lang.String getExemptedMember() { + java.lang.Object ref = exemptedMember_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - String s = bs.toStringUtf8(); + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); exemptedMember_ = s; return s; } } /** + * + * *
    * A single identity that is exempted from "data access" audit
    * logging for the `service` specified above.
@@ -348,14 +413,14 @@ public String getExemptedMember() {
    * 
* * string exempted_member = 3; + * + * @return The bytes for exemptedMember. */ - public com.google.protobuf.ByteString - getExemptedMemberBytes() { - Object ref = exemptedMember_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (String) ref); + public com.google.protobuf.ByteString getExemptedMemberBytes() { + java.lang.Object ref = exemptedMember_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); exemptedMember_ = b; return b; } else { @@ -364,8 +429,10 @@ public String getExemptedMember() { } public static final int LOG_TYPE_FIELD_NUMBER = 4; - private volatile Object logType_; + private volatile java.lang.Object logType_; /** + * + * *
    * Specifies the log_type that was be enabled. ADMIN_ACTIVITY is always
    * enabled, and cannot be configured.
@@ -373,20 +440,23 @@ public String getExemptedMember() {
    * 
* * string log_type = 4; + * + * @return The logType. */ - public String getLogType() { - Object ref = logType_; - if (ref instanceof String) { - return (String) ref; + public java.lang.String getLogType() { + java.lang.Object ref = logType_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - String s = bs.toStringUtf8(); + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); logType_ = s; return s; } } /** + * + * *
    * Specifies the log_type that was be enabled. ADMIN_ACTIVITY is always
    * enabled, and cannot be configured.
@@ -394,14 +464,14 @@ public String getLogType() {
    * 
* * string log_type = 4; + * + * @return The bytes for logType. */ - public com.google.protobuf.ByteString - getLogTypeBytes() { - Object ref = logType_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (String) ref); + public com.google.protobuf.ByteString getLogTypeBytes() { + java.lang.Object ref = logType_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); logType_ = b; return b; } else { @@ -410,7 +480,8 @@ public String getLogType() { } private byte memoizedIsInitialized = -1; - @Override + + @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; if (isInitialized == 1) return true; @@ -420,10 +491,9 @@ public final boolean isInitialized() { return true; } - @Override - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (action_ != Action.ACTION_UNSPECIFIED.getNumber()) { + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (action_ != com.google.iam.v1.AuditConfigDelta.Action.ACTION_UNSPECIFIED.getNumber()) { output.writeEnum(1, action_); } if (!getServiceBytes().isEmpty()) { @@ -438,15 +508,14 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) unknownFields.writeTo(output); } - @Override + @java.lang.Override public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; - if (action_ != Action.ACTION_UNSPECIFIED.getNumber()) { - size += com.google.protobuf.CodedOutputStream - .computeEnumSize(1, action_); + if (action_ != com.google.iam.v1.AuditConfigDelta.Action.ACTION_UNSPECIFIED.getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, action_); } if (!getServiceBytes().isEmpty()) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, service_); @@ -462,28 +531,25 @@ public int getSerializedSize() { return size; } - @Override - public boolean equals(final Object obj) { + @java.lang.Override + public boolean equals(final java.lang.Object obj) { if (obj == this) { - return true; + return true; } - if (!(obj instanceof AuditConfigDelta)) { + if (!(obj instanceof com.google.iam.v1.AuditConfigDelta)) { return super.equals(obj); } - AuditConfigDelta other = (AuditConfigDelta) obj; + com.google.iam.v1.AuditConfigDelta other = (com.google.iam.v1.AuditConfigDelta) obj; if (action_ != other.action_) return false; - if (!getService() - .equals(other.getService())) return false; - if (!getExemptedMember() - .equals(other.getExemptedMember())) return false; - if (!getLogType() - .equals(other.getLogType())) return false; + if (!getService().equals(other.getService())) return false; + if (!getExemptedMember().equals(other.getExemptedMember())) return false; + if (!getLogType().equals(other.getLogType())) return false; if (!unknownFields.equals(other.unknownFields)) return false; return true; } - @Override + @java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; @@ -503,97 +569,103 @@ public int hashCode() { return hash; } - public static AuditConfigDelta parseFrom( - java.nio.ByteBuffer data) + public static com.google.iam.v1.AuditConfigDelta parseFrom(java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } - public static AuditConfigDelta parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + + public static com.google.iam.v1.AuditConfigDelta parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static AuditConfigDelta parseFrom( - com.google.protobuf.ByteString data) + + public static com.google.iam.v1.AuditConfigDelta parseFrom(com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } - public static AuditConfigDelta parseFrom( + + public static com.google.iam.v1.AuditConfigDelta parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static AuditConfigDelta parseFrom(byte[] data) + + public static com.google.iam.v1.AuditConfigDelta parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } - public static AuditConfigDelta parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + + public static com.google.iam.v1.AuditConfigDelta parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static AuditConfigDelta parseFrom(java.io.InputStream input) + + public static com.google.iam.v1.AuditConfigDelta parseFrom(java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } - public static AuditConfigDelta parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + + public static com.google.iam.v1.AuditConfigDelta parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } - public static AuditConfigDelta parseDelimitedFrom(java.io.InputStream input) + + public static com.google.iam.v1.AuditConfigDelta parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } - public static AuditConfigDelta parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + + public static com.google.iam.v1.AuditConfigDelta parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); } - public static AuditConfigDelta parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + + public static com.google.iam.v1.AuditConfigDelta parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } - public static AuditConfigDelta parseFrom( + + public static com.google.iam.v1.AuditConfigDelta parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); } - @Override - public Builder newBuilderForType() { return newBuilder(); } public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } - public static Builder newBuilder(AuditConfigDelta prototype) { + + public static Builder newBuilder(com.google.iam.v1.AuditConfigDelta prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } - @Override + + @java.lang.Override public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } - @Override - protected Builder newBuilderForType( - BuilderParent parent) { + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** + * + * *
    * One delta entry for AuditConfig. Each individual change (only one
    * exempted_member in each entry) to a AuditConfig will be a separate entry.
@@ -601,21 +673,23 @@ protected Builder newBuilderForType(
    *
    * Protobuf type {@code google.iam.v1.AuditConfigDelta}
    */
-  public static final class Builder extends
-      com.google.protobuf.GeneratedMessageV3.Builder implements
+  public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder
+      implements
       // @@protoc_insertion_point(builder_implements:google.iam.v1.AuditConfigDelta)
       com.google.iam.v1.AuditConfigDeltaOrBuilder {
-    public static final com.google.protobuf.Descriptors.Descriptor
-        getDescriptor() {
-      return PolicyProto.internal_static_google_iam_v1_AuditConfigDelta_descriptor;
+    public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() {
+      return com.google.iam.v1.PolicyProto
+          .internal_static_google_iam_v1_AuditConfigDelta_descriptor;
     }
 
-    @Override
-    protected FieldAccessorTable
+    @java.lang.Override
+    protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
         internalGetFieldAccessorTable() {
-      return PolicyProto.internal_static_google_iam_v1_AuditConfigDelta_fieldAccessorTable
+      return com.google.iam.v1.PolicyProto
+          .internal_static_google_iam_v1_AuditConfigDelta_fieldAccessorTable
           .ensureFieldAccessorsInitialized(
-              AuditConfigDelta.class, Builder.class);
+              com.google.iam.v1.AuditConfigDelta.class,
+              com.google.iam.v1.AuditConfigDelta.Builder.class);
     }
 
     // Construct using com.google.iam.v1.AuditConfigDelta.newBuilder()
@@ -623,17 +697,16 @@ private Builder() {
       maybeForceBuilderInitialization();
     }
 
-    private Builder(
-        BuilderParent parent) {
+    private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
       super(parent);
       maybeForceBuilderInitialization();
     }
+
     private void maybeForceBuilderInitialization() {
-      if (com.google.protobuf.GeneratedMessageV3
-              .alwaysUseFieldBuilders) {
-      }
+      if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {}
     }
-    @Override
+
+    @java.lang.Override
     public Builder clear() {
       super.clear();
       action_ = 0;
@@ -647,29 +720,29 @@ public Builder clear() {
       return this;
     }
 
-    @Override
-    public com.google.protobuf.Descriptors.Descriptor
-        getDescriptorForType() {
-      return PolicyProto.internal_static_google_iam_v1_AuditConfigDelta_descriptor;
+    @java.lang.Override
+    public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() {
+      return com.google.iam.v1.PolicyProto
+          .internal_static_google_iam_v1_AuditConfigDelta_descriptor;
     }
 
-    @Override
-    public AuditConfigDelta getDefaultInstanceForType() {
-      return AuditConfigDelta.getDefaultInstance();
+    @java.lang.Override
+    public com.google.iam.v1.AuditConfigDelta getDefaultInstanceForType() {
+      return com.google.iam.v1.AuditConfigDelta.getDefaultInstance();
     }
 
-    @Override
-    public AuditConfigDelta build() {
-      AuditConfigDelta result = buildPartial();
+    @java.lang.Override
+    public com.google.iam.v1.AuditConfigDelta build() {
+      com.google.iam.v1.AuditConfigDelta result = buildPartial();
       if (!result.isInitialized()) {
         throw newUninitializedMessageException(result);
       }
       return result;
     }
 
-    @Override
-    public AuditConfigDelta buildPartial() {
-      AuditConfigDelta result = new AuditConfigDelta(this);
+    @java.lang.Override
+    public com.google.iam.v1.AuditConfigDelta buildPartial() {
+      com.google.iam.v1.AuditConfigDelta result = new com.google.iam.v1.AuditConfigDelta(this);
       result.action_ = action_;
       result.service_ = service_;
       result.exemptedMember_ = exemptedMember_;
@@ -678,50 +751,51 @@ public AuditConfigDelta buildPartial() {
       return result;
     }
 
-    @Override
+    @java.lang.Override
     public Builder clone() {
       return super.clone();
     }
-    @Override
+
+    @java.lang.Override
     public Builder setField(
-        com.google.protobuf.Descriptors.FieldDescriptor field,
-        Object value) {
+        com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) {
       return super.setField(field, value);
     }
-    @Override
-    public Builder clearField(
-        com.google.protobuf.Descriptors.FieldDescriptor field) {
+
+    @java.lang.Override
+    public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) {
       return super.clearField(field);
     }
-    @Override
-    public Builder clearOneof(
-        com.google.protobuf.Descriptors.OneofDescriptor oneof) {
+
+    @java.lang.Override
+    public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) {
       return super.clearOneof(oneof);
     }
-    @Override
+
+    @java.lang.Override
     public Builder setRepeatedField(
-        com.google.protobuf.Descriptors.FieldDescriptor field,
-        int index, Object value) {
+        com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) {
       return super.setRepeatedField(field, index, value);
     }
-    @Override
+
+    @java.lang.Override
     public Builder addRepeatedField(
-        com.google.protobuf.Descriptors.FieldDescriptor field,
-        Object value) {
+        com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) {
       return super.addRepeatedField(field, value);
     }
-    @Override
+
+    @java.lang.Override
     public Builder mergeFrom(com.google.protobuf.Message other) {
-      if (other instanceof AuditConfigDelta) {
-        return mergeFrom((AuditConfigDelta)other);
+      if (other instanceof com.google.iam.v1.AuditConfigDelta) {
+        return mergeFrom((com.google.iam.v1.AuditConfigDelta) other);
       } else {
         super.mergeFrom(other);
         return this;
       }
     }
 
-    public Builder mergeFrom(AuditConfigDelta other) {
-      if (other == AuditConfigDelta.getDefaultInstance()) return this;
+    public Builder mergeFrom(com.google.iam.v1.AuditConfigDelta other) {
+      if (other == com.google.iam.v1.AuditConfigDelta.getDefaultInstance()) return this;
       if (other.action_ != 0) {
         setActionValue(other.getActionValue());
       }
@@ -742,21 +816,21 @@ public Builder mergeFrom(AuditConfigDelta other) {
       return this;
     }
 
-    @Override
+    @java.lang.Override
     public final boolean isInitialized() {
       return true;
     }
 
-    @Override
+    @java.lang.Override
     public Builder mergeFrom(
         com.google.protobuf.CodedInputStream input,
         com.google.protobuf.ExtensionRegistryLite extensionRegistry)
         throws java.io.IOException {
-      AuditConfigDelta parsedMessage = null;
+      com.google.iam.v1.AuditConfigDelta parsedMessage = null;
       try {
         parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
       } catch (com.google.protobuf.InvalidProtocolBufferException e) {
-        parsedMessage = (AuditConfigDelta) e.getUnfinishedMessage();
+        parsedMessage = (com.google.iam.v1.AuditConfigDelta) e.getUnfinishedMessage();
         throw e.unwrapIOException();
       } finally {
         if (parsedMessage != null) {
@@ -768,23 +842,32 @@ public Builder mergeFrom(
 
     private int action_ = 0;
     /**
+     *
+     *
      * 
      * The action that was performed on an audit configuration in a policy.
      * Required
      * 
* * .google.iam.v1.AuditConfigDelta.Action action = 1; + * + * @return The enum numeric value on the wire for action. */ public int getActionValue() { return action_; } /** + * + * *
      * The action that was performed on an audit configuration in a policy.
      * Required
      * 
* * .google.iam.v1.AuditConfigDelta.Action action = 1; + * + * @param value The enum numeric value on the wire for action to set. + * @return This builder for chaining. */ public Builder setActionValue(int value) { action_ = value; @@ -792,52 +875,68 @@ public Builder setActionValue(int value) { return this; } /** + * + * *
      * The action that was performed on an audit configuration in a policy.
      * Required
      * 
* * .google.iam.v1.AuditConfigDelta.Action action = 1; + * + * @return The action. */ - public Action getAction() { + public com.google.iam.v1.AuditConfigDelta.Action getAction() { @SuppressWarnings("deprecation") - Action result = Action.valueOf(action_); - return result == null ? Action.UNRECOGNIZED : result; + com.google.iam.v1.AuditConfigDelta.Action result = + com.google.iam.v1.AuditConfigDelta.Action.valueOf(action_); + return result == null ? com.google.iam.v1.AuditConfigDelta.Action.UNRECOGNIZED : result; } /** + * + * *
      * The action that was performed on an audit configuration in a policy.
      * Required
      * 
* * .google.iam.v1.AuditConfigDelta.Action action = 1; + * + * @param value The action to set. + * @return This builder for chaining. */ - public Builder setAction(Action value) { + public Builder setAction(com.google.iam.v1.AuditConfigDelta.Action value) { if (value == null) { throw new NullPointerException(); } - + action_ = value.getNumber(); onChanged(); return this; } /** + * + * *
      * The action that was performed on an audit configuration in a policy.
      * Required
      * 
* * .google.iam.v1.AuditConfigDelta.Action action = 1; + * + * @return This builder for chaining. */ public Builder clearAction() { - + action_ = 0; onChanged(); return this; } - private Object service_ = ""; + private java.lang.Object service_ = ""; /** + * + * *
      * Specifies a service that was configured for Cloud Audit Logging.
      * For example, `storage.googleapis.com`, `cloudsql.googleapis.com`.
@@ -846,20 +945,23 @@ public Builder clearAction() {
      * 
* * string service = 2; + * + * @return The service. */ - public String getService() { - Object ref = service_; - if (!(ref instanceof String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - String s = bs.toStringUtf8(); + public java.lang.String getService() { + java.lang.Object ref = service_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); service_ = s; return s; } else { - return (String) ref; + return (java.lang.String) ref; } } /** + * + * *
      * Specifies a service that was configured for Cloud Audit Logging.
      * For example, `storage.googleapis.com`, `cloudsql.googleapis.com`.
@@ -868,14 +970,14 @@ public String getService() {
      * 
* * string service = 2; + * + * @return The bytes for service. */ - public com.google.protobuf.ByteString - getServiceBytes() { - Object ref = service_; + public com.google.protobuf.ByteString getServiceBytes() { + java.lang.Object ref = service_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); service_ = b; return b; } else { @@ -883,6 +985,8 @@ public String getService() { } } /** + * + * *
      * Specifies a service that was configured for Cloud Audit Logging.
      * For example, `storage.googleapis.com`, `cloudsql.googleapis.com`.
@@ -891,18 +995,22 @@ public String getService() {
      * 
* * string service = 2; + * + * @param value The service to set. + * @return This builder for chaining. */ - public Builder setService( - String value) { + public Builder setService(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + service_ = value; onChanged(); return this; } /** + * + * *
      * Specifies a service that was configured for Cloud Audit Logging.
      * For example, `storage.googleapis.com`, `cloudsql.googleapis.com`.
@@ -911,14 +1019,18 @@ public Builder setService(
      * 
* * string service = 2; + * + * @return This builder for chaining. */ public Builder clearService() { - + service_ = getDefaultInstance().getService(); onChanged(); return this; } /** + * + * *
      * Specifies a service that was configured for Cloud Audit Logging.
      * For example, `storage.googleapis.com`, `cloudsql.googleapis.com`.
@@ -927,21 +1039,25 @@ public Builder clearService() {
      * 
* * string service = 2; + * + * @param value The bytes for service to set. + * @return This builder for chaining. */ - public Builder setServiceBytes( - com.google.protobuf.ByteString value) { + public Builder setServiceBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + service_ = value; onChanged(); return this; } - private Object exemptedMember_ = ""; + private java.lang.Object exemptedMember_ = ""; /** + * + * *
      * A single identity that is exempted from "data access" audit
      * logging for the `service` specified above.
@@ -949,20 +1065,23 @@ public Builder setServiceBytes(
      * 
* * string exempted_member = 3; + * + * @return The exemptedMember. */ - public String getExemptedMember() { - Object ref = exemptedMember_; - if (!(ref instanceof String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - String s = bs.toStringUtf8(); + public java.lang.String getExemptedMember() { + java.lang.Object ref = exemptedMember_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); exemptedMember_ = s; return s; } else { - return (String) ref; + return (java.lang.String) ref; } } /** + * + * *
      * A single identity that is exempted from "data access" audit
      * logging for the `service` specified above.
@@ -970,14 +1089,14 @@ public String getExemptedMember() {
      * 
* * string exempted_member = 3; + * + * @return The bytes for exemptedMember. */ - public com.google.protobuf.ByteString - getExemptedMemberBytes() { - Object ref = exemptedMember_; + public com.google.protobuf.ByteString getExemptedMemberBytes() { + java.lang.Object ref = exemptedMember_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); exemptedMember_ = b; return b; } else { @@ -985,6 +1104,8 @@ public String getExemptedMember() { } } /** + * + * *
      * A single identity that is exempted from "data access" audit
      * logging for the `service` specified above.
@@ -992,18 +1113,22 @@ public String getExemptedMember() {
      * 
* * string exempted_member = 3; + * + * @param value The exemptedMember to set. + * @return This builder for chaining. */ - public Builder setExemptedMember( - String value) { + public Builder setExemptedMember(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + exemptedMember_ = value; onChanged(); return this; } /** + * + * *
      * A single identity that is exempted from "data access" audit
      * logging for the `service` specified above.
@@ -1011,14 +1136,18 @@ public Builder setExemptedMember(
      * 
* * string exempted_member = 3; + * + * @return This builder for chaining. */ public Builder clearExemptedMember() { - + exemptedMember_ = getDefaultInstance().getExemptedMember(); onChanged(); return this; } /** + * + * *
      * A single identity that is exempted from "data access" audit
      * logging for the `service` specified above.
@@ -1026,21 +1155,25 @@ public Builder clearExemptedMember() {
      * 
* * string exempted_member = 3; + * + * @param value The bytes for exemptedMember to set. + * @return This builder for chaining. */ - public Builder setExemptedMemberBytes( - com.google.protobuf.ByteString value) { + public Builder setExemptedMemberBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + exemptedMember_ = value; onChanged(); return this; } - private Object logType_ = ""; + private java.lang.Object logType_ = ""; /** + * + * *
      * Specifies the log_type that was be enabled. ADMIN_ACTIVITY is always
      * enabled, and cannot be configured.
@@ -1048,20 +1181,23 @@ public Builder setExemptedMemberBytes(
      * 
* * string log_type = 4; + * + * @return The logType. */ - public String getLogType() { - Object ref = logType_; - if (!(ref instanceof String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - String s = bs.toStringUtf8(); + public java.lang.String getLogType() { + java.lang.Object ref = logType_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); logType_ = s; return s; } else { - return (String) ref; + return (java.lang.String) ref; } } /** + * + * *
      * Specifies the log_type that was be enabled. ADMIN_ACTIVITY is always
      * enabled, and cannot be configured.
@@ -1069,14 +1205,14 @@ public String getLogType() {
      * 
* * string log_type = 4; + * + * @return The bytes for logType. */ - public com.google.protobuf.ByteString - getLogTypeBytes() { - Object ref = logType_; + public com.google.protobuf.ByteString getLogTypeBytes() { + java.lang.Object ref = logType_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); logType_ = b; return b; } else { @@ -1084,6 +1220,8 @@ public String getLogType() { } } /** + * + * *
      * Specifies the log_type that was be enabled. ADMIN_ACTIVITY is always
      * enabled, and cannot be configured.
@@ -1091,18 +1229,22 @@ public String getLogType() {
      * 
* * string log_type = 4; + * + * @param value The logType to set. + * @return This builder for chaining. */ - public Builder setLogType( - String value) { + public Builder setLogType(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + logType_ = value; onChanged(); return this; } /** + * + * *
      * Specifies the log_type that was be enabled. ADMIN_ACTIVITY is always
      * enabled, and cannot be configured.
@@ -1110,14 +1252,18 @@ public Builder setLogType(
      * 
* * string log_type = 4; + * + * @return This builder for chaining. */ public Builder clearLogType() { - + logType_ = getDefaultInstance().getLogType(); onChanged(); return this; } /** + * + * *
      * Specifies the log_type that was be enabled. ADMIN_ACTIVITY is always
      * enabled, and cannot be configured.
@@ -1125,68 +1271,68 @@ public Builder clearLogType() {
      * 
* * string log_type = 4; + * + * @param value The bytes for logType to set. + * @return This builder for chaining. */ - public Builder setLogTypeBytes( - com.google.protobuf.ByteString value) { + public Builder setLogTypeBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + logType_ = value; onChanged(); return this; } - @Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } - @Override + @java.lang.Override public final Builder mergeUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return super.mergeUnknownFields(unknownFields); } - // @@protoc_insertion_point(builder_scope:google.iam.v1.AuditConfigDelta) } // @@protoc_insertion_point(class_scope:google.iam.v1.AuditConfigDelta) - private static final AuditConfigDelta DEFAULT_INSTANCE; + private static final com.google.iam.v1.AuditConfigDelta DEFAULT_INSTANCE; + static { - DEFAULT_INSTANCE = new AuditConfigDelta(); + DEFAULT_INSTANCE = new com.google.iam.v1.AuditConfigDelta(); } - public static AuditConfigDelta getDefaultInstance() { + public static com.google.iam.v1.AuditConfigDelta getDefaultInstance() { return DEFAULT_INSTANCE; } - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - @Override - public AuditConfigDelta parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new AuditConfigDelta(input, extensionRegistry); - } - }; + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public AuditConfigDelta parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new AuditConfigDelta(input, extensionRegistry); + } + }; public static com.google.protobuf.Parser parser() { return PARSER; } - @Override + @java.lang.Override public com.google.protobuf.Parser getParserForType() { return PARSER; } - @Override - public AuditConfigDelta getDefaultInstanceForType() { + @java.lang.Override + public com.google.iam.v1.AuditConfigDelta getDefaultInstanceForType() { return DEFAULT_INSTANCE; } - } - diff --git a/proto-google-iam-v1/src/main/java/com/google/iam/v1/AuditConfigDeltaOrBuilder.java b/proto-google-iam-v1/src/main/java/com/google/iam/v1/AuditConfigDeltaOrBuilder.java index 1ecef232..e1bea6c2 100644 --- a/proto-google-iam-v1/src/main/java/com/google/iam/v1/AuditConfigDeltaOrBuilder.java +++ b/proto-google-iam-v1/src/main/java/com/google/iam/v1/AuditConfigDeltaOrBuilder.java @@ -1,32 +1,58 @@ +/* + * 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/iam/v1/policy.proto package com.google.iam.v1; -public interface AuditConfigDeltaOrBuilder extends +public interface AuditConfigDeltaOrBuilder + extends // @@protoc_insertion_point(interface_extends:google.iam.v1.AuditConfigDelta) com.google.protobuf.MessageOrBuilder { /** + * + * *
    * The action that was performed on an audit configuration in a policy.
    * Required
    * 
* * .google.iam.v1.AuditConfigDelta.Action action = 1; + * + * @return The enum numeric value on the wire for action. */ int getActionValue(); /** + * + * *
    * The action that was performed on an audit configuration in a policy.
    * Required
    * 
* * .google.iam.v1.AuditConfigDelta.Action action = 1; + * + * @return The action. */ - AuditConfigDelta.Action getAction(); + com.google.iam.v1.AuditConfigDelta.Action getAction(); /** + * + * *
    * Specifies a service that was configured for Cloud Audit Logging.
    * For example, `storage.googleapis.com`, `cloudsql.googleapis.com`.
@@ -35,9 +61,13 @@ public interface AuditConfigDeltaOrBuilder extends
    * 
* * string service = 2; + * + * @return The service. */ - String getService(); + java.lang.String getService(); /** + * + * *
    * Specifies a service that was configured for Cloud Audit Logging.
    * For example, `storage.googleapis.com`, `cloudsql.googleapis.com`.
@@ -46,11 +76,14 @@ public interface AuditConfigDeltaOrBuilder extends
    * 
* * string service = 2; + * + * @return The bytes for service. */ - com.google.protobuf.ByteString - getServiceBytes(); + com.google.protobuf.ByteString getServiceBytes(); /** + * + * *
    * A single identity that is exempted from "data access" audit
    * logging for the `service` specified above.
@@ -58,9 +91,13 @@ public interface AuditConfigDeltaOrBuilder extends
    * 
* * string exempted_member = 3; + * + * @return The exemptedMember. */ - String getExemptedMember(); + java.lang.String getExemptedMember(); /** + * + * *
    * A single identity that is exempted from "data access" audit
    * logging for the `service` specified above.
@@ -68,11 +105,14 @@ public interface AuditConfigDeltaOrBuilder extends
    * 
* * string exempted_member = 3; + * + * @return The bytes for exemptedMember. */ - com.google.protobuf.ByteString - getExemptedMemberBytes(); + com.google.protobuf.ByteString getExemptedMemberBytes(); /** + * + * *
    * Specifies the log_type that was be enabled. ADMIN_ACTIVITY is always
    * enabled, and cannot be configured.
@@ -80,9 +120,13 @@ public interface AuditConfigDeltaOrBuilder extends
    * 
* * string log_type = 4; + * + * @return The logType. */ - String getLogType(); + java.lang.String getLogType(); /** + * + * *
    * Specifies the log_type that was be enabled. ADMIN_ACTIVITY is always
    * enabled, and cannot be configured.
@@ -90,7 +134,8 @@ public interface AuditConfigDeltaOrBuilder extends
    * 
* * string log_type = 4; + * + * @return The bytes for logType. */ - com.google.protobuf.ByteString - getLogTypeBytes(); + com.google.protobuf.ByteString getLogTypeBytes(); } diff --git a/proto-google-iam-v1/src/main/java/com/google/iam/v1/Binding.java b/proto-google-iam-v1/src/main/java/com/google/iam/v1/Binding.java index ddb14676..04e2b560 100644 --- a/proto-google-iam-v1/src/main/java/com/google/iam/v1/Binding.java +++ b/proto-google-iam-v1/src/main/java/com/google/iam/v1/Binding.java @@ -1,41 +1,65 @@ +/* + * 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/iam/v1/policy.proto package com.google.iam.v1; /** + * + * *
  * Associates `members` with a `role`.
  * 
* * Protobuf type {@code google.iam.v1.Binding} */ -public final class Binding extends - com.google.protobuf.GeneratedMessageV3 implements +public final class Binding extends com.google.protobuf.GeneratedMessageV3 + implements // @@protoc_insertion_point(message_implements:google.iam.v1.Binding) BindingOrBuilder { -private static final long serialVersionUID = 0L; + private static final long serialVersionUID = 0L; // Use Binding.newBuilder() to construct. private Binding(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } + private Binding() { role_ = ""; members_ = com.google.protobuf.LazyStringArrayList.EMPTY; } - @Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new Binding(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } + private Binding( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { this(); if (extensionRegistry == null) { - throw new NullPointerException(); + throw new java.lang.NullPointerException(); } int mutable_bitField0_ = 0; com.google.protobuf.UnknownFieldSet.Builder unknownFields = @@ -48,107 +72,113 @@ private Binding( case 0: done = true; break; - case 10: { - String s = input.readStringRequireUtf8(); + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); - role_ = s; - break; - } - case 18: { - String s = input.readStringRequireUtf8(); - if (!((mutable_bitField0_ & 0x00000002) != 0)) { - members_ = new com.google.protobuf.LazyStringArrayList(); - mutable_bitField0_ |= 0x00000002; + role_ = s; + break; } - members_.add(s); - break; - } - case 26: { - com.google.type.Expr.Builder subBuilder = null; - if (condition_ != null) { - subBuilder = condition_.toBuilder(); - } - condition_ = input.readMessage(com.google.type.Expr.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(condition_); - condition_ = subBuilder.buildPartial(); + case 18: + { + java.lang.String s = input.readStringRequireUtf8(); + if (!((mutable_bitField0_ & 0x00000001) != 0)) { + members_ = new com.google.protobuf.LazyStringArrayList(); + mutable_bitField0_ |= 0x00000001; + } + members_.add(s); + break; } + case 26: + { + com.google.type.Expr.Builder subBuilder = null; + if (condition_ != null) { + subBuilder = condition_.toBuilder(); + } + condition_ = input.readMessage(com.google.type.Expr.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(condition_); + condition_ = subBuilder.buildPartial(); + } - break; - } - default: { - if (!parseUnknownField( - input, unknownFields, extensionRegistry, tag)) { - done = true; + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; } - break; - } } } } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(this); } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException( - e).setUnfinishedMessage(this); + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); } finally { - if (((mutable_bitField0_ & 0x00000002) != 0)) { + if (((mutable_bitField0_ & 0x00000001) != 0)) { members_ = members_.getUnmodifiableView(); } this.unknownFields = unknownFields.build(); makeExtensionsImmutable(); } } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.iam.v1.PolicyProto.internal_static_google_iam_v1_Binding_descriptor; } - @Override - protected FieldAccessorTable + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.google.iam.v1.PolicyProto.internal_static_google_iam_v1_Binding_fieldAccessorTable .ensureFieldAccessorsInitialized( - Binding.class, Builder.class); + com.google.iam.v1.Binding.class, com.google.iam.v1.Binding.Builder.class); } - private int bitField0_; public static final int ROLE_FIELD_NUMBER = 1; - private volatile Object role_; + private volatile java.lang.Object role_; /** + * + * *
    * Role that is assigned to `members`.
    * For example, `roles/viewer`, `roles/editor`, or `roles/owner`.
    * 
* * string role = 1; + * + * @return The role. */ - public String getRole() { - Object ref = role_; - if (ref instanceof String) { - return (String) ref; + public java.lang.String getRole() { + java.lang.Object ref = role_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - String s = bs.toStringUtf8(); + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); role_ = s; return s; } } /** + * + * *
    * Role that is assigned to `members`.
    * For example, `roles/viewer`, `roles/editor`, or `roles/owner`.
    * 
* * string role = 1; + * + * @return The bytes for role. */ - public com.google.protobuf.ByteString - getRoleBytes() { - Object ref = role_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (String) ref); + public com.google.protobuf.ByteString getRoleBytes() { + java.lang.Object ref = role_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); role_ = b; return b; } else { @@ -159,6 +189,8 @@ public String getRole() { public static final int MEMBERS_FIELD_NUMBER = 2; private com.google.protobuf.LazyStringList members_; /** + * + * *
    * Specifies the identities requesting access for a Cloud Platform resource.
    * `members` can have the following values:
@@ -177,12 +209,15 @@ public String getRole() {
    * 
* * repeated string members = 2; + * + * @return A list containing the members. */ - public com.google.protobuf.ProtocolStringList - getMembersList() { + public com.google.protobuf.ProtocolStringList getMembersList() { return members_; } /** + * + * *
    * Specifies the identities requesting access for a Cloud Platform resource.
    * `members` can have the following values:
@@ -201,11 +236,15 @@ public String getRole() {
    * 
* * repeated string members = 2; + * + * @return The count of members. */ public int getMembersCount() { return members_.size(); } /** + * + * *
    * Specifies the identities requesting access for a Cloud Platform resource.
    * `members` can have the following values:
@@ -224,11 +263,16 @@ public int getMembersCount() {
    * 
* * repeated string members = 2; + * + * @param index The index of the element to return. + * @return The members at the given index. */ - public String getMembers(int index) { + public java.lang.String getMembers(int index) { return members_.get(index); } /** + * + * *
    * Specifies the identities requesting access for a Cloud Platform resource.
    * `members` can have the following values:
@@ -247,15 +291,19 @@ public String getMembers(int index) {
    * 
* * repeated string members = 2; + * + * @param index The index of the value to return. + * @return The bytes of the members at the given index. */ - public com.google.protobuf.ByteString - getMembersBytes(int index) { + public com.google.protobuf.ByteString getMembersBytes(int index) { return members_.getByteString(index); } public static final int CONDITION_FIELD_NUMBER = 3; private com.google.type.Expr condition_; /** + * + * *
    * The condition that is associated with this binding.
    * NOTE: An unsatisfied condition will not allow user access via current
@@ -264,11 +312,15 @@ public String getMembers(int index) {
    * 
* * .google.type.Expr condition = 3; + * + * @return Whether the condition field is set. */ public boolean hasCondition() { return condition_ != null; } /** + * + * *
    * The condition that is associated with this binding.
    * NOTE: An unsatisfied condition will not allow user access via current
@@ -277,11 +329,15 @@ public boolean hasCondition() {
    * 
* * .google.type.Expr condition = 3; + * + * @return The condition. */ public com.google.type.Expr getCondition() { return condition_ == null ? com.google.type.Expr.getDefaultInstance() : condition_; } /** + * + * *
    * The condition that is associated with this binding.
    * NOTE: An unsatisfied condition will not allow user access via current
@@ -296,7 +352,8 @@ public com.google.type.ExprOrBuilder getConditionOrBuilder() {
   }
 
   private byte memoizedIsInitialized = -1;
-  @Override
+
+  @java.lang.Override
   public final boolean isInitialized() {
     byte isInitialized = memoizedIsInitialized;
     if (isInitialized == 1) return true;
@@ -306,9 +363,8 @@ public final boolean isInitialized() {
     return true;
   }
 
-  @Override
-  public void writeTo(com.google.protobuf.CodedOutputStream output)
-                      throws java.io.IOException {
+  @java.lang.Override
+  public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException {
     if (!getRoleBytes().isEmpty()) {
       com.google.protobuf.GeneratedMessageV3.writeString(output, 1, role_);
     }
@@ -321,7 +377,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output)
     unknownFields.writeTo(output);
   }
 
-  @Override
+  @java.lang.Override
   public int getSerializedSize() {
     int size = memoizedSize;
     if (size != -1) return size;
@@ -339,38 +395,34 @@ public int getSerializedSize() {
       size += 1 * getMembersList().size();
     }
     if (condition_ != null) {
-      size += com.google.protobuf.CodedOutputStream
-        .computeMessageSize(3, getCondition());
+      size += com.google.protobuf.CodedOutputStream.computeMessageSize(3, getCondition());
     }
     size += unknownFields.getSerializedSize();
     memoizedSize = size;
     return size;
   }
 
-  @Override
-  public boolean equals(final Object obj) {
+  @java.lang.Override
+  public boolean equals(final java.lang.Object obj) {
     if (obj == this) {
-     return true;
+      return true;
     }
-    if (!(obj instanceof Binding)) {
+    if (!(obj instanceof com.google.iam.v1.Binding)) {
       return super.equals(obj);
     }
-    Binding other = (Binding) obj;
+    com.google.iam.v1.Binding other = (com.google.iam.v1.Binding) obj;
 
-    if (!getRole()
-        .equals(other.getRole())) return false;
-    if (!getMembersList()
-        .equals(other.getMembersList())) return false;
+    if (!getRole().equals(other.getRole())) return false;
+    if (!getMembersList().equals(other.getMembersList())) return false;
     if (hasCondition() != other.hasCondition()) return false;
     if (hasCondition()) {
-      if (!getCondition()
-          .equals(other.getCondition())) return false;
+      if (!getCondition().equals(other.getCondition())) return false;
     }
     if (!unknownFields.equals(other.unknownFields)) return false;
     return true;
   }
 
-  @Override
+  @java.lang.Override
   public int hashCode() {
     if (memoizedHashCode != 0) {
       return memoizedHashCode;
@@ -392,118 +444,123 @@ public int hashCode() {
     return hash;
   }
 
-  public static Binding parseFrom(
-      java.nio.ByteBuffer data)
+  public static com.google.iam.v1.Binding parseFrom(java.nio.ByteBuffer data)
       throws com.google.protobuf.InvalidProtocolBufferException {
     return PARSER.parseFrom(data);
   }
-  public static Binding parseFrom(
-      java.nio.ByteBuffer data,
-      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+
+  public static com.google.iam.v1.Binding parseFrom(
+      java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
       throws com.google.protobuf.InvalidProtocolBufferException {
     return PARSER.parseFrom(data, extensionRegistry);
   }
-  public static Binding parseFrom(
-      com.google.protobuf.ByteString data)
+
+  public static com.google.iam.v1.Binding parseFrom(com.google.protobuf.ByteString data)
       throws com.google.protobuf.InvalidProtocolBufferException {
     return PARSER.parseFrom(data);
   }
-  public static Binding parseFrom(
+
+  public static com.google.iam.v1.Binding parseFrom(
       com.google.protobuf.ByteString data,
       com.google.protobuf.ExtensionRegistryLite extensionRegistry)
       throws com.google.protobuf.InvalidProtocolBufferException {
     return PARSER.parseFrom(data, extensionRegistry);
   }
-  public static Binding parseFrom(byte[] data)
+
+  public static com.google.iam.v1.Binding parseFrom(byte[] data)
       throws com.google.protobuf.InvalidProtocolBufferException {
     return PARSER.parseFrom(data);
   }
-  public static Binding parseFrom(
-      byte[] data,
-      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+
+  public static com.google.iam.v1.Binding parseFrom(
+      byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
       throws com.google.protobuf.InvalidProtocolBufferException {
     return PARSER.parseFrom(data, extensionRegistry);
   }
-  public static Binding parseFrom(java.io.InputStream input)
+
+  public static com.google.iam.v1.Binding parseFrom(java.io.InputStream input)
       throws java.io.IOException {
-    return com.google.protobuf.GeneratedMessageV3
-        .parseWithIOException(PARSER, input);
+    return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
   }
-  public static Binding parseFrom(
-      java.io.InputStream input,
-      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+
+  public static com.google.iam.v1.Binding parseFrom(
+      java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
       throws java.io.IOException {
-    return com.google.protobuf.GeneratedMessageV3
-        .parseWithIOException(PARSER, input, extensionRegistry);
+    return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
+        PARSER, input, extensionRegistry);
   }
-  public static Binding parseDelimitedFrom(java.io.InputStream input)
+
+  public static com.google.iam.v1.Binding parseDelimitedFrom(java.io.InputStream input)
       throws java.io.IOException {
-    return com.google.protobuf.GeneratedMessageV3
-        .parseDelimitedWithIOException(PARSER, input);
+    return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input);
   }
-  public static Binding parseDelimitedFrom(
-      java.io.InputStream input,
-      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+
+  public static com.google.iam.v1.Binding parseDelimitedFrom(
+      java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
       throws java.io.IOException {
-    return com.google.protobuf.GeneratedMessageV3
-        .parseDelimitedWithIOException(PARSER, input, extensionRegistry);
+    return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(
+        PARSER, input, extensionRegistry);
   }
-  public static Binding parseFrom(
-      com.google.protobuf.CodedInputStream input)
+
+  public static com.google.iam.v1.Binding parseFrom(com.google.protobuf.CodedInputStream input)
       throws java.io.IOException {
-    return com.google.protobuf.GeneratedMessageV3
-        .parseWithIOException(PARSER, input);
+    return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
   }
-  public static Binding parseFrom(
+
+  public static com.google.iam.v1.Binding parseFrom(
       com.google.protobuf.CodedInputStream input,
       com.google.protobuf.ExtensionRegistryLite extensionRegistry)
       throws java.io.IOException {
-    return com.google.protobuf.GeneratedMessageV3
-        .parseWithIOException(PARSER, input, extensionRegistry);
+    return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
+        PARSER, input, extensionRegistry);
+  }
+
+  @java.lang.Override
+  public Builder newBuilderForType() {
+    return newBuilder();
   }
 
-  @Override
-  public Builder newBuilderForType() { return newBuilder(); }
   public static Builder newBuilder() {
     return DEFAULT_INSTANCE.toBuilder();
   }
-  public static Builder newBuilder(Binding prototype) {
+
+  public static Builder newBuilder(com.google.iam.v1.Binding prototype) {
     return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
   }
-  @Override
+
+  @java.lang.Override
   public Builder toBuilder() {
-    return this == DEFAULT_INSTANCE
-        ? new Builder() : new Builder().mergeFrom(this);
+    return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this);
   }
 
-  @Override
-  protected Builder newBuilderForType(
-      BuilderParent parent) {
+  @java.lang.Override
+  protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
     Builder builder = new Builder(parent);
     return builder;
   }
   /**
+   *
+   *
    * 
    * Associates `members` with a `role`.
    * 
* * Protobuf type {@code google.iam.v1.Binding} */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements // @@protoc_insertion_point(builder_implements:google.iam.v1.Binding) com.google.iam.v1.BindingOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.iam.v1.PolicyProto.internal_static_google_iam_v1_Binding_descriptor; } - @Override - protected FieldAccessorTable + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { return com.google.iam.v1.PolicyProto.internal_static_google_iam_v1_Binding_fieldAccessorTable .ensureFieldAccessorsInitialized( - Binding.class, Builder.class); + com.google.iam.v1.Binding.class, com.google.iam.v1.Binding.Builder.class); } // Construct using com.google.iam.v1.Binding.newBuilder() @@ -511,23 +568,22 @@ private Builder() { maybeForceBuilderInitialization(); } - private Builder( - BuilderParent parent) { + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); maybeForceBuilderInitialization(); } + private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } - @Override + + @java.lang.Override public Builder clear() { super.clear(); role_ = ""; members_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000002); + bitField0_ = (bitField0_ & ~0x00000001); if (conditionBuilder_ == null) { condition_ = null; } else { @@ -537,35 +593,33 @@ public Builder clear() { return this; } - @Override - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return com.google.iam.v1.PolicyProto.internal_static_google_iam_v1_Binding_descriptor; } - @Override - public Binding getDefaultInstanceForType() { - return Binding.getDefaultInstance(); + @java.lang.Override + public com.google.iam.v1.Binding getDefaultInstanceForType() { + return com.google.iam.v1.Binding.getDefaultInstance(); } - @Override - public Binding build() { - Binding result = buildPartial(); + @java.lang.Override + public com.google.iam.v1.Binding build() { + com.google.iam.v1.Binding result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } - @Override - public Binding buildPartial() { - Binding result = new Binding(this); + @java.lang.Override + public com.google.iam.v1.Binding buildPartial() { + com.google.iam.v1.Binding result = new com.google.iam.v1.Binding(this); int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; result.role_ = role_; - if (((bitField0_ & 0x00000002) != 0)) { + if (((bitField0_ & 0x00000001) != 0)) { members_ = members_.getUnmodifiableView(); - bitField0_ = (bitField0_ & ~0x00000002); + bitField0_ = (bitField0_ & ~0x00000001); } result.members_ = members_; if (conditionBuilder_ == null) { @@ -573,55 +627,55 @@ public Binding buildPartial() { } else { result.condition_ = conditionBuilder_.build(); } - result.bitField0_ = to_bitField0_; onBuilt(); return result; } - @Override + @java.lang.Override public Builder clone() { return super.clone(); } - @Override + + @java.lang.Override public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } - @Override - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } - @Override - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } - @Override + + @java.lang.Override public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } - @Override + + @java.lang.Override public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } - @Override + + @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof Binding) { - return mergeFrom((Binding)other); + if (other instanceof com.google.iam.v1.Binding) { + return mergeFrom((com.google.iam.v1.Binding) other); } else { super.mergeFrom(other); return this; } } - public Builder mergeFrom(Binding other) { - if (other == Binding.getDefaultInstance()) return this; + public Builder mergeFrom(com.google.iam.v1.Binding other) { + if (other == com.google.iam.v1.Binding.getDefaultInstance()) return this; if (!other.getRole().isEmpty()) { role_ = other.role_; onChanged(); @@ -629,7 +683,7 @@ public Builder mergeFrom(Binding other) { if (!other.members_.isEmpty()) { if (members_.isEmpty()) { members_ = other.members_; - bitField0_ = (bitField0_ & ~0x00000002); + bitField0_ = (bitField0_ & ~0x00000001); } else { ensureMembersIsMutable(); members_.addAll(other.members_); @@ -644,21 +698,21 @@ public Builder mergeFrom(Binding other) { return this; } - @Override + @java.lang.Override public final boolean isInitialized() { return true; } - @Override + @java.lang.Override public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - Binding parsedMessage = null; + com.google.iam.v1.Binding parsedMessage = null; try { parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (Binding) e.getUnfinishedMessage(); + parsedMessage = (com.google.iam.v1.Binding) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { if (parsedMessage != null) { @@ -667,44 +721,50 @@ public Builder mergeFrom( } return this; } + private int bitField0_; - private Object role_ = ""; + private java.lang.Object role_ = ""; /** + * + * *
      * Role that is assigned to `members`.
      * For example, `roles/viewer`, `roles/editor`, or `roles/owner`.
      * 
* * string role = 1; + * + * @return The role. */ - public String getRole() { - Object ref = role_; - if (!(ref instanceof String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - String s = bs.toStringUtf8(); + public java.lang.String getRole() { + java.lang.Object ref = role_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); role_ = s; return s; } else { - return (String) ref; + return (java.lang.String) ref; } } /** + * + * *
      * Role that is assigned to `members`.
      * For example, `roles/viewer`, `roles/editor`, or `roles/owner`.
      * 
* * string role = 1; + * + * @return The bytes for role. */ - public com.google.protobuf.ByteString - getRoleBytes() { - Object ref = role_; + public com.google.protobuf.ByteString getRoleBytes() { + java.lang.Object ref = role_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); role_ = b; return b; } else { @@ -712,65 +772,81 @@ public String getRole() { } } /** + * + * *
      * Role that is assigned to `members`.
      * For example, `roles/viewer`, `roles/editor`, or `roles/owner`.
      * 
* * string role = 1; + * + * @param value The role to set. + * @return This builder for chaining. */ - public Builder setRole( - String value) { + public Builder setRole(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + role_ = value; onChanged(); return this; } /** + * + * *
      * Role that is assigned to `members`.
      * For example, `roles/viewer`, `roles/editor`, or `roles/owner`.
      * 
* * string role = 1; + * + * @return This builder for chaining. */ public Builder clearRole() { - + role_ = getDefaultInstance().getRole(); onChanged(); return this; } /** + * + * *
      * Role that is assigned to `members`.
      * For example, `roles/viewer`, `roles/editor`, or `roles/owner`.
      * 
* * string role = 1; + * + * @param value The bytes for role to set. + * @return This builder for chaining. */ - public Builder setRoleBytes( - com.google.protobuf.ByteString value) { + public Builder setRoleBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + role_ = value; onChanged(); return this; } - private com.google.protobuf.LazyStringList members_ = com.google.protobuf.LazyStringArrayList.EMPTY; + private com.google.protobuf.LazyStringList members_ = + com.google.protobuf.LazyStringArrayList.EMPTY; + private void ensureMembersIsMutable() { - if (!((bitField0_ & 0x00000002) != 0)) { + if (!((bitField0_ & 0x00000001) != 0)) { members_ = new com.google.protobuf.LazyStringArrayList(members_); - bitField0_ |= 0x00000002; - } + bitField0_ |= 0x00000001; + } } /** + * + * *
      * Specifies the identities requesting access for a Cloud Platform resource.
      * `members` can have the following values:
@@ -789,12 +865,15 @@ private void ensureMembersIsMutable() {
      * 
* * repeated string members = 2; + * + * @return A list containing the members. */ - public com.google.protobuf.ProtocolStringList - getMembersList() { + public com.google.protobuf.ProtocolStringList getMembersList() { return members_.getUnmodifiableView(); } /** + * + * *
      * Specifies the identities requesting access for a Cloud Platform resource.
      * `members` can have the following values:
@@ -813,11 +892,15 @@ private void ensureMembersIsMutable() {
      * 
* * repeated string members = 2; + * + * @return The count of members. */ public int getMembersCount() { return members_.size(); } /** + * + * *
      * Specifies the identities requesting access for a Cloud Platform resource.
      * `members` can have the following values:
@@ -836,11 +919,16 @@ public int getMembersCount() {
      * 
* * repeated string members = 2; + * + * @param index The index of the element to return. + * @return The members at the given index. */ - public String getMembers(int index) { + public java.lang.String getMembers(int index) { return members_.get(index); } /** + * + * *
      * Specifies the identities requesting access for a Cloud Platform resource.
      * `members` can have the following values:
@@ -859,12 +947,16 @@ public String getMembers(int index) {
      * 
* * repeated string members = 2; + * + * @param index The index of the value to return. + * @return The bytes of the members at the given index. */ - public com.google.protobuf.ByteString - getMembersBytes(int index) { + public com.google.protobuf.ByteString getMembersBytes(int index) { return members_.getByteString(index); } /** + * + * *
      * Specifies the identities requesting access for a Cloud Platform resource.
      * `members` can have the following values:
@@ -883,18 +975,23 @@ public String getMembers(int index) {
      * 
* * repeated string members = 2; + * + * @param index The index to set the value at. + * @param value The members to set. + * @return This builder for chaining. */ - public Builder setMembers( - int index, String value) { + public Builder setMembers(int index, java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - ensureMembersIsMutable(); + throw new NullPointerException(); + } + ensureMembersIsMutable(); members_.set(index, value); onChanged(); return this; } /** + * + * *
      * Specifies the identities requesting access for a Cloud Platform resource.
      * `members` can have the following values:
@@ -913,18 +1010,22 @@ public Builder setMembers(
      * 
* * repeated string members = 2; + * + * @param value The members to add. + * @return This builder for chaining. */ - public Builder addMembers( - String value) { + public Builder addMembers(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - ensureMembersIsMutable(); + throw new NullPointerException(); + } + ensureMembersIsMutable(); members_.add(value); onChanged(); return this; } /** + * + * *
      * Specifies the identities requesting access for a Cloud Platform resource.
      * `members` can have the following values:
@@ -943,16 +1044,19 @@ public Builder addMembers(
      * 
* * repeated string members = 2; + * + * @param values The members to add. + * @return This builder for chaining. */ - public Builder addAllMembers( - Iterable values) { + public Builder addAllMembers(java.lang.Iterable values) { ensureMembersIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, members_); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, members_); onChanged(); return this; } /** + * + * *
      * Specifies the identities requesting access for a Cloud Platform resource.
      * `members` can have the following values:
@@ -971,14 +1075,18 @@ public Builder addAllMembers(
      * 
* * repeated string members = 2; + * + * @return This builder for chaining. */ public Builder clearMembers() { members_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000002); + bitField0_ = (bitField0_ & ~0x00000001); onChanged(); return this; } /** + * + * *
      * Specifies the identities requesting access for a Cloud Platform resource.
      * `members` can have the following values:
@@ -997,13 +1105,15 @@ public Builder clearMembers() {
      * 
* * repeated string members = 2; + * + * @param value The bytes of the members to add. + * @return This builder for chaining. */ - public Builder addMembersBytes( - com.google.protobuf.ByteString value) { + public Builder addMembersBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); ensureMembersIsMutable(); members_.add(value); onChanged(); @@ -1012,8 +1122,11 @@ public Builder addMembersBytes( private com.google.type.Expr condition_; private com.google.protobuf.SingleFieldBuilderV3< - com.google.type.Expr, com.google.type.Expr.Builder, com.google.type.ExprOrBuilder> conditionBuilder_; + com.google.type.Expr, com.google.type.Expr.Builder, com.google.type.ExprOrBuilder> + conditionBuilder_; /** + * + * *
      * The condition that is associated with this binding.
      * NOTE: An unsatisfied condition will not allow user access via current
@@ -1022,11 +1135,15 @@ public Builder addMembersBytes(
      * 
* * .google.type.Expr condition = 3; + * + * @return Whether the condition field is set. */ public boolean hasCondition() { return conditionBuilder_ != null || condition_ != null; } /** + * + * *
      * The condition that is associated with this binding.
      * NOTE: An unsatisfied condition will not allow user access via current
@@ -1035,6 +1152,8 @@ public boolean hasCondition() {
      * 
* * .google.type.Expr condition = 3; + * + * @return The condition. */ public com.google.type.Expr getCondition() { if (conditionBuilder_ == null) { @@ -1044,6 +1163,8 @@ public com.google.type.Expr getCondition() { } } /** + * + * *
      * The condition that is associated with this binding.
      * NOTE: An unsatisfied condition will not allow user access via current
@@ -1067,6 +1188,8 @@ public Builder setCondition(com.google.type.Expr value) {
       return this;
     }
     /**
+     *
+     *
      * 
      * The condition that is associated with this binding.
      * NOTE: An unsatisfied condition will not allow user access via current
@@ -1076,8 +1199,7 @@ public Builder setCondition(com.google.type.Expr value) {
      *
      * .google.type.Expr condition = 3;
      */
-    public Builder setCondition(
-        com.google.type.Expr.Builder builderForValue) {
+    public Builder setCondition(com.google.type.Expr.Builder builderForValue) {
       if (conditionBuilder_ == null) {
         condition_ = builderForValue.build();
         onChanged();
@@ -1088,6 +1210,8 @@ public Builder setCondition(
       return this;
     }
     /**
+     *
+     *
      * 
      * The condition that is associated with this binding.
      * NOTE: An unsatisfied condition will not allow user access via current
@@ -1100,8 +1224,7 @@ public Builder setCondition(
     public Builder mergeCondition(com.google.type.Expr value) {
       if (conditionBuilder_ == null) {
         if (condition_ != null) {
-          condition_ =
-            com.google.type.Expr.newBuilder(condition_).mergeFrom(value).buildPartial();
+          condition_ = com.google.type.Expr.newBuilder(condition_).mergeFrom(value).buildPartial();
         } else {
           condition_ = value;
         }
@@ -1113,6 +1236,8 @@ public Builder mergeCondition(com.google.type.Expr value) {
       return this;
     }
     /**
+     *
+     *
      * 
      * The condition that is associated with this binding.
      * NOTE: An unsatisfied condition will not allow user access via current
@@ -1134,6 +1259,8 @@ public Builder clearCondition() {
       return this;
     }
     /**
+     *
+     *
      * 
      * The condition that is associated with this binding.
      * NOTE: An unsatisfied condition will not allow user access via current
@@ -1144,11 +1271,13 @@ public Builder clearCondition() {
      * .google.type.Expr condition = 3;
      */
     public com.google.type.Expr.Builder getConditionBuilder() {
-      
+
       onChanged();
       return getConditionFieldBuilder().getBuilder();
     }
     /**
+     *
+     *
      * 
      * The condition that is associated with this binding.
      * NOTE: An unsatisfied condition will not allow user access via current
@@ -1162,11 +1291,12 @@ public com.google.type.ExprOrBuilder getConditionOrBuilder() {
       if (conditionBuilder_ != null) {
         return conditionBuilder_.getMessageOrBuilder();
       } else {
-        return condition_ == null ?
-            com.google.type.Expr.getDefaultInstance() : condition_;
+        return condition_ == null ? com.google.type.Expr.getDefaultInstance() : condition_;
       }
     }
     /**
+     *
+     *
      * 
      * The condition that is associated with this binding.
      * NOTE: An unsatisfied condition will not allow user access via current
@@ -1177,68 +1307,65 @@ public com.google.type.ExprOrBuilder getConditionOrBuilder() {
      * .google.type.Expr condition = 3;
      */
     private com.google.protobuf.SingleFieldBuilderV3<
-        com.google.type.Expr, com.google.type.Expr.Builder, com.google.type.ExprOrBuilder> 
+            com.google.type.Expr, com.google.type.Expr.Builder, com.google.type.ExprOrBuilder>
         getConditionFieldBuilder() {
       if (conditionBuilder_ == null) {
-        conditionBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
-            com.google.type.Expr, com.google.type.Expr.Builder, com.google.type.ExprOrBuilder>(
-                getCondition(),
-                getParentForChildren(),
-                isClean());
+        conditionBuilder_ =
+            new com.google.protobuf.SingleFieldBuilderV3<
+                com.google.type.Expr, com.google.type.Expr.Builder, com.google.type.ExprOrBuilder>(
+                getCondition(), getParentForChildren(), isClean());
         condition_ = null;
       }
       return conditionBuilder_;
     }
-    @Override
-    public final Builder setUnknownFields(
-        final com.google.protobuf.UnknownFieldSet unknownFields) {
+
+    @java.lang.Override
+    public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) {
       return super.setUnknownFields(unknownFields);
     }
 
-    @Override
+    @java.lang.Override
     public final Builder mergeUnknownFields(
         final com.google.protobuf.UnknownFieldSet unknownFields) {
       return super.mergeUnknownFields(unknownFields);
     }
 
-
     // @@protoc_insertion_point(builder_scope:google.iam.v1.Binding)
   }
 
   // @@protoc_insertion_point(class_scope:google.iam.v1.Binding)
-  private static final Binding DEFAULT_INSTANCE;
+  private static final com.google.iam.v1.Binding DEFAULT_INSTANCE;
+
   static {
-    DEFAULT_INSTANCE = new Binding();
+    DEFAULT_INSTANCE = new com.google.iam.v1.Binding();
   }
 
-  public static Binding getDefaultInstance() {
+  public static com.google.iam.v1.Binding getDefaultInstance() {
     return DEFAULT_INSTANCE;
   }
 
-  private static final com.google.protobuf.Parser
-      PARSER = new com.google.protobuf.AbstractParser() {
-    @Override
-    public Binding parsePartialFrom(
-        com.google.protobuf.CodedInputStream input,
-        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
-        throws com.google.protobuf.InvalidProtocolBufferException {
-      return new Binding(input, extensionRegistry);
-    }
-  };
+  private static final com.google.protobuf.Parser PARSER =
+      new com.google.protobuf.AbstractParser() {
+        @java.lang.Override
+        public Binding parsePartialFrom(
+            com.google.protobuf.CodedInputStream input,
+            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+            throws com.google.protobuf.InvalidProtocolBufferException {
+          return new Binding(input, extensionRegistry);
+        }
+      };
 
   public static com.google.protobuf.Parser parser() {
     return PARSER;
   }
 
-  @Override
+  @java.lang.Override
   public com.google.protobuf.Parser getParserForType() {
     return PARSER;
   }
 
-  @Override
-  public Binding getDefaultInstanceForType() {
+  @java.lang.Override
+  public com.google.iam.v1.Binding getDefaultInstanceForType() {
     return DEFAULT_INSTANCE;
   }
-
 }
-
diff --git a/proto-google-iam-v1/src/main/java/com/google/iam/v1/BindingDelta.java b/proto-google-iam-v1/src/main/java/com/google/iam/v1/BindingDelta.java
index 1d05ab59..731f4c9b 100644
--- a/proto-google-iam-v1/src/main/java/com/google/iam/v1/BindingDelta.java
+++ b/proto-google-iam-v1/src/main/java/com/google/iam/v1/BindingDelta.java
@@ -1,9 +1,26 @@
+/*
+ * 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/iam/v1/policy.proto
 
 package com.google.iam.v1;
 
 /**
+ *
+ *
  * 
  * One delta entry for Binding. Each individual change (only one member in each
  * entry) to a binding will be a separate entry.
@@ -11,35 +28,41 @@
  *
  * Protobuf type {@code google.iam.v1.BindingDelta}
  */
-public  final class BindingDelta extends
-    com.google.protobuf.GeneratedMessageV3 implements
+public final class BindingDelta extends com.google.protobuf.GeneratedMessageV3
+    implements
     // @@protoc_insertion_point(message_implements:google.iam.v1.BindingDelta)
     BindingDeltaOrBuilder {
-private static final long serialVersionUID = 0L;
+  private static final long serialVersionUID = 0L;
   // Use BindingDelta.newBuilder() to construct.
   private BindingDelta(com.google.protobuf.GeneratedMessageV3.Builder builder) {
     super(builder);
   }
+
   private BindingDelta() {
     action_ = 0;
     role_ = "";
     member_ = "";
   }
 
-  @Override
-  public final com.google.protobuf.UnknownFieldSet
-  getUnknownFields() {
+  @java.lang.Override
+  @SuppressWarnings({"unused"})
+  protected java.lang.Object newInstance(UnusedPrivateParameter unused) {
+    return new BindingDelta();
+  }
+
+  @java.lang.Override
+  public final com.google.protobuf.UnknownFieldSet getUnknownFields() {
     return this.unknownFields;
   }
+
   private BindingDelta(
       com.google.protobuf.CodedInputStream input,
       com.google.protobuf.ExtensionRegistryLite extensionRegistry)
       throws com.google.protobuf.InvalidProtocolBufferException {
     this();
     if (extensionRegistry == null) {
-      throw new NullPointerException();
+      throw new java.lang.NullPointerException();
     }
-    int mutable_bitField0_ = 0;
     com.google.protobuf.UnknownFieldSet.Builder unknownFields =
         com.google.protobuf.UnknownFieldSet.newBuilder();
     try {
@@ -50,79 +73,86 @@ private BindingDelta(
           case 0:
             done = true;
             break;
-          case 8: {
-            int rawValue = input.readEnum();
+          case 8:
+            {
+              int rawValue = input.readEnum();
 
-            action_ = rawValue;
-            break;
-          }
-          case 18: {
-            String s = input.readStringRequireUtf8();
+              action_ = rawValue;
+              break;
+            }
+          case 18:
+            {
+              java.lang.String s = input.readStringRequireUtf8();
 
-            role_ = s;
-            break;
-          }
-          case 26: {
-            String s = input.readStringRequireUtf8();
+              role_ = s;
+              break;
+            }
+          case 26:
+            {
+              java.lang.String s = input.readStringRequireUtf8();
 
-            member_ = s;
-            break;
-          }
-          case 34: {
-            com.google.type.Expr.Builder subBuilder = null;
-            if (condition_ != null) {
-              subBuilder = condition_.toBuilder();
+              member_ = s;
+              break;
             }
-            condition_ = input.readMessage(com.google.type.Expr.parser(), extensionRegistry);
-            if (subBuilder != null) {
-              subBuilder.mergeFrom(condition_);
-              condition_ = subBuilder.buildPartial();
+          case 34:
+            {
+              com.google.type.Expr.Builder subBuilder = null;
+              if (condition_ != null) {
+                subBuilder = condition_.toBuilder();
+              }
+              condition_ = input.readMessage(com.google.type.Expr.parser(), extensionRegistry);
+              if (subBuilder != null) {
+                subBuilder.mergeFrom(condition_);
+                condition_ = subBuilder.buildPartial();
+              }
+
+              break;
             }
-
-            break;
-          }
-          default: {
-            if (!parseUnknownField(
-                input, unknownFields, extensionRegistry, tag)) {
-              done = true;
+          default:
+            {
+              if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) {
+                done = true;
+              }
+              break;
             }
-            break;
-          }
         }
       }
     } catch (com.google.protobuf.InvalidProtocolBufferException e) {
       throw e.setUnfinishedMessage(this);
     } catch (java.io.IOException e) {
-      throw new com.google.protobuf.InvalidProtocolBufferException(
-          e).setUnfinishedMessage(this);
+      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 PolicyProto.internal_static_google_iam_v1_BindingDelta_descriptor;
+
+  public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() {
+    return com.google.iam.v1.PolicyProto.internal_static_google_iam_v1_BindingDelta_descriptor;
   }
 
-  @Override
-  protected FieldAccessorTable
+  @java.lang.Override
+  protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
       internalGetFieldAccessorTable() {
-    return PolicyProto.internal_static_google_iam_v1_BindingDelta_fieldAccessorTable
+    return com.google.iam.v1.PolicyProto
+        .internal_static_google_iam_v1_BindingDelta_fieldAccessorTable
         .ensureFieldAccessorsInitialized(
-            BindingDelta.class, Builder.class);
+            com.google.iam.v1.BindingDelta.class, com.google.iam.v1.BindingDelta.Builder.class);
   }
 
   /**
+   *
+   *
    * 
    * The type of action performed on a Binding in a policy.
    * 
* * Protobuf enum {@code google.iam.v1.BindingDelta.Action} */ - public enum Action - implements com.google.protobuf.ProtocolMessageEnum { + public enum Action implements com.google.protobuf.ProtocolMessageEnum { /** + * + * *
      * Unspecified.
      * 
@@ -131,6 +161,8 @@ public enum Action */ ACTION_UNSPECIFIED(0), /** + * + * *
      * Addition of a Binding.
      * 
@@ -139,6 +171,8 @@ public enum Action */ ADD(1), /** + * + * *
      * Removal of a Binding.
      * 
@@ -150,6 +184,8 @@ public enum Action ; /** + * + * *
      * Unspecified.
      * 
@@ -158,6 +194,8 @@ public enum Action */ public static final int ACTION_UNSPECIFIED_VALUE = 0; /** + * + * *
      * Addition of a Binding.
      * 
@@ -166,6 +204,8 @@ public enum Action */ public static final int ADD_VALUE = 1; /** + * + * *
      * Removal of a Binding.
      * 
@@ -174,64 +214,69 @@ public enum Action */ public static final int REMOVE_VALUE = 2; - public final int getNumber() { if (this == UNRECOGNIZED) { - throw new IllegalArgumentException( + 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. */ - @Deprecated + @java.lang.Deprecated public static Action 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 Action forNumber(int value) { switch (value) { - case 0: return ACTION_UNSPECIFIED; - case 1: return ADD; - case 2: return REMOVE; - default: return null; + case 0: + return ACTION_UNSPECIFIED; + case 1: + return ADD; + case 2: + return REMOVE; + default: + return null; } } - public static com.google.protobuf.Internal.EnumLiteMap - internalGetValueMap() { + public static com.google.protobuf.Internal.EnumLiteMap internalGetValueMap() { return internalValueMap; } - private static final com.google.protobuf.Internal.EnumLiteMap< - Action> internalValueMap = - new com.google.protobuf.Internal.EnumLiteMap() { - public Action findValueByNumber(int number) { - return Action.forNumber(number); - } - }; - public final com.google.protobuf.Descriptors.EnumValueDescriptor - getValueDescriptor() { + private static final com.google.protobuf.Internal.EnumLiteMap internalValueMap = + new com.google.protobuf.Internal.EnumLiteMap() { + public Action findValueByNumber(int number) { + return Action.forNumber(number); + } + }; + + public final com.google.protobuf.Descriptors.EnumValueDescriptor getValueDescriptor() { return getDescriptor().getValues().get(ordinal()); } - public final com.google.protobuf.Descriptors.EnumDescriptor - getDescriptorForType() { + + public final com.google.protobuf.Descriptors.EnumDescriptor getDescriptorForType() { return getDescriptor(); } - public static final com.google.protobuf.Descriptors.EnumDescriptor - getDescriptor() { - return BindingDelta.getDescriptor().getEnumTypes().get(0); + + public static final com.google.protobuf.Descriptors.EnumDescriptor getDescriptor() { + return com.google.iam.v1.BindingDelta.getDescriptor().getEnumTypes().get(0); } private static final Action[] VALUES = values(); - public static Action valueOf( - com.google.protobuf.Descriptors.EnumValueDescriptor desc) { + public static Action valueOf(com.google.protobuf.Descriptors.EnumValueDescriptor desc) { if (desc.getType() != getDescriptor()) { - throw new IllegalArgumentException( - "EnumValueDescriptor is not for this type."); + throw new java.lang.IllegalArgumentException("EnumValueDescriptor is not for this type."); } if (desc.getIndex() == -1) { return UNRECOGNIZED; @@ -251,33 +296,44 @@ private Action(int value) { public static final int ACTION_FIELD_NUMBER = 1; private int action_; /** + * + * *
    * The action that was performed on a Binding.
    * Required
    * 
* * .google.iam.v1.BindingDelta.Action action = 1; + * + * @return The enum numeric value on the wire for action. */ public int getActionValue() { return action_; } /** + * + * *
    * The action that was performed on a Binding.
    * Required
    * 
* * .google.iam.v1.BindingDelta.Action action = 1; + * + * @return The action. */ - public Action getAction() { + public com.google.iam.v1.BindingDelta.Action getAction() { @SuppressWarnings("deprecation") - Action result = Action.valueOf(action_); - return result == null ? Action.UNRECOGNIZED : result; + com.google.iam.v1.BindingDelta.Action result = + com.google.iam.v1.BindingDelta.Action.valueOf(action_); + return result == null ? com.google.iam.v1.BindingDelta.Action.UNRECOGNIZED : result; } public static final int ROLE_FIELD_NUMBER = 2; - private volatile Object role_; + private volatile java.lang.Object role_; /** + * + * *
    * Role that is assigned to `members`.
    * For example, `roles/viewer`, `roles/editor`, or `roles/owner`.
@@ -285,20 +341,23 @@ public Action getAction() {
    * 
* * string role = 2; + * + * @return The role. */ - public String getRole() { - Object ref = role_; - if (ref instanceof String) { - return (String) ref; + public java.lang.String getRole() { + java.lang.Object ref = role_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - String s = bs.toStringUtf8(); + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); role_ = s; return s; } } /** + * + * *
    * Role that is assigned to `members`.
    * For example, `roles/viewer`, `roles/editor`, or `roles/owner`.
@@ -306,14 +365,14 @@ public String getRole() {
    * 
* * string role = 2; + * + * @return The bytes for role. */ - public com.google.protobuf.ByteString - getRoleBytes() { - Object ref = role_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (String) ref); + public com.google.protobuf.ByteString getRoleBytes() { + java.lang.Object ref = role_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); role_ = b; return b; } else { @@ -322,8 +381,10 @@ public String getRole() { } public static final int MEMBER_FIELD_NUMBER = 3; - private volatile Object member_; + private volatile java.lang.Object member_; /** + * + * *
    * A single identity requesting access for a Cloud Platform resource.
    * Follows the same format of Binding.members.
@@ -331,20 +392,23 @@ public String getRole() {
    * 
* * string member = 3; + * + * @return The member. */ - public String getMember() { - Object ref = member_; - if (ref instanceof String) { - return (String) ref; + public java.lang.String getMember() { + java.lang.Object ref = member_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - String s = bs.toStringUtf8(); + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); member_ = s; return s; } } /** + * + * *
    * A single identity requesting access for a Cloud Platform resource.
    * Follows the same format of Binding.members.
@@ -352,14 +416,14 @@ public String getMember() {
    * 
* * string member = 3; + * + * @return The bytes for member. */ - public com.google.protobuf.ByteString - getMemberBytes() { - Object ref = member_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (String) ref); + public com.google.protobuf.ByteString getMemberBytes() { + java.lang.Object ref = member_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); member_ = b; return b; } else { @@ -370,26 +434,36 @@ public String getMember() { public static final int CONDITION_FIELD_NUMBER = 4; private com.google.type.Expr condition_; /** + * + * *
    * The condition that is associated with this binding.
    * 
* * .google.type.Expr condition = 4; + * + * @return Whether the condition field is set. */ public boolean hasCondition() { return condition_ != null; } /** + * + * *
    * The condition that is associated with this binding.
    * 
* * .google.type.Expr condition = 4; + * + * @return The condition. */ public com.google.type.Expr getCondition() { return condition_ == null ? com.google.type.Expr.getDefaultInstance() : condition_; } /** + * + * *
    * The condition that is associated with this binding.
    * 
@@ -401,7 +475,8 @@ public com.google.type.ExprOrBuilder getConditionOrBuilder() { } private byte memoizedIsInitialized = -1; - @Override + + @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; if (isInitialized == 1) return true; @@ -411,10 +486,9 @@ public final boolean isInitialized() { return true; } - @Override - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - if (action_ != Action.ACTION_UNSPECIFIED.getNumber()) { + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { + if (action_ != com.google.iam.v1.BindingDelta.Action.ACTION_UNSPECIFIED.getNumber()) { output.writeEnum(1, action_); } if (!getRoleBytes().isEmpty()) { @@ -429,15 +503,14 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) unknownFields.writeTo(output); } - @Override + @java.lang.Override public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; - if (action_ != Action.ACTION_UNSPECIFIED.getNumber()) { - size += com.google.protobuf.CodedOutputStream - .computeEnumSize(1, action_); + if (action_ != com.google.iam.v1.BindingDelta.Action.ACTION_UNSPECIFIED.getNumber()) { + size += com.google.protobuf.CodedOutputStream.computeEnumSize(1, action_); } if (!getRoleBytes().isEmpty()) { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(2, role_); @@ -446,39 +519,35 @@ public int getSerializedSize() { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(3, member_); } if (condition_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(4, getCondition()); + size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, getCondition()); } size += unknownFields.getSerializedSize(); memoizedSize = size; return size; } - @Override - public boolean equals(final Object obj) { + @java.lang.Override + public boolean equals(final java.lang.Object obj) { if (obj == this) { - return true; + return true; } - if (!(obj instanceof BindingDelta)) { + if (!(obj instanceof com.google.iam.v1.BindingDelta)) { return super.equals(obj); } - BindingDelta other = (BindingDelta) obj; + com.google.iam.v1.BindingDelta other = (com.google.iam.v1.BindingDelta) obj; if (action_ != other.action_) return false; - if (!getRole() - .equals(other.getRole())) return false; - if (!getMember() - .equals(other.getMember())) return false; + if (!getRole().equals(other.getRole())) return false; + if (!getMember().equals(other.getMember())) return false; if (hasCondition() != other.hasCondition()) return false; if (hasCondition()) { - if (!getCondition() - .equals(other.getCondition())) return false; + if (!getCondition().equals(other.getCondition())) return false; } if (!unknownFields.equals(other.unknownFields)) return false; return true; } - @Override + @java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; @@ -500,97 +569,103 @@ public int hashCode() { return hash; } - public static BindingDelta parseFrom( - java.nio.ByteBuffer data) + public static com.google.iam.v1.BindingDelta parseFrom(java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } - public static BindingDelta parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + + public static com.google.iam.v1.BindingDelta parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static BindingDelta parseFrom( - com.google.protobuf.ByteString data) + + public static com.google.iam.v1.BindingDelta parseFrom(com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } - public static BindingDelta parseFrom( + + public static com.google.iam.v1.BindingDelta parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static BindingDelta parseFrom(byte[] data) + + public static com.google.iam.v1.BindingDelta parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } - public static BindingDelta parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + + public static com.google.iam.v1.BindingDelta parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static BindingDelta parseFrom(java.io.InputStream input) + + public static com.google.iam.v1.BindingDelta parseFrom(java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } - public static BindingDelta parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + + public static com.google.iam.v1.BindingDelta parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } - public static BindingDelta parseDelimitedFrom(java.io.InputStream input) + + public static com.google.iam.v1.BindingDelta parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } - public static BindingDelta parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + + public static com.google.iam.v1.BindingDelta parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); } - public static BindingDelta parseFrom( - com.google.protobuf.CodedInputStream input) + + public static com.google.iam.v1.BindingDelta parseFrom(com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } - public static BindingDelta parseFrom( + + public static com.google.iam.v1.BindingDelta parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); } - @Override - public Builder newBuilderForType() { return newBuilder(); } public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } - public static Builder newBuilder(BindingDelta prototype) { + + public static Builder newBuilder(com.google.iam.v1.BindingDelta prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } - @Override + + @java.lang.Override public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } - @Override - protected Builder newBuilderForType( - BuilderParent parent) { + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** + * + * *
    * One delta entry for Binding. Each individual change (only one member in each
    * entry) to a binding will be a separate entry.
@@ -598,21 +673,21 @@ protected Builder newBuilderForType(
    *
    * Protobuf type {@code google.iam.v1.BindingDelta}
    */
-  public static final class Builder extends
-      com.google.protobuf.GeneratedMessageV3.Builder implements
+  public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder
+      implements
       // @@protoc_insertion_point(builder_implements:google.iam.v1.BindingDelta)
       com.google.iam.v1.BindingDeltaOrBuilder {
-    public static final com.google.protobuf.Descriptors.Descriptor
-        getDescriptor() {
-      return PolicyProto.internal_static_google_iam_v1_BindingDelta_descriptor;
+    public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() {
+      return com.google.iam.v1.PolicyProto.internal_static_google_iam_v1_BindingDelta_descriptor;
     }
 
-    @Override
-    protected FieldAccessorTable
+    @java.lang.Override
+    protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
         internalGetFieldAccessorTable() {
-      return PolicyProto.internal_static_google_iam_v1_BindingDelta_fieldAccessorTable
+      return com.google.iam.v1.PolicyProto
+          .internal_static_google_iam_v1_BindingDelta_fieldAccessorTable
           .ensureFieldAccessorsInitialized(
-              BindingDelta.class, Builder.class);
+              com.google.iam.v1.BindingDelta.class, com.google.iam.v1.BindingDelta.Builder.class);
     }
 
     // Construct using com.google.iam.v1.BindingDelta.newBuilder()
@@ -620,17 +695,16 @@ private Builder() {
       maybeForceBuilderInitialization();
     }
 
-    private Builder(
-        BuilderParent parent) {
+    private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
       super(parent);
       maybeForceBuilderInitialization();
     }
+
     private void maybeForceBuilderInitialization() {
-      if (com.google.protobuf.GeneratedMessageV3
-              .alwaysUseFieldBuilders) {
-      }
+      if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {}
     }
-    @Override
+
+    @java.lang.Override
     public Builder clear() {
       super.clear();
       action_ = 0;
@@ -648,29 +722,28 @@ public Builder clear() {
       return this;
     }
 
-    @Override
-    public com.google.protobuf.Descriptors.Descriptor
-        getDescriptorForType() {
-      return PolicyProto.internal_static_google_iam_v1_BindingDelta_descriptor;
+    @java.lang.Override
+    public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() {
+      return com.google.iam.v1.PolicyProto.internal_static_google_iam_v1_BindingDelta_descriptor;
     }
 
-    @Override
-    public BindingDelta getDefaultInstanceForType() {
-      return BindingDelta.getDefaultInstance();
+    @java.lang.Override
+    public com.google.iam.v1.BindingDelta getDefaultInstanceForType() {
+      return com.google.iam.v1.BindingDelta.getDefaultInstance();
     }
 
-    @Override
-    public BindingDelta build() {
-      BindingDelta result = buildPartial();
+    @java.lang.Override
+    public com.google.iam.v1.BindingDelta build() {
+      com.google.iam.v1.BindingDelta result = buildPartial();
       if (!result.isInitialized()) {
         throw newUninitializedMessageException(result);
       }
       return result;
     }
 
-    @Override
-    public BindingDelta buildPartial() {
-      BindingDelta result = new BindingDelta(this);
+    @java.lang.Override
+    public com.google.iam.v1.BindingDelta buildPartial() {
+      com.google.iam.v1.BindingDelta result = new com.google.iam.v1.BindingDelta(this);
       result.action_ = action_;
       result.role_ = role_;
       result.member_ = member_;
@@ -683,50 +756,51 @@ public BindingDelta buildPartial() {
       return result;
     }
 
-    @Override
+    @java.lang.Override
     public Builder clone() {
       return super.clone();
     }
-    @Override
+
+    @java.lang.Override
     public Builder setField(
-        com.google.protobuf.Descriptors.FieldDescriptor field,
-        Object value) {
+        com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) {
       return super.setField(field, value);
     }
-    @Override
-    public Builder clearField(
-        com.google.protobuf.Descriptors.FieldDescriptor field) {
+
+    @java.lang.Override
+    public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) {
       return super.clearField(field);
     }
-    @Override
-    public Builder clearOneof(
-        com.google.protobuf.Descriptors.OneofDescriptor oneof) {
+
+    @java.lang.Override
+    public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) {
       return super.clearOneof(oneof);
     }
-    @Override
+
+    @java.lang.Override
     public Builder setRepeatedField(
-        com.google.protobuf.Descriptors.FieldDescriptor field,
-        int index, Object value) {
+        com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) {
       return super.setRepeatedField(field, index, value);
     }
-    @Override
+
+    @java.lang.Override
     public Builder addRepeatedField(
-        com.google.protobuf.Descriptors.FieldDescriptor field,
-        Object value) {
+        com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) {
       return super.addRepeatedField(field, value);
     }
-    @Override
+
+    @java.lang.Override
     public Builder mergeFrom(com.google.protobuf.Message other) {
-      if (other instanceof BindingDelta) {
-        return mergeFrom((BindingDelta)other);
+      if (other instanceof com.google.iam.v1.BindingDelta) {
+        return mergeFrom((com.google.iam.v1.BindingDelta) other);
       } else {
         super.mergeFrom(other);
         return this;
       }
     }
 
-    public Builder mergeFrom(BindingDelta other) {
-      if (other == BindingDelta.getDefaultInstance()) return this;
+    public Builder mergeFrom(com.google.iam.v1.BindingDelta other) {
+      if (other == com.google.iam.v1.BindingDelta.getDefaultInstance()) return this;
       if (other.action_ != 0) {
         setActionValue(other.getActionValue());
       }
@@ -746,21 +820,21 @@ public Builder mergeFrom(BindingDelta other) {
       return this;
     }
 
-    @Override
+    @java.lang.Override
     public final boolean isInitialized() {
       return true;
     }
 
-    @Override
+    @java.lang.Override
     public Builder mergeFrom(
         com.google.protobuf.CodedInputStream input,
         com.google.protobuf.ExtensionRegistryLite extensionRegistry)
         throws java.io.IOException {
-      BindingDelta parsedMessage = null;
+      com.google.iam.v1.BindingDelta parsedMessage = null;
       try {
         parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
       } catch (com.google.protobuf.InvalidProtocolBufferException e) {
-        parsedMessage = (BindingDelta) e.getUnfinishedMessage();
+        parsedMessage = (com.google.iam.v1.BindingDelta) e.getUnfinishedMessage();
         throw e.unwrapIOException();
       } finally {
         if (parsedMessage != null) {
@@ -772,23 +846,32 @@ public Builder mergeFrom(
 
     private int action_ = 0;
     /**
+     *
+     *
      * 
      * The action that was performed on a Binding.
      * Required
      * 
* * .google.iam.v1.BindingDelta.Action action = 1; + * + * @return The enum numeric value on the wire for action. */ public int getActionValue() { return action_; } /** + * + * *
      * The action that was performed on a Binding.
      * Required
      * 
* * .google.iam.v1.BindingDelta.Action action = 1; + * + * @param value The enum numeric value on the wire for action to set. + * @return This builder for chaining. */ public Builder setActionValue(int value) { action_ = value; @@ -796,52 +879,68 @@ public Builder setActionValue(int value) { return this; } /** + * + * *
      * The action that was performed on a Binding.
      * Required
      * 
* * .google.iam.v1.BindingDelta.Action action = 1; + * + * @return The action. */ - public Action getAction() { + public com.google.iam.v1.BindingDelta.Action getAction() { @SuppressWarnings("deprecation") - Action result = Action.valueOf(action_); - return result == null ? Action.UNRECOGNIZED : result; + com.google.iam.v1.BindingDelta.Action result = + com.google.iam.v1.BindingDelta.Action.valueOf(action_); + return result == null ? com.google.iam.v1.BindingDelta.Action.UNRECOGNIZED : result; } /** + * + * *
      * The action that was performed on a Binding.
      * Required
      * 
* * .google.iam.v1.BindingDelta.Action action = 1; + * + * @param value The action to set. + * @return This builder for chaining. */ - public Builder setAction(Action value) { + public Builder setAction(com.google.iam.v1.BindingDelta.Action value) { if (value == null) { throw new NullPointerException(); } - + action_ = value.getNumber(); onChanged(); return this; } /** + * + * *
      * The action that was performed on a Binding.
      * Required
      * 
* * .google.iam.v1.BindingDelta.Action action = 1; + * + * @return This builder for chaining. */ public Builder clearAction() { - + action_ = 0; onChanged(); return this; } - private Object role_ = ""; + private java.lang.Object role_ = ""; /** + * + * *
      * Role that is assigned to `members`.
      * For example, `roles/viewer`, `roles/editor`, or `roles/owner`.
@@ -849,20 +948,23 @@ public Builder clearAction() {
      * 
* * string role = 2; + * + * @return The role. */ - public String getRole() { - Object ref = role_; - if (!(ref instanceof String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - String s = bs.toStringUtf8(); + public java.lang.String getRole() { + java.lang.Object ref = role_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); role_ = s; return s; } else { - return (String) ref; + return (java.lang.String) ref; } } /** + * + * *
      * Role that is assigned to `members`.
      * For example, `roles/viewer`, `roles/editor`, or `roles/owner`.
@@ -870,14 +972,14 @@ public String getRole() {
      * 
* * string role = 2; + * + * @return The bytes for role. */ - public com.google.protobuf.ByteString - getRoleBytes() { - Object ref = role_; + public com.google.protobuf.ByteString getRoleBytes() { + java.lang.Object ref = role_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); role_ = b; return b; } else { @@ -885,6 +987,8 @@ public String getRole() { } } /** + * + * *
      * Role that is assigned to `members`.
      * For example, `roles/viewer`, `roles/editor`, or `roles/owner`.
@@ -892,18 +996,22 @@ public String getRole() {
      * 
* * string role = 2; + * + * @param value The role to set. + * @return This builder for chaining. */ - public Builder setRole( - String value) { + public Builder setRole(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + role_ = value; onChanged(); return this; } /** + * + * *
      * Role that is assigned to `members`.
      * For example, `roles/viewer`, `roles/editor`, or `roles/owner`.
@@ -911,14 +1019,18 @@ public Builder setRole(
      * 
* * string role = 2; + * + * @return This builder for chaining. */ public Builder clearRole() { - + role_ = getDefaultInstance().getRole(); onChanged(); return this; } /** + * + * *
      * Role that is assigned to `members`.
      * For example, `roles/viewer`, `roles/editor`, or `roles/owner`.
@@ -926,21 +1038,25 @@ public Builder clearRole() {
      * 
* * string role = 2; + * + * @param value The bytes for role to set. + * @return This builder for chaining. */ - public Builder setRoleBytes( - com.google.protobuf.ByteString value) { + public Builder setRoleBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + role_ = value; onChanged(); return this; } - private Object member_ = ""; + private java.lang.Object member_ = ""; /** + * + * *
      * A single identity requesting access for a Cloud Platform resource.
      * Follows the same format of Binding.members.
@@ -948,20 +1064,23 @@ public Builder setRoleBytes(
      * 
* * string member = 3; + * + * @return The member. */ - public String getMember() { - Object ref = member_; - if (!(ref instanceof String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - String s = bs.toStringUtf8(); + public java.lang.String getMember() { + java.lang.Object ref = member_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); member_ = s; return s; } else { - return (String) ref; + return (java.lang.String) ref; } } /** + * + * *
      * A single identity requesting access for a Cloud Platform resource.
      * Follows the same format of Binding.members.
@@ -969,14 +1088,14 @@ public String getMember() {
      * 
* * string member = 3; + * + * @return The bytes for member. */ - public com.google.protobuf.ByteString - getMemberBytes() { - Object ref = member_; + public com.google.protobuf.ByteString getMemberBytes() { + java.lang.Object ref = member_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); member_ = b; return b; } else { @@ -984,6 +1103,8 @@ public String getMember() { } } /** + * + * *
      * A single identity requesting access for a Cloud Platform resource.
      * Follows the same format of Binding.members.
@@ -991,18 +1112,22 @@ public String getMember() {
      * 
* * string member = 3; + * + * @param value The member to set. + * @return This builder for chaining. */ - public Builder setMember( - String value) { + public Builder setMember(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + member_ = value; onChanged(); return this; } /** + * + * *
      * A single identity requesting access for a Cloud Platform resource.
      * Follows the same format of Binding.members.
@@ -1010,14 +1135,18 @@ public Builder setMember(
      * 
* * string member = 3; + * + * @return This builder for chaining. */ public Builder clearMember() { - + member_ = getDefaultInstance().getMember(); onChanged(); return this; } /** + * + * *
      * A single identity requesting access for a Cloud Platform resource.
      * Follows the same format of Binding.members.
@@ -1025,14 +1154,16 @@ public Builder clearMember() {
      * 
* * string member = 3; + * + * @param value The bytes for member to set. + * @return This builder for chaining. */ - public Builder setMemberBytes( - com.google.protobuf.ByteString value) { + public Builder setMemberBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + member_ = value; onChanged(); return this; @@ -1040,23 +1171,32 @@ public Builder setMemberBytes( private com.google.type.Expr condition_; private com.google.protobuf.SingleFieldBuilderV3< - com.google.type.Expr, com.google.type.Expr.Builder, com.google.type.ExprOrBuilder> conditionBuilder_; + com.google.type.Expr, com.google.type.Expr.Builder, com.google.type.ExprOrBuilder> + conditionBuilder_; /** + * + * *
      * The condition that is associated with this binding.
      * 
* * .google.type.Expr condition = 4; + * + * @return Whether the condition field is set. */ public boolean hasCondition() { return conditionBuilder_ != null || condition_ != null; } /** + * + * *
      * The condition that is associated with this binding.
      * 
* * .google.type.Expr condition = 4; + * + * @return The condition. */ public com.google.type.Expr getCondition() { if (conditionBuilder_ == null) { @@ -1066,6 +1206,8 @@ public com.google.type.Expr getCondition() { } } /** + * + * *
      * The condition that is associated with this binding.
      * 
@@ -1086,14 +1228,15 @@ public Builder setCondition(com.google.type.Expr value) { return this; } /** + * + * *
      * The condition that is associated with this binding.
      * 
* * .google.type.Expr condition = 4; */ - public Builder setCondition( - com.google.type.Expr.Builder builderForValue) { + public Builder setCondition(com.google.type.Expr.Builder builderForValue) { if (conditionBuilder_ == null) { condition_ = builderForValue.build(); onChanged(); @@ -1104,6 +1247,8 @@ public Builder setCondition( return this; } /** + * + * *
      * The condition that is associated with this binding.
      * 
@@ -1113,8 +1258,7 @@ public Builder setCondition( public Builder mergeCondition(com.google.type.Expr value) { if (conditionBuilder_ == null) { if (condition_ != null) { - condition_ = - com.google.type.Expr.newBuilder(condition_).mergeFrom(value).buildPartial(); + condition_ = com.google.type.Expr.newBuilder(condition_).mergeFrom(value).buildPartial(); } else { condition_ = value; } @@ -1126,6 +1270,8 @@ public Builder mergeCondition(com.google.type.Expr value) { return this; } /** + * + * *
      * The condition that is associated with this binding.
      * 
@@ -1144,6 +1290,8 @@ public Builder clearCondition() { return this; } /** + * + * *
      * The condition that is associated with this binding.
      * 
@@ -1151,11 +1299,13 @@ public Builder clearCondition() { * .google.type.Expr condition = 4; */ public com.google.type.Expr.Builder getConditionBuilder() { - + onChanged(); return getConditionFieldBuilder().getBuilder(); } /** + * + * *
      * The condition that is associated with this binding.
      * 
@@ -1166,11 +1316,12 @@ public com.google.type.ExprOrBuilder getConditionOrBuilder() { if (conditionBuilder_ != null) { return conditionBuilder_.getMessageOrBuilder(); } else { - return condition_ == null ? - com.google.type.Expr.getDefaultInstance() : condition_; + return condition_ == null ? com.google.type.Expr.getDefaultInstance() : condition_; } } /** + * + * *
      * The condition that is associated with this binding.
      * 
@@ -1178,68 +1329,65 @@ public com.google.type.ExprOrBuilder getConditionOrBuilder() { * .google.type.Expr condition = 4; */ private com.google.protobuf.SingleFieldBuilderV3< - com.google.type.Expr, com.google.type.Expr.Builder, com.google.type.ExprOrBuilder> + com.google.type.Expr, com.google.type.Expr.Builder, com.google.type.ExprOrBuilder> getConditionFieldBuilder() { if (conditionBuilder_ == null) { - conditionBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.type.Expr, com.google.type.Expr.Builder, com.google.type.ExprOrBuilder>( - getCondition(), - getParentForChildren(), - isClean()); + conditionBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.type.Expr, com.google.type.Expr.Builder, com.google.type.ExprOrBuilder>( + getCondition(), getParentForChildren(), isClean()); condition_ = null; } return conditionBuilder_; } - @Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } - @Override + @java.lang.Override public final Builder mergeUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return super.mergeUnknownFields(unknownFields); } - // @@protoc_insertion_point(builder_scope:google.iam.v1.BindingDelta) } // @@protoc_insertion_point(class_scope:google.iam.v1.BindingDelta) - private static final BindingDelta DEFAULT_INSTANCE; + private static final com.google.iam.v1.BindingDelta DEFAULT_INSTANCE; + static { - DEFAULT_INSTANCE = new BindingDelta(); + DEFAULT_INSTANCE = new com.google.iam.v1.BindingDelta(); } - public static BindingDelta getDefaultInstance() { + public static com.google.iam.v1.BindingDelta getDefaultInstance() { return DEFAULT_INSTANCE; } - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - @Override - public BindingDelta parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new BindingDelta(input, extensionRegistry); - } - }; + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public BindingDelta parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new BindingDelta(input, extensionRegistry); + } + }; public static com.google.protobuf.Parser parser() { return PARSER; } - @Override + @java.lang.Override public com.google.protobuf.Parser getParserForType() { return PARSER; } - @Override - public BindingDelta getDefaultInstanceForType() { + @java.lang.Override + public com.google.iam.v1.BindingDelta getDefaultInstanceForType() { return DEFAULT_INSTANCE; } - } - diff --git a/proto-google-iam-v1/src/main/java/com/google/iam/v1/BindingDeltaOrBuilder.java b/proto-google-iam-v1/src/main/java/com/google/iam/v1/BindingDeltaOrBuilder.java index ffed4bd8..a2959294 100644 --- a/proto-google-iam-v1/src/main/java/com/google/iam/v1/BindingDeltaOrBuilder.java +++ b/proto-google-iam-v1/src/main/java/com/google/iam/v1/BindingDeltaOrBuilder.java @@ -1,32 +1,58 @@ +/* + * 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/iam/v1/policy.proto package com.google.iam.v1; -public interface BindingDeltaOrBuilder extends +public interface BindingDeltaOrBuilder + extends // @@protoc_insertion_point(interface_extends:google.iam.v1.BindingDelta) com.google.protobuf.MessageOrBuilder { /** + * + * *
    * The action that was performed on a Binding.
    * Required
    * 
* * .google.iam.v1.BindingDelta.Action action = 1; + * + * @return The enum numeric value on the wire for action. */ int getActionValue(); /** + * + * *
    * The action that was performed on a Binding.
    * Required
    * 
* * .google.iam.v1.BindingDelta.Action action = 1; + * + * @return The action. */ - BindingDelta.Action getAction(); + com.google.iam.v1.BindingDelta.Action getAction(); /** + * + * *
    * Role that is assigned to `members`.
    * For example, `roles/viewer`, `roles/editor`, or `roles/owner`.
@@ -34,9 +60,13 @@ public interface BindingDeltaOrBuilder extends
    * 
* * string role = 2; + * + * @return The role. */ - String getRole(); + java.lang.String getRole(); /** + * + * *
    * Role that is assigned to `members`.
    * For example, `roles/viewer`, `roles/editor`, or `roles/owner`.
@@ -44,11 +74,14 @@ public interface BindingDeltaOrBuilder extends
    * 
* * string role = 2; + * + * @return The bytes for role. */ - com.google.protobuf.ByteString - getRoleBytes(); + com.google.protobuf.ByteString getRoleBytes(); /** + * + * *
    * A single identity requesting access for a Cloud Platform resource.
    * Follows the same format of Binding.members.
@@ -56,9 +89,13 @@ public interface BindingDeltaOrBuilder extends
    * 
* * string member = 3; + * + * @return The member. */ - String getMember(); + java.lang.String getMember(); /** + * + * *
    * A single identity requesting access for a Cloud Platform resource.
    * Follows the same format of Binding.members.
@@ -66,27 +103,38 @@ public interface BindingDeltaOrBuilder extends
    * 
* * string member = 3; + * + * @return The bytes for member. */ - com.google.protobuf.ByteString - getMemberBytes(); + com.google.protobuf.ByteString getMemberBytes(); /** + * + * *
    * The condition that is associated with this binding.
    * 
* * .google.type.Expr condition = 4; + * + * @return Whether the condition field is set. */ boolean hasCondition(); /** + * + * *
    * The condition that is associated with this binding.
    * 
* * .google.type.Expr condition = 4; + * + * @return The condition. */ com.google.type.Expr getCondition(); /** + * + * *
    * The condition that is associated with this binding.
    * 
diff --git a/proto-google-iam-v1/src/main/java/com/google/iam/v1/BindingOrBuilder.java b/proto-google-iam-v1/src/main/java/com/google/iam/v1/BindingOrBuilder.java index d43f6b8a..f51272f7 100644 --- a/proto-google-iam-v1/src/main/java/com/google/iam/v1/BindingOrBuilder.java +++ b/proto-google-iam-v1/src/main/java/com/google/iam/v1/BindingOrBuilder.java @@ -1,33 +1,58 @@ +/* + * 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/iam/v1/policy.proto package com.google.iam.v1; -public interface BindingOrBuilder extends +public interface BindingOrBuilder + extends // @@protoc_insertion_point(interface_extends:google.iam.v1.Binding) com.google.protobuf.MessageOrBuilder { /** + * + * *
    * Role that is assigned to `members`.
    * For example, `roles/viewer`, `roles/editor`, or `roles/owner`.
    * 
* * string role = 1; + * + * @return The role. */ - String getRole(); + java.lang.String getRole(); /** + * + * *
    * Role that is assigned to `members`.
    * For example, `roles/viewer`, `roles/editor`, or `roles/owner`.
    * 
* * string role = 1; + * + * @return The bytes for role. */ - com.google.protobuf.ByteString - getRoleBytes(); + com.google.protobuf.ByteString getRoleBytes(); /** + * + * *
    * Specifies the identities requesting access for a Cloud Platform resource.
    * `members` can have the following values:
@@ -46,10 +71,13 @@ public interface BindingOrBuilder extends
    * 
* * repeated string members = 2; + * + * @return A list containing the members. */ - java.util.List - getMembersList(); + java.util.List getMembersList(); /** + * + * *
    * Specifies the identities requesting access for a Cloud Platform resource.
    * `members` can have the following values:
@@ -68,9 +96,13 @@ public interface BindingOrBuilder extends
    * 
* * repeated string members = 2; + * + * @return The count of members. */ int getMembersCount(); /** + * + * *
    * Specifies the identities requesting access for a Cloud Platform resource.
    * `members` can have the following values:
@@ -89,9 +121,14 @@ public interface BindingOrBuilder extends
    * 
* * repeated string members = 2; + * + * @param index The index of the element to return. + * @return The members at the given index. */ - String getMembers(int index); + java.lang.String getMembers(int index); /** + * + * *
    * Specifies the identities requesting access for a Cloud Platform resource.
    * `members` can have the following values:
@@ -110,11 +147,15 @@ public interface BindingOrBuilder extends
    * 
* * repeated string members = 2; + * + * @param index The index of the value to return. + * @return The bytes of the members at the given index. */ - com.google.protobuf.ByteString - getMembersBytes(int index); + com.google.protobuf.ByteString getMembersBytes(int index); /** + * + * *
    * The condition that is associated with this binding.
    * NOTE: An unsatisfied condition will not allow user access via current
@@ -123,9 +164,13 @@ public interface BindingOrBuilder extends
    * 
* * .google.type.Expr condition = 3; + * + * @return Whether the condition field is set. */ boolean hasCondition(); /** + * + * *
    * The condition that is associated with this binding.
    * NOTE: An unsatisfied condition will not allow user access via current
@@ -134,9 +179,13 @@ public interface BindingOrBuilder extends
    * 
* * .google.type.Expr condition = 3; + * + * @return The condition. */ com.google.type.Expr getCondition(); /** + * + * *
    * The condition that is associated with this binding.
    * NOTE: An unsatisfied condition will not allow user access via current
diff --git a/proto-google-iam-v1/src/main/java/com/google/iam/v1/GetIamPolicyRequest.java b/proto-google-iam-v1/src/main/java/com/google/iam/v1/GetIamPolicyRequest.java
index 78432184..af0b3566 100644
--- a/proto-google-iam-v1/src/main/java/com/google/iam/v1/GetIamPolicyRequest.java
+++ b/proto-google-iam-v1/src/main/java/com/google/iam/v1/GetIamPolicyRequest.java
@@ -1,42 +1,65 @@
+/*
+ * 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/iam/v1/iam_policy.proto
 
 package com.google.iam.v1;
 
 /**
+ *
+ *
  * 
  * Request message for `GetIamPolicy` method.
  * 
* * Protobuf type {@code google.iam.v1.GetIamPolicyRequest} */ -public final class GetIamPolicyRequest extends - com.google.protobuf.GeneratedMessageV3 implements +public final class GetIamPolicyRequest extends com.google.protobuf.GeneratedMessageV3 + implements // @@protoc_insertion_point(message_implements:google.iam.v1.GetIamPolicyRequest) GetIamPolicyRequestOrBuilder { -private static final long serialVersionUID = 0L; + private static final long serialVersionUID = 0L; // Use GetIamPolicyRequest.newBuilder() to construct. private GetIamPolicyRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } + private GetIamPolicyRequest() { resource_ = ""; } - @Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new GetIamPolicyRequest(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } + private GetIamPolicyRequest( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { this(); if (extensionRegistry == null) { - throw new NullPointerException(); + throw new java.lang.NullPointerException(); } - int mutable_bitField0_ = 0; com.google.protobuf.UnknownFieldSet.Builder unknownFields = com.google.protobuf.UnknownFieldSet.newBuilder(); try { @@ -47,94 +70,108 @@ private GetIamPolicyRequest( case 0: done = true; break; - case 10: { - String s = input.readStringRequireUtf8(); + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); - resource_ = s; - break; - } - case 18: { - GetPolicyOptions.Builder subBuilder = null; - if (options_ != null) { - subBuilder = options_.toBuilder(); + resource_ = s; + break; } - options_ = input.readMessage(GetPolicyOptions.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(options_); - options_ = subBuilder.buildPartial(); + case 18: + { + com.google.iam.v1.GetPolicyOptions.Builder subBuilder = null; + if (options_ != null) { + subBuilder = options_.toBuilder(); + } + options_ = + input.readMessage(com.google.iam.v1.GetPolicyOptions.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(options_); + options_ = subBuilder.buildPartial(); + } + + break; } - - break; - } - default: { - if (!parseUnknownField( - input, unknownFields, extensionRegistry, tag)) { - done = true; + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; } - break; - } } } } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(this); } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException( - e).setUnfinishedMessage(this); + 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 IamPolicyProto.internal_static_google_iam_v1_GetIamPolicyRequest_descriptor; + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.iam.v1.IamPolicyProto + .internal_static_google_iam_v1_GetIamPolicyRequest_descriptor; } - @Override - protected FieldAccessorTable + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return IamPolicyProto.internal_static_google_iam_v1_GetIamPolicyRequest_fieldAccessorTable + return com.google.iam.v1.IamPolicyProto + .internal_static_google_iam_v1_GetIamPolicyRequest_fieldAccessorTable .ensureFieldAccessorsInitialized( - GetIamPolicyRequest.class, Builder.class); + com.google.iam.v1.GetIamPolicyRequest.class, + com.google.iam.v1.GetIamPolicyRequest.Builder.class); } public static final int RESOURCE_FIELD_NUMBER = 1; - private volatile Object resource_; + private volatile java.lang.Object resource_; /** + * + * *
    * REQUIRED: The resource for which the policy is being requested.
    * See the operation documentation for the appropriate value for this field.
    * 
* - * string resource = 1; + * + * string resource = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The resource. */ - public String getResource() { - Object ref = resource_; - if (ref instanceof String) { - return (String) ref; + public java.lang.String getResource() { + java.lang.Object ref = resource_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - String s = bs.toStringUtf8(); + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); resource_ = s; return s; } } /** + * + * *
    * REQUIRED: The resource for which the policy is being requested.
    * See the operation documentation for the appropriate value for this field.
    * 
* - * string resource = 1; + * + * string resource = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for resource. */ - public com.google.protobuf.ByteString - getResourceBytes() { - Object ref = resource_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (String) ref); + public com.google.protobuf.ByteString getResourceBytes() { + java.lang.Object ref = resource_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); resource_ = b; return b; } else { @@ -143,30 +180,40 @@ public String getResource() { } public static final int OPTIONS_FIELD_NUMBER = 2; - private GetPolicyOptions options_; + private com.google.iam.v1.GetPolicyOptions options_; /** + * + * *
    * OPTIONAL: A `GetPolicyOptions` object for specifying options to
    * `GetIamPolicy`. This field is only used by Cloud IAM.
    * 
* * .google.iam.v1.GetPolicyOptions options = 2; + * + * @return Whether the options field is set. */ public boolean hasOptions() { return options_ != null; } /** + * + * *
    * OPTIONAL: A `GetPolicyOptions` object for specifying options to
    * `GetIamPolicy`. This field is only used by Cloud IAM.
    * 
* * .google.iam.v1.GetPolicyOptions options = 2; + * + * @return The options. */ - public GetPolicyOptions getOptions() { - return options_ == null ? GetPolicyOptions.getDefaultInstance() : options_; + public com.google.iam.v1.GetPolicyOptions getOptions() { + return options_ == null ? com.google.iam.v1.GetPolicyOptions.getDefaultInstance() : options_; } /** + * + * *
    * OPTIONAL: A `GetPolicyOptions` object for specifying options to
    * `GetIamPolicy`. This field is only used by Cloud IAM.
@@ -179,7 +226,8 @@ public com.google.iam.v1.GetPolicyOptionsOrBuilder getOptionsOrBuilder() {
   }
 
   private byte memoizedIsInitialized = -1;
-  @Override
+
+  @java.lang.Override
   public final boolean isInitialized() {
     byte isInitialized = memoizedIsInitialized;
     if (isInitialized == 1) return true;
@@ -189,9 +237,8 @@ public final boolean isInitialized() {
     return true;
   }
 
-  @Override
-  public void writeTo(com.google.protobuf.CodedOutputStream output)
-                      throws java.io.IOException {
+  @java.lang.Override
+  public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException {
     if (!getResourceBytes().isEmpty()) {
       com.google.protobuf.GeneratedMessageV3.writeString(output, 1, resource_);
     }
@@ -201,7 +248,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output)
     unknownFields.writeTo(output);
   }
 
-  @Override
+  @java.lang.Override
   public int getSerializedSize() {
     int size = memoizedSize;
     if (size != -1) return size;
@@ -211,36 +258,33 @@ public int getSerializedSize() {
       size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, resource_);
     }
     if (options_ != null) {
-      size += com.google.protobuf.CodedOutputStream
-        .computeMessageSize(2, getOptions());
+      size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getOptions());
     }
     size += unknownFields.getSerializedSize();
     memoizedSize = size;
     return size;
   }
 
-  @Override
-  public boolean equals(final Object obj) {
+  @java.lang.Override
+  public boolean equals(final java.lang.Object obj) {
     if (obj == this) {
-     return true;
+      return true;
     }
-    if (!(obj instanceof GetIamPolicyRequest)) {
+    if (!(obj instanceof com.google.iam.v1.GetIamPolicyRequest)) {
       return super.equals(obj);
     }
-    GetIamPolicyRequest other = (GetIamPolicyRequest) obj;
+    com.google.iam.v1.GetIamPolicyRequest other = (com.google.iam.v1.GetIamPolicyRequest) obj;
 
-    if (!getResource()
-        .equals(other.getResource())) return false;
+    if (!getResource().equals(other.getResource())) return false;
     if (hasOptions() != other.hasOptions()) return false;
     if (hasOptions()) {
-      if (!getOptions()
-          .equals(other.getOptions())) return false;
+      if (!getOptions().equals(other.getOptions())) return false;
     }
     if (!unknownFields.equals(other.unknownFields)) return false;
     return true;
   }
 
-  @Override
+  @java.lang.Override
   public int hashCode() {
     if (memoizedHashCode != 0) {
       return memoizedHashCode;
@@ -258,118 +302,126 @@ public int hashCode() {
     return hash;
   }
 
-  public static GetIamPolicyRequest parseFrom(
-      java.nio.ByteBuffer data)
+  public static com.google.iam.v1.GetIamPolicyRequest parseFrom(java.nio.ByteBuffer data)
       throws com.google.protobuf.InvalidProtocolBufferException {
     return PARSER.parseFrom(data);
   }
-  public static GetIamPolicyRequest parseFrom(
-      java.nio.ByteBuffer data,
-      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+
+  public static com.google.iam.v1.GetIamPolicyRequest parseFrom(
+      java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
       throws com.google.protobuf.InvalidProtocolBufferException {
     return PARSER.parseFrom(data, extensionRegistry);
   }
-  public static GetIamPolicyRequest parseFrom(
-      com.google.protobuf.ByteString data)
+
+  public static com.google.iam.v1.GetIamPolicyRequest parseFrom(com.google.protobuf.ByteString data)
       throws com.google.protobuf.InvalidProtocolBufferException {
     return PARSER.parseFrom(data);
   }
-  public static GetIamPolicyRequest parseFrom(
+
+  public static com.google.iam.v1.GetIamPolicyRequest parseFrom(
       com.google.protobuf.ByteString data,
       com.google.protobuf.ExtensionRegistryLite extensionRegistry)
       throws com.google.protobuf.InvalidProtocolBufferException {
     return PARSER.parseFrom(data, extensionRegistry);
   }
-  public static GetIamPolicyRequest parseFrom(byte[] data)
+
+  public static com.google.iam.v1.GetIamPolicyRequest parseFrom(byte[] data)
       throws com.google.protobuf.InvalidProtocolBufferException {
     return PARSER.parseFrom(data);
   }
-  public static GetIamPolicyRequest parseFrom(
-      byte[] data,
-      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+
+  public static com.google.iam.v1.GetIamPolicyRequest parseFrom(
+      byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
       throws com.google.protobuf.InvalidProtocolBufferException {
     return PARSER.parseFrom(data, extensionRegistry);
   }
-  public static GetIamPolicyRequest parseFrom(java.io.InputStream input)
+
+  public static com.google.iam.v1.GetIamPolicyRequest parseFrom(java.io.InputStream input)
       throws java.io.IOException {
-    return com.google.protobuf.GeneratedMessageV3
-        .parseWithIOException(PARSER, input);
+    return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
   }
-  public static GetIamPolicyRequest parseFrom(
-      java.io.InputStream input,
-      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+
+  public static com.google.iam.v1.GetIamPolicyRequest parseFrom(
+      java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
       throws java.io.IOException {
-    return com.google.protobuf.GeneratedMessageV3
-        .parseWithIOException(PARSER, input, extensionRegistry);
+    return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
+        PARSER, input, extensionRegistry);
   }
-  public static GetIamPolicyRequest parseDelimitedFrom(java.io.InputStream input)
+
+  public static com.google.iam.v1.GetIamPolicyRequest parseDelimitedFrom(java.io.InputStream input)
       throws java.io.IOException {
-    return com.google.protobuf.GeneratedMessageV3
-        .parseDelimitedWithIOException(PARSER, input);
+    return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input);
   }
-  public static GetIamPolicyRequest parseDelimitedFrom(
-      java.io.InputStream input,
-      com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+
+  public static com.google.iam.v1.GetIamPolicyRequest parseDelimitedFrom(
+      java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
       throws java.io.IOException {
-    return com.google.protobuf.GeneratedMessageV3
-        .parseDelimitedWithIOException(PARSER, input, extensionRegistry);
+    return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(
+        PARSER, input, extensionRegistry);
   }
-  public static GetIamPolicyRequest parseFrom(
-      com.google.protobuf.CodedInputStream input)
-      throws java.io.IOException {
-    return com.google.protobuf.GeneratedMessageV3
-        .parseWithIOException(PARSER, input);
+
+  public static com.google.iam.v1.GetIamPolicyRequest parseFrom(
+      com.google.protobuf.CodedInputStream input) throws java.io.IOException {
+    return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input);
   }
-  public static GetIamPolicyRequest parseFrom(
+
+  public static com.google.iam.v1.GetIamPolicyRequest parseFrom(
       com.google.protobuf.CodedInputStream input,
       com.google.protobuf.ExtensionRegistryLite extensionRegistry)
       throws java.io.IOException {
-    return com.google.protobuf.GeneratedMessageV3
-        .parseWithIOException(PARSER, input, extensionRegistry);
+    return com.google.protobuf.GeneratedMessageV3.parseWithIOException(
+        PARSER, input, extensionRegistry);
+  }
+
+  @java.lang.Override
+  public Builder newBuilderForType() {
+    return newBuilder();
   }
 
-  @Override
-  public Builder newBuilderForType() { return newBuilder(); }
   public static Builder newBuilder() {
     return DEFAULT_INSTANCE.toBuilder();
   }
-  public static Builder newBuilder(GetIamPolicyRequest prototype) {
+
+  public static Builder newBuilder(com.google.iam.v1.GetIamPolicyRequest prototype) {
     return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
   }
-  @Override
+
+  @java.lang.Override
   public Builder toBuilder() {
-    return this == DEFAULT_INSTANCE
-        ? new Builder() : new Builder().mergeFrom(this);
+    return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this);
   }
 
-  @Override
-  protected Builder newBuilderForType(
-      BuilderParent parent) {
+  @java.lang.Override
+  protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
     Builder builder = new Builder(parent);
     return builder;
   }
   /**
+   *
+   *
    * 
    * Request message for `GetIamPolicy` method.
    * 
* * Protobuf type {@code google.iam.v1.GetIamPolicyRequest} */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements // @@protoc_insertion_point(builder_implements:google.iam.v1.GetIamPolicyRequest) com.google.iam.v1.GetIamPolicyRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return IamPolicyProto.internal_static_google_iam_v1_GetIamPolicyRequest_descriptor; + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.iam.v1.IamPolicyProto + .internal_static_google_iam_v1_GetIamPolicyRequest_descriptor; } - @Override - protected FieldAccessorTable + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return IamPolicyProto.internal_static_google_iam_v1_GetIamPolicyRequest_fieldAccessorTable + return com.google.iam.v1.IamPolicyProto + .internal_static_google_iam_v1_GetIamPolicyRequest_fieldAccessorTable .ensureFieldAccessorsInitialized( - GetIamPolicyRequest.class, Builder.class); + com.google.iam.v1.GetIamPolicyRequest.class, + com.google.iam.v1.GetIamPolicyRequest.Builder.class); } // Construct using com.google.iam.v1.GetIamPolicyRequest.newBuilder() @@ -377,17 +429,16 @@ private Builder() { maybeForceBuilderInitialization(); } - private Builder( - BuilderParent parent) { + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); maybeForceBuilderInitialization(); } + private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } - @Override + + @java.lang.Override public Builder clear() { super.clear(); resource_ = ""; @@ -401,29 +452,30 @@ public Builder clear() { return this; } - @Override - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return IamPolicyProto.internal_static_google_iam_v1_GetIamPolicyRequest_descriptor; + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.iam.v1.IamPolicyProto + .internal_static_google_iam_v1_GetIamPolicyRequest_descriptor; } - @Override - public GetIamPolicyRequest getDefaultInstanceForType() { - return GetIamPolicyRequest.getDefaultInstance(); + @java.lang.Override + public com.google.iam.v1.GetIamPolicyRequest getDefaultInstanceForType() { + return com.google.iam.v1.GetIamPolicyRequest.getDefaultInstance(); } - @Override - public GetIamPolicyRequest build() { - GetIamPolicyRequest result = buildPartial(); + @java.lang.Override + public com.google.iam.v1.GetIamPolicyRequest build() { + com.google.iam.v1.GetIamPolicyRequest result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } - @Override - public GetIamPolicyRequest buildPartial() { - GetIamPolicyRequest result = new GetIamPolicyRequest(this); + @java.lang.Override + public com.google.iam.v1.GetIamPolicyRequest buildPartial() { + com.google.iam.v1.GetIamPolicyRequest result = + new com.google.iam.v1.GetIamPolicyRequest(this); result.resource_ = resource_; if (optionsBuilder_ == null) { result.options_ = options_; @@ -434,50 +486,51 @@ public GetIamPolicyRequest buildPartial() { return result; } - @Override + @java.lang.Override public Builder clone() { return super.clone(); } - @Override + + @java.lang.Override public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } - @Override - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } - @Override - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } - @Override + + @java.lang.Override public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } - @Override + + @java.lang.Override public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } - @Override + + @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof GetIamPolicyRequest) { - return mergeFrom((GetIamPolicyRequest)other); + if (other instanceof com.google.iam.v1.GetIamPolicyRequest) { + return mergeFrom((com.google.iam.v1.GetIamPolicyRequest) other); } else { super.mergeFrom(other); return this; } } - public Builder mergeFrom(GetIamPolicyRequest other) { - if (other == GetIamPolicyRequest.getDefaultInstance()) return this; + public Builder mergeFrom(com.google.iam.v1.GetIamPolicyRequest other) { + if (other == com.google.iam.v1.GetIamPolicyRequest.getDefaultInstance()) return this; if (!other.getResource().isEmpty()) { resource_ = other.resource_; onChanged(); @@ -490,21 +543,21 @@ public Builder mergeFrom(GetIamPolicyRequest other) { return this; } - @Override + @java.lang.Override public final boolean isInitialized() { return true; } - @Override + @java.lang.Override public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - GetIamPolicyRequest parsedMessage = null; + com.google.iam.v1.GetIamPolicyRequest parsedMessage = null; try { parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (GetIamPolicyRequest) e.getUnfinishedMessage(); + parsedMessage = (com.google.iam.v1.GetIamPolicyRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { if (parsedMessage != null) { @@ -514,42 +567,51 @@ public Builder mergeFrom( return this; } - private Object resource_ = ""; + private java.lang.Object resource_ = ""; /** + * + * *
      * REQUIRED: The resource for which the policy is being requested.
      * See the operation documentation for the appropriate value for this field.
      * 
* - * string resource = 1; + * + * string resource = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The resource. */ - public String getResource() { - Object ref = resource_; - if (!(ref instanceof String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - String s = bs.toStringUtf8(); + public java.lang.String getResource() { + java.lang.Object ref = resource_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); resource_ = s; return s; } else { - return (String) ref; + return (java.lang.String) ref; } } /** + * + * *
      * REQUIRED: The resource for which the policy is being requested.
      * See the operation documentation for the appropriate value for this field.
      * 
* - * string resource = 1; + * + * string resource = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for resource. */ - public com.google.protobuf.ByteString - getResourceBytes() { - Object ref = resource_; + public com.google.protobuf.ByteString getResourceBytes() { + java.lang.Object ref = resource_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); resource_ = b; return b; } else { @@ -557,87 +619,120 @@ public String getResource() { } } /** + * + * *
      * REQUIRED: The resource for which the policy is being requested.
      * See the operation documentation for the appropriate value for this field.
      * 
* - * string resource = 1; + * + * string resource = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The resource to set. + * @return This builder for chaining. */ - public Builder setResource( - String value) { + public Builder setResource(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + resource_ = value; onChanged(); return this; } /** + * + * *
      * REQUIRED: The resource for which the policy is being requested.
      * See the operation documentation for the appropriate value for this field.
      * 
* - * string resource = 1; + * + * string resource = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. */ public Builder clearResource() { - + resource_ = getDefaultInstance().getResource(); onChanged(); return this; } /** + * + * *
      * REQUIRED: The resource for which the policy is being requested.
      * See the operation documentation for the appropriate value for this field.
      * 
* - * string resource = 1; + * + * string resource = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for resource to set. + * @return This builder for chaining. */ - public Builder setResourceBytes( - com.google.protobuf.ByteString value) { + public Builder setResourceBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + resource_ = value; onChanged(); return this; } - private GetPolicyOptions options_; + private com.google.iam.v1.GetPolicyOptions options_; private com.google.protobuf.SingleFieldBuilderV3< - GetPolicyOptions, GetPolicyOptions.Builder, com.google.iam.v1.GetPolicyOptionsOrBuilder> optionsBuilder_; + com.google.iam.v1.GetPolicyOptions, + com.google.iam.v1.GetPolicyOptions.Builder, + com.google.iam.v1.GetPolicyOptionsOrBuilder> + optionsBuilder_; /** + * + * *
      * OPTIONAL: A `GetPolicyOptions` object for specifying options to
      * `GetIamPolicy`. This field is only used by Cloud IAM.
      * 
* * .google.iam.v1.GetPolicyOptions options = 2; + * + * @return Whether the options field is set. */ public boolean hasOptions() { return optionsBuilder_ != null || options_ != null; } /** + * + * *
      * OPTIONAL: A `GetPolicyOptions` object for specifying options to
      * `GetIamPolicy`. This field is only used by Cloud IAM.
      * 
* * .google.iam.v1.GetPolicyOptions options = 2; + * + * @return The options. */ - public GetPolicyOptions getOptions() { + public com.google.iam.v1.GetPolicyOptions getOptions() { if (optionsBuilder_ == null) { - return options_ == null ? GetPolicyOptions.getDefaultInstance() : options_; + return options_ == null + ? com.google.iam.v1.GetPolicyOptions.getDefaultInstance() + : options_; } else { return optionsBuilder_.getMessage(); } } /** + * + * *
      * OPTIONAL: A `GetPolicyOptions` object for specifying options to
      * `GetIamPolicy`. This field is only used by Cloud IAM.
@@ -645,7 +740,7 @@ public GetPolicyOptions getOptions() {
      *
      * .google.iam.v1.GetPolicyOptions options = 2;
      */
-    public Builder setOptions(GetPolicyOptions value) {
+    public Builder setOptions(com.google.iam.v1.GetPolicyOptions value) {
       if (optionsBuilder_ == null) {
         if (value == null) {
           throw new NullPointerException();
@@ -659,6 +754,8 @@ public Builder setOptions(GetPolicyOptions value) {
       return this;
     }
     /**
+     *
+     *
      * 
      * OPTIONAL: A `GetPolicyOptions` object for specifying options to
      * `GetIamPolicy`. This field is only used by Cloud IAM.
@@ -666,8 +763,7 @@ public Builder setOptions(GetPolicyOptions value) {
      *
      * .google.iam.v1.GetPolicyOptions options = 2;
      */
-    public Builder setOptions(
-        GetPolicyOptions.Builder builderForValue) {
+    public Builder setOptions(com.google.iam.v1.GetPolicyOptions.Builder builderForValue) {
       if (optionsBuilder_ == null) {
         options_ = builderForValue.build();
         onChanged();
@@ -678,6 +774,8 @@ public Builder setOptions(
       return this;
     }
     /**
+     *
+     *
      * 
      * OPTIONAL: A `GetPolicyOptions` object for specifying options to
      * `GetIamPolicy`. This field is only used by Cloud IAM.
@@ -685,11 +783,13 @@ public Builder setOptions(
      *
      * .google.iam.v1.GetPolicyOptions options = 2;
      */
-    public Builder mergeOptions(GetPolicyOptions value) {
+    public Builder mergeOptions(com.google.iam.v1.GetPolicyOptions value) {
       if (optionsBuilder_ == null) {
         if (options_ != null) {
           options_ =
-            GetPolicyOptions.newBuilder(options_).mergeFrom(value).buildPartial();
+              com.google.iam.v1.GetPolicyOptions.newBuilder(options_)
+                  .mergeFrom(value)
+                  .buildPartial();
         } else {
           options_ = value;
         }
@@ -701,6 +801,8 @@ public Builder mergeOptions(GetPolicyOptions value) {
       return this;
     }
     /**
+     *
+     *
      * 
      * OPTIONAL: A `GetPolicyOptions` object for specifying options to
      * `GetIamPolicy`. This field is only used by Cloud IAM.
@@ -720,6 +822,8 @@ public Builder clearOptions() {
       return this;
     }
     /**
+     *
+     *
      * 
      * OPTIONAL: A `GetPolicyOptions` object for specifying options to
      * `GetIamPolicy`. This field is only used by Cloud IAM.
@@ -727,12 +831,14 @@ public Builder clearOptions() {
      *
      * .google.iam.v1.GetPolicyOptions options = 2;
      */
-    public GetPolicyOptions.Builder getOptionsBuilder() {
-      
+    public com.google.iam.v1.GetPolicyOptions.Builder getOptionsBuilder() {
+
       onChanged();
       return getOptionsFieldBuilder().getBuilder();
     }
     /**
+     *
+     *
      * 
      * OPTIONAL: A `GetPolicyOptions` object for specifying options to
      * `GetIamPolicy`. This field is only used by Cloud IAM.
@@ -744,11 +850,14 @@ public com.google.iam.v1.GetPolicyOptionsOrBuilder getOptionsOrBuilder() {
       if (optionsBuilder_ != null) {
         return optionsBuilder_.getMessageOrBuilder();
       } else {
-        return options_ == null ?
-            GetPolicyOptions.getDefaultInstance() : options_;
+        return options_ == null
+            ? com.google.iam.v1.GetPolicyOptions.getDefaultInstance()
+            : options_;
       }
     }
     /**
+     *
+     *
      * 
      * OPTIONAL: A `GetPolicyOptions` object for specifying options to
      * `GetIamPolicy`. This field is only used by Cloud IAM.
@@ -757,68 +866,69 @@ public com.google.iam.v1.GetPolicyOptionsOrBuilder getOptionsOrBuilder() {
      * .google.iam.v1.GetPolicyOptions options = 2;
      */
     private com.google.protobuf.SingleFieldBuilderV3<
-        GetPolicyOptions, GetPolicyOptions.Builder, com.google.iam.v1.GetPolicyOptionsOrBuilder>
+            com.google.iam.v1.GetPolicyOptions,
+            com.google.iam.v1.GetPolicyOptions.Builder,
+            com.google.iam.v1.GetPolicyOptionsOrBuilder>
         getOptionsFieldBuilder() {
       if (optionsBuilder_ == null) {
-        optionsBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
-            GetPolicyOptions, GetPolicyOptions.Builder, com.google.iam.v1.GetPolicyOptionsOrBuilder>(
-                getOptions(),
-                getParentForChildren(),
-                isClean());
+        optionsBuilder_ =
+            new com.google.protobuf.SingleFieldBuilderV3<
+                com.google.iam.v1.GetPolicyOptions,
+                com.google.iam.v1.GetPolicyOptions.Builder,
+                com.google.iam.v1.GetPolicyOptionsOrBuilder>(
+                getOptions(), getParentForChildren(), isClean());
         options_ = null;
       }
       return optionsBuilder_;
     }
-    @Override
-    public final Builder setUnknownFields(
-        final com.google.protobuf.UnknownFieldSet unknownFields) {
+
+    @java.lang.Override
+    public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) {
       return super.setUnknownFields(unknownFields);
     }
 
-    @Override
+    @java.lang.Override
     public final Builder mergeUnknownFields(
         final com.google.protobuf.UnknownFieldSet unknownFields) {
       return super.mergeUnknownFields(unknownFields);
     }
 
-
     // @@protoc_insertion_point(builder_scope:google.iam.v1.GetIamPolicyRequest)
   }
 
   // @@protoc_insertion_point(class_scope:google.iam.v1.GetIamPolicyRequest)
-  private static final GetIamPolicyRequest DEFAULT_INSTANCE;
+  private static final com.google.iam.v1.GetIamPolicyRequest DEFAULT_INSTANCE;
+
   static {
-    DEFAULT_INSTANCE = new GetIamPolicyRequest();
+    DEFAULT_INSTANCE = new com.google.iam.v1.GetIamPolicyRequest();
   }
 
-  public static GetIamPolicyRequest getDefaultInstance() {
+  public static com.google.iam.v1.GetIamPolicyRequest getDefaultInstance() {
     return DEFAULT_INSTANCE;
   }
 
-  private static final com.google.protobuf.Parser
-      PARSER = new com.google.protobuf.AbstractParser() {
-    @Override
-    public GetIamPolicyRequest parsePartialFrom(
-        com.google.protobuf.CodedInputStream input,
-        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
-        throws com.google.protobuf.InvalidProtocolBufferException {
-      return new GetIamPolicyRequest(input, extensionRegistry);
-    }
-  };
+  private static final com.google.protobuf.Parser PARSER =
+      new com.google.protobuf.AbstractParser() {
+        @java.lang.Override
+        public GetIamPolicyRequest parsePartialFrom(
+            com.google.protobuf.CodedInputStream input,
+            com.google.protobuf.ExtensionRegistryLite extensionRegistry)
+            throws com.google.protobuf.InvalidProtocolBufferException {
+          return new GetIamPolicyRequest(input, extensionRegistry);
+        }
+      };
 
   public static com.google.protobuf.Parser parser() {
     return PARSER;
   }
 
-  @Override
+  @java.lang.Override
   public com.google.protobuf.Parser getParserForType() {
     return PARSER;
   }
 
-  @Override
-  public GetIamPolicyRequest getDefaultInstanceForType() {
+  @java.lang.Override
+  public com.google.iam.v1.GetIamPolicyRequest getDefaultInstanceForType() {
     return DEFAULT_INSTANCE;
   }
-
 }
-
diff --git a/proto-google-iam-v1/src/main/java/com/google/iam/v1/GetIamPolicyRequestOrBuilder.java b/proto-google-iam-v1/src/main/java/com/google/iam/v1/GetIamPolicyRequestOrBuilder.java
index 5e7749a9..443bbb5c 100644
--- a/proto-google-iam-v1/src/main/java/com/google/iam/v1/GetIamPolicyRequestOrBuilder.java
+++ b/proto-google-iam-v1/src/main/java/com/google/iam/v1/GetIamPolicyRequestOrBuilder.java
@@ -1,51 +1,88 @@
+/*
+ * 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/iam/v1/iam_policy.proto
 
 package com.google.iam.v1;
 
-public interface GetIamPolicyRequestOrBuilder extends
+public interface GetIamPolicyRequestOrBuilder
+    extends
     // @@protoc_insertion_point(interface_extends:google.iam.v1.GetIamPolicyRequest)
     com.google.protobuf.MessageOrBuilder {
 
   /**
+   *
+   *
    * 
    * REQUIRED: The resource for which the policy is being requested.
    * See the operation documentation for the appropriate value for this field.
    * 
* - * string resource = 1; + * + * string resource = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The resource. */ - String getResource(); + java.lang.String getResource(); /** + * + * *
    * REQUIRED: The resource for which the policy is being requested.
    * See the operation documentation for the appropriate value for this field.
    * 
* - * string resource = 1; + * + * string resource = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for resource. */ - com.google.protobuf.ByteString - getResourceBytes(); + com.google.protobuf.ByteString getResourceBytes(); /** + * + * *
    * OPTIONAL: A `GetPolicyOptions` object for specifying options to
    * `GetIamPolicy`. This field is only used by Cloud IAM.
    * 
* * .google.iam.v1.GetPolicyOptions options = 2; + * + * @return Whether the options field is set. */ boolean hasOptions(); /** + * + * *
    * OPTIONAL: A `GetPolicyOptions` object for specifying options to
    * `GetIamPolicy`. This field is only used by Cloud IAM.
    * 
* * .google.iam.v1.GetPolicyOptions options = 2; + * + * @return The options. */ - GetPolicyOptions getOptions(); + com.google.iam.v1.GetPolicyOptions getOptions(); /** + * + * *
    * OPTIONAL: A `GetPolicyOptions` object for specifying options to
    * `GetIamPolicy`. This field is only used by Cloud IAM.
@@ -53,5 +90,5 @@ public interface GetIamPolicyRequestOrBuilder extends
    *
    * .google.iam.v1.GetPolicyOptions options = 2;
    */
-  GetPolicyOptionsOrBuilder getOptionsOrBuilder();
+  com.google.iam.v1.GetPolicyOptionsOrBuilder getOptionsOrBuilder();
 }
diff --git a/proto-google-iam-v1/src/main/java/com/google/iam/v1/GetPolicyOptions.java b/proto-google-iam-v1/src/main/java/com/google/iam/v1/GetPolicyOptions.java
index 1c7dfbf2..84f175da 100644
--- a/proto-google-iam-v1/src/main/java/com/google/iam/v1/GetPolicyOptions.java
+++ b/proto-google-iam-v1/src/main/java/com/google/iam/v1/GetPolicyOptions.java
@@ -1,41 +1,63 @@
+/*
+ * 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/iam/v1/options.proto
 
 package com.google.iam.v1;
 
 /**
+ *
+ *
  * 
  * Encapsulates settings provided to GetIamPolicy.
  * 
* * Protobuf type {@code google.iam.v1.GetPolicyOptions} */ -public final class GetPolicyOptions extends - com.google.protobuf.GeneratedMessageV3 implements +public final class GetPolicyOptions extends com.google.protobuf.GeneratedMessageV3 + implements // @@protoc_insertion_point(message_implements:google.iam.v1.GetPolicyOptions) GetPolicyOptionsOrBuilder { -private static final long serialVersionUID = 0L; + private static final long serialVersionUID = 0L; // Use GetPolicyOptions.newBuilder() to construct. private GetPolicyOptions(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } - private GetPolicyOptions() { + + private GetPolicyOptions() {} + + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new GetPolicyOptions(); } - @Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } + private GetPolicyOptions( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { this(); if (extensionRegistry == null) { - throw new NullPointerException(); + throw new java.lang.NullPointerException(); } - int mutable_bitField0_ = 0; com.google.protobuf.UnknownFieldSet.Builder unknownFields = com.google.protobuf.UnknownFieldSet.newBuilder(); try { @@ -46,46 +68,49 @@ private GetPolicyOptions( case 0: done = true; break; - case 8: { - - requestedPolicyVersion_ = input.readInt32(); - break; - } - default: { - if (!parseUnknownField( - input, unknownFields, extensionRegistry, tag)) { - done = true; + case 8: + { + requestedPolicyVersion_ = input.readInt32(); + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; } - break; - } } } } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(this); } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException( - e).setUnfinishedMessage(this); + 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 OptionsProto.internal_static_google_iam_v1_GetPolicyOptions_descriptor; + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.iam.v1.OptionsProto.internal_static_google_iam_v1_GetPolicyOptions_descriptor; } - @Override - protected FieldAccessorTable + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return OptionsProto.internal_static_google_iam_v1_GetPolicyOptions_fieldAccessorTable + return com.google.iam.v1.OptionsProto + .internal_static_google_iam_v1_GetPolicyOptions_fieldAccessorTable .ensureFieldAccessorsInitialized( - GetPolicyOptions.class, Builder.class); + com.google.iam.v1.GetPolicyOptions.class, + com.google.iam.v1.GetPolicyOptions.Builder.class); } public static final int REQUESTED_POLICY_VERSION_FIELD_NUMBER = 1; private int requestedPolicyVersion_; /** + * + * *
    * Optional. The policy format version to be returned.
    * Valid values are 0, 1, and 3. Requests specifying an invalid value will be
@@ -96,13 +121,16 @@ private GetPolicyOptions(
    * 
* * int32 requested_policy_version = 1; + * + * @return The requestedPolicyVersion. */ public int getRequestedPolicyVersion() { return requestedPolicyVersion_; } private byte memoizedIsInitialized = -1; - @Override + + @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; if (isInitialized == 1) return true; @@ -112,47 +140,44 @@ public final boolean isInitialized() { return true; } - @Override - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (requestedPolicyVersion_ != 0) { output.writeInt32(1, requestedPolicyVersion_); } unknownFields.writeTo(output); } - @Override + @java.lang.Override public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; if (requestedPolicyVersion_ != 0) { - size += com.google.protobuf.CodedOutputStream - .computeInt32Size(1, requestedPolicyVersion_); + size += com.google.protobuf.CodedOutputStream.computeInt32Size(1, requestedPolicyVersion_); } size += unknownFields.getSerializedSize(); memoizedSize = size; return size; } - @Override - public boolean equals(final Object obj) { + @java.lang.Override + public boolean equals(final java.lang.Object obj) { if (obj == this) { - return true; + return true; } - if (!(obj instanceof GetPolicyOptions)) { + if (!(obj instanceof com.google.iam.v1.GetPolicyOptions)) { return super.equals(obj); } - GetPolicyOptions other = (GetPolicyOptions) obj; + com.google.iam.v1.GetPolicyOptions other = (com.google.iam.v1.GetPolicyOptions) obj; - if (getRequestedPolicyVersion() - != other.getRequestedPolicyVersion()) return false; + if (getRequestedPolicyVersion() != other.getRequestedPolicyVersion()) return false; if (!unknownFields.equals(other.unknownFields)) return false; return true; } - @Override + @java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; @@ -166,118 +191,126 @@ public int hashCode() { return hash; } - public static GetPolicyOptions parseFrom( - java.nio.ByteBuffer data) + public static com.google.iam.v1.GetPolicyOptions parseFrom(java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } - public static GetPolicyOptions parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + + public static com.google.iam.v1.GetPolicyOptions parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static GetPolicyOptions parseFrom( - com.google.protobuf.ByteString data) + + public static com.google.iam.v1.GetPolicyOptions parseFrom(com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } - public static GetPolicyOptions parseFrom( + + public static com.google.iam.v1.GetPolicyOptions parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static GetPolicyOptions parseFrom(byte[] data) + + public static com.google.iam.v1.GetPolicyOptions parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } - public static GetPolicyOptions parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + + public static com.google.iam.v1.GetPolicyOptions parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static GetPolicyOptions parseFrom(java.io.InputStream input) + + public static com.google.iam.v1.GetPolicyOptions parseFrom(java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } - public static GetPolicyOptions parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + + public static com.google.iam.v1.GetPolicyOptions parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } - public static GetPolicyOptions parseDelimitedFrom(java.io.InputStream input) + + public static com.google.iam.v1.GetPolicyOptions parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } - public static GetPolicyOptions parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + + public static com.google.iam.v1.GetPolicyOptions parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); } - public static GetPolicyOptions parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + + public static com.google.iam.v1.GetPolicyOptions parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } - public static GetPolicyOptions parseFrom( + + public static com.google.iam.v1.GetPolicyOptions parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); } - @Override - public Builder newBuilderForType() { return newBuilder(); } public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } - public static Builder newBuilder(GetPolicyOptions prototype) { + + public static Builder newBuilder(com.google.iam.v1.GetPolicyOptions prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } - @Override + + @java.lang.Override public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } - @Override - protected Builder newBuilderForType( - BuilderParent parent) { + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** + * + * *
    * Encapsulates settings provided to GetIamPolicy.
    * 
* * Protobuf type {@code google.iam.v1.GetPolicyOptions} */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements // @@protoc_insertion_point(builder_implements:google.iam.v1.GetPolicyOptions) com.google.iam.v1.GetPolicyOptionsOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return OptionsProto.internal_static_google_iam_v1_GetPolicyOptions_descriptor; + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.iam.v1.OptionsProto + .internal_static_google_iam_v1_GetPolicyOptions_descriptor; } - @Override - protected FieldAccessorTable + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return OptionsProto.internal_static_google_iam_v1_GetPolicyOptions_fieldAccessorTable + return com.google.iam.v1.OptionsProto + .internal_static_google_iam_v1_GetPolicyOptions_fieldAccessorTable .ensureFieldAccessorsInitialized( - GetPolicyOptions.class, Builder.class); + com.google.iam.v1.GetPolicyOptions.class, + com.google.iam.v1.GetPolicyOptions.Builder.class); } // Construct using com.google.iam.v1.GetPolicyOptions.newBuilder() @@ -285,17 +318,16 @@ private Builder() { maybeForceBuilderInitialization(); } - private Builder( - BuilderParent parent) { + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); maybeForceBuilderInitialization(); } + private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } - @Override + + @java.lang.Override public Builder clear() { super.clear(); requestedPolicyVersion_ = 0; @@ -303,78 +335,79 @@ public Builder clear() { return this; } - @Override - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return OptionsProto.internal_static_google_iam_v1_GetPolicyOptions_descriptor; + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.iam.v1.OptionsProto + .internal_static_google_iam_v1_GetPolicyOptions_descriptor; } - @Override - public GetPolicyOptions getDefaultInstanceForType() { - return GetPolicyOptions.getDefaultInstance(); + @java.lang.Override + public com.google.iam.v1.GetPolicyOptions getDefaultInstanceForType() { + return com.google.iam.v1.GetPolicyOptions.getDefaultInstance(); } - @Override - public GetPolicyOptions build() { - GetPolicyOptions result = buildPartial(); + @java.lang.Override + public com.google.iam.v1.GetPolicyOptions build() { + com.google.iam.v1.GetPolicyOptions result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } - @Override - public GetPolicyOptions buildPartial() { - GetPolicyOptions result = new GetPolicyOptions(this); + @java.lang.Override + public com.google.iam.v1.GetPolicyOptions buildPartial() { + com.google.iam.v1.GetPolicyOptions result = new com.google.iam.v1.GetPolicyOptions(this); result.requestedPolicyVersion_ = requestedPolicyVersion_; onBuilt(); return result; } - @Override + @java.lang.Override public Builder clone() { return super.clone(); } - @Override + + @java.lang.Override public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } - @Override - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } - @Override - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } - @Override + + @java.lang.Override public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } - @Override + + @java.lang.Override public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } - @Override + + @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof GetPolicyOptions) { - return mergeFrom((GetPolicyOptions)other); + if (other instanceof com.google.iam.v1.GetPolicyOptions) { + return mergeFrom((com.google.iam.v1.GetPolicyOptions) other); } else { super.mergeFrom(other); return this; } } - public Builder mergeFrom(GetPolicyOptions other) { - if (other == GetPolicyOptions.getDefaultInstance()) return this; + public Builder mergeFrom(com.google.iam.v1.GetPolicyOptions other) { + if (other == com.google.iam.v1.GetPolicyOptions.getDefaultInstance()) return this; if (other.getRequestedPolicyVersion() != 0) { setRequestedPolicyVersion(other.getRequestedPolicyVersion()); } @@ -383,21 +416,21 @@ public Builder mergeFrom(GetPolicyOptions other) { return this; } - @Override + @java.lang.Override public final boolean isInitialized() { return true; } - @Override + @java.lang.Override public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - GetPolicyOptions parsedMessage = null; + com.google.iam.v1.GetPolicyOptions parsedMessage = null; try { parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (GetPolicyOptions) e.getUnfinishedMessage(); + parsedMessage = (com.google.iam.v1.GetPolicyOptions) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { if (parsedMessage != null) { @@ -407,8 +440,10 @@ public Builder mergeFrom( return this; } - private int requestedPolicyVersion_ ; + private int requestedPolicyVersion_; /** + * + * *
      * Optional. The policy format version to be returned.
      * Valid values are 0, 1, and 3. Requests specifying an invalid value will be
@@ -419,11 +454,15 @@ public Builder mergeFrom(
      * 
* * int32 requested_policy_version = 1; + * + * @return The requestedPolicyVersion. */ public int getRequestedPolicyVersion() { return requestedPolicyVersion_; } /** + * + * *
      * Optional. The policy format version to be returned.
      * Valid values are 0, 1, and 3. Requests specifying an invalid value will be
@@ -434,14 +473,19 @@ public int getRequestedPolicyVersion() {
      * 
* * int32 requested_policy_version = 1; + * + * @param value The requestedPolicyVersion to set. + * @return This builder for chaining. */ public Builder setRequestedPolicyVersion(int value) { - + requestedPolicyVersion_ = value; onChanged(); return this; } /** + * + * *
      * Optional. The policy format version to be returned.
      * Valid values are 0, 1, and 3. Requests specifying an invalid value will be
@@ -452,63 +496,63 @@ public Builder setRequestedPolicyVersion(int value) {
      * 
* * int32 requested_policy_version = 1; + * + * @return This builder for chaining. */ public Builder clearRequestedPolicyVersion() { - + requestedPolicyVersion_ = 0; onChanged(); return this; } - @Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } - @Override + @java.lang.Override public final Builder mergeUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return super.mergeUnknownFields(unknownFields); } - // @@protoc_insertion_point(builder_scope:google.iam.v1.GetPolicyOptions) } // @@protoc_insertion_point(class_scope:google.iam.v1.GetPolicyOptions) - private static final GetPolicyOptions DEFAULT_INSTANCE; + private static final com.google.iam.v1.GetPolicyOptions DEFAULT_INSTANCE; + static { - DEFAULT_INSTANCE = new GetPolicyOptions(); + DEFAULT_INSTANCE = new com.google.iam.v1.GetPolicyOptions(); } - public static GetPolicyOptions getDefaultInstance() { + public static com.google.iam.v1.GetPolicyOptions getDefaultInstance() { return DEFAULT_INSTANCE; } - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - @Override - public GetPolicyOptions parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new GetPolicyOptions(input, extensionRegistry); - } - }; + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public GetPolicyOptions parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new GetPolicyOptions(input, extensionRegistry); + } + }; public static com.google.protobuf.Parser parser() { return PARSER; } - @Override + @java.lang.Override public com.google.protobuf.Parser getParserForType() { return PARSER; } - @Override - public GetPolicyOptions getDefaultInstanceForType() { + @java.lang.Override + public com.google.iam.v1.GetPolicyOptions getDefaultInstanceForType() { return DEFAULT_INSTANCE; } - } - diff --git a/proto-google-iam-v1/src/main/java/com/google/iam/v1/GetPolicyOptionsOrBuilder.java b/proto-google-iam-v1/src/main/java/com/google/iam/v1/GetPolicyOptionsOrBuilder.java index a49f78a6..ea37a837 100644 --- a/proto-google-iam-v1/src/main/java/com/google/iam/v1/GetPolicyOptionsOrBuilder.java +++ b/proto-google-iam-v1/src/main/java/com/google/iam/v1/GetPolicyOptionsOrBuilder.java @@ -1,13 +1,31 @@ +/* + * 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/iam/v1/options.proto package com.google.iam.v1; -public interface GetPolicyOptionsOrBuilder extends +public interface GetPolicyOptionsOrBuilder + extends // @@protoc_insertion_point(interface_extends:google.iam.v1.GetPolicyOptions) com.google.protobuf.MessageOrBuilder { /** + * + * *
    * Optional. The policy format version to be returned.
    * Valid values are 0, 1, and 3. Requests specifying an invalid value will be
@@ -18,6 +36,8 @@ public interface GetPolicyOptionsOrBuilder extends
    * 
* * int32 requested_policy_version = 1; + * + * @return The requestedPolicyVersion. */ int getRequestedPolicyVersion(); } diff --git a/proto-google-iam-v1/src/main/java/com/google/iam/v1/IamPolicyProto.java b/proto-google-iam-v1/src/main/java/com/google/iam/v1/IamPolicyProto.java index be8c5a61..088dcca0 100644 --- a/proto-google-iam-v1/src/main/java/com/google/iam/v1/IamPolicyProto.java +++ b/proto-google-iam-v1/src/main/java/com/google/iam/v1/IamPolicyProto.java @@ -1,3 +1,18 @@ +/* + * 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/iam/v1/iam_policy.proto @@ -5,121 +20,125 @@ public final class IamPolicyProto { private IamPolicyProto() {} - public static void registerAllExtensions( - com.google.protobuf.ExtensionRegistryLite registry) { - } - public static void registerAllExtensions( - com.google.protobuf.ExtensionRegistry registry) { - registerAllExtensions( - (com.google.protobuf.ExtensionRegistryLite) registry); + 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_iam_v1_SetIamPolicyRequest_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_iam_v1_SetIamPolicyRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internal_static_google_iam_v1_SetIamPolicyRequest_fieldAccessorTable; static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_iam_v1_GetIamPolicyRequest_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_iam_v1_GetIamPolicyRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internal_static_google_iam_v1_GetIamPolicyRequest_fieldAccessorTable; static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_iam_v1_TestIamPermissionsRequest_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_iam_v1_TestIamPermissionsRequest_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internal_static_google_iam_v1_TestIamPermissionsRequest_fieldAccessorTable; static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_iam_v1_TestIamPermissionsResponse_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_iam_v1_TestIamPermissionsResponse_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internal_static_google_iam_v1_TestIamPermissionsResponse_fieldAccessorTable; - public static com.google.protobuf.Descriptors.FileDescriptor - getDescriptor() { + public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { return descriptor; } - private static com.google.protobuf.Descriptors.FileDescriptor - descriptor; + + private static com.google.protobuf.Descriptors.FileDescriptor descriptor; + static { - String[] descriptorData = { - "\n\036google/iam/v1/iam_policy.proto\022\rgoogle" + - ".iam.v1\032\033google/iam/v1/options.proto\032\032go" + - "ogle/iam/v1/policy.proto\032\034google/api/ann" + - "otations.proto\032\027google/api/client.proto\"" + - "N\n\023SetIamPolicyRequest\022\020\n\010resource\030\001 \001(\t" + - "\022%\n\006policy\030\002 \001(\0132\025.google.iam.v1.Policy\"" + - "Y\n\023GetIamPolicyRequest\022\020\n\010resource\030\001 \001(\t" + - "\0220\n\007options\030\002 \001(\0132\037.google.iam.v1.GetPol" + - "icyOptions\"B\n\031TestIamPermissionsRequest\022" + - "\020\n\010resource\030\001 \001(\t\022\023\n\013permissions\030\002 \003(\t\"1" + - "\n\032TestIamPermissionsResponse\022\023\n\013permissi" + - "ons\030\001 \003(\t2\264\003\n\tIAMPolicy\022t\n\014SetIamPolicy\022" + - "\".google.iam.v1.SetIamPolicyRequest\032\025.go" + - "ogle.iam.v1.Policy\")\202\323\344\223\002#\"\036/v1/{resourc" + - "e=**}:setIamPolicy:\001*\022t\n\014GetIamPolicy\022\"." + - "google.iam.v1.GetIamPolicyRequest\032\025.goog" + - "le.iam.v1.Policy\")\202\323\344\223\002#\"\036/v1/{resource=" + - "**}:getIamPolicy:\001*\022\232\001\n\022TestIamPermissio" + - "ns\022(.google.iam.v1.TestIamPermissionsReq" + - "uest\032).google.iam.v1.TestIamPermissionsR" + - "esponse\"/\202\323\344\223\002)\"$/v1/{resource=**}:testI" + - "amPermissions:\001*\032\036\312A\033iam-meta-api.google" + - "apis.comB\206\001\n\021com.google.iam.v1B\016IamPolic" + - "yProtoP\001Z0google.golang.org/genproto/goo" + - "gleapis/iam/v1;iam\370\001\001\252\002\023Google.Cloud.Iam" + - ".V1\312\002\023Google\\Cloud\\Iam\\V1b\006proto3" + java.lang.String[] descriptorData = { + "\n\036google/iam/v1/iam_policy.proto\022\rgoogle" + + ".iam.v1\032\033google/iam/v1/options.proto\032\032go" + + "ogle/iam/v1/policy.proto\032\034google/api/ann" + + "otations.proto\032\027google/api/client.proto\032" + + "\037google/api/field_behavior.proto\032\031google" + + "/api/resource.proto\"^\n\023SetIamPolicyReque" + + "st\022\033\n\010resource\030\001 \001(\tB\t\340A\002\372A\003\n\001*\022*\n\006polic" + + "y\030\002 \001(\0132\025.google.iam.v1.PolicyB\003\340A\002\"d\n\023G" + + "etIamPolicyRequest\022\033\n\010resource\030\001 \001(\tB\t\340A" + + "\002\372A\003\n\001*\0220\n\007options\030\002 \001(\0132\037.google.iam.v1" + + ".GetPolicyOptions\"R\n\031TestIamPermissionsR" + + "equest\022\033\n\010resource\030\001 \001(\tB\t\340A\002\372A\003\n\001*\022\030\n\013p" + + "ermissions\030\002 \003(\tB\003\340A\002\"1\n\032TestIamPermissi" + + "onsResponse\022\023\n\013permissions\030\001 \003(\t2\264\003\n\tIAM" + + "Policy\022t\n\014SetIamPolicy\022\".google.iam.v1.S" + + "etIamPolicyRequest\032\025.google.iam.v1.Polic" + + "y\")\202\323\344\223\002#\"\036/v1/{resource=**}:setIamPolic" + + "y:\001*\022t\n\014GetIamPolicy\022\".google.iam.v1.Get" + + "IamPolicyRequest\032\025.google.iam.v1.Policy\"" + + ")\202\323\344\223\002#\"\036/v1/{resource=**}:getIamPolicy:" + + "\001*\022\232\001\n\022TestIamPermissions\022(.google.iam.v" + + "1.TestIamPermissionsRequest\032).google.iam" + + ".v1.TestIamPermissionsResponse\"/\202\323\344\223\002)\"$" + + "/v1/{resource=**}:testIamPermissions:\001*\032" + + "\036\312A\033iam-meta-api.googleapis.comB\206\001\n\021com." + + "google.iam.v1B\016IamPolicyProtoP\001Z0google." + + "golang.org/genproto/googleapis/iam/v1;ia" + + "m\370\001\001\252\002\023Google.Cloud.Iam.V1\312\002\023Google\\Clou" + + "d\\Iam\\V1b\006proto3" }; - com.google.protobuf.Descriptors.FileDescriptor.InternalDescriptorAssigner assigner = - new com.google.protobuf.Descriptors.FileDescriptor. InternalDescriptorAssigner() { - public com.google.protobuf.ExtensionRegistry assignDescriptors( - com.google.protobuf.Descriptors.FileDescriptor root) { - descriptor = root; - return null; - } - }; - com.google.protobuf.Descriptors.FileDescriptor - .internalBuildGeneratedFileFrom(descriptorData, - new com.google.protobuf.Descriptors.FileDescriptor[] { - OptionsProto.getDescriptor(), - PolicyProto.getDescriptor(), - com.google.api.AnnotationsProto.getDescriptor(), - com.google.api.ClientProto.getDescriptor(), - }, assigner); + descriptor = + com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( + descriptorData, + new com.google.protobuf.Descriptors.FileDescriptor[] { + com.google.iam.v1.OptionsProto.getDescriptor(), + com.google.iam.v1.PolicyProto.getDescriptor(), + com.google.api.AnnotationsProto.getDescriptor(), + com.google.api.ClientProto.getDescriptor(), + com.google.api.FieldBehaviorProto.getDescriptor(), + com.google.api.ResourceProto.getDescriptor(), + }); internal_static_google_iam_v1_SetIamPolicyRequest_descriptor = - getDescriptor().getMessageTypes().get(0); - internal_static_google_iam_v1_SetIamPolicyRequest_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_iam_v1_SetIamPolicyRequest_descriptor, - new String[] { "Resource", "Policy", }); + getDescriptor().getMessageTypes().get(0); + internal_static_google_iam_v1_SetIamPolicyRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_iam_v1_SetIamPolicyRequest_descriptor, + new java.lang.String[] { + "Resource", "Policy", + }); internal_static_google_iam_v1_GetIamPolicyRequest_descriptor = - getDescriptor().getMessageTypes().get(1); - internal_static_google_iam_v1_GetIamPolicyRequest_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_iam_v1_GetIamPolicyRequest_descriptor, - new String[] { "Resource", "Options", }); + getDescriptor().getMessageTypes().get(1); + internal_static_google_iam_v1_GetIamPolicyRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_iam_v1_GetIamPolicyRequest_descriptor, + new java.lang.String[] { + "Resource", "Options", + }); internal_static_google_iam_v1_TestIamPermissionsRequest_descriptor = - getDescriptor().getMessageTypes().get(2); - internal_static_google_iam_v1_TestIamPermissionsRequest_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_iam_v1_TestIamPermissionsRequest_descriptor, - new String[] { "Resource", "Permissions", }); + getDescriptor().getMessageTypes().get(2); + internal_static_google_iam_v1_TestIamPermissionsRequest_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_iam_v1_TestIamPermissionsRequest_descriptor, + new java.lang.String[] { + "Resource", "Permissions", + }); internal_static_google_iam_v1_TestIamPermissionsResponse_descriptor = - getDescriptor().getMessageTypes().get(3); - internal_static_google_iam_v1_TestIamPermissionsResponse_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_iam_v1_TestIamPermissionsResponse_descriptor, - new String[] { "Permissions", }); + getDescriptor().getMessageTypes().get(3); + internal_static_google_iam_v1_TestIamPermissionsResponse_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_iam_v1_TestIamPermissionsResponse_descriptor, + new java.lang.String[] { + "Permissions", + }); 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); - com.google.protobuf.Descriptors.FileDescriptor - .internalUpdateFileDescriptor(descriptor, registry); - OptionsProto.getDescriptor(); - PolicyProto.getDescriptor(); + registry.add(com.google.api.ResourceProto.resourceReference); + com.google.protobuf.Descriptors.FileDescriptor.internalUpdateFileDescriptor( + descriptor, registry); + com.google.iam.v1.OptionsProto.getDescriptor(); + com.google.iam.v1.PolicyProto.getDescriptor(); com.google.api.AnnotationsProto.getDescriptor(); com.google.api.ClientProto.getDescriptor(); + com.google.api.FieldBehaviorProto.getDescriptor(); + com.google.api.ResourceProto.getDescriptor(); } // @@protoc_insertion_point(outer_class_scope) diff --git a/proto-google-iam-v1/src/main/java/com/google/iam/v1/OptionsProto.java b/proto-google-iam-v1/src/main/java/com/google/iam/v1/OptionsProto.java index 38d4284b..02274d0d 100644 --- a/proto-google-iam-v1/src/main/java/com/google/iam/v1/OptionsProto.java +++ b/proto-google-iam-v1/src/main/java/com/google/iam/v1/OptionsProto.java @@ -1,3 +1,18 @@ +/* + * 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/iam/v1/options.proto @@ -5,56 +20,48 @@ public final class OptionsProto { private OptionsProto() {} - public static void registerAllExtensions( - com.google.protobuf.ExtensionRegistryLite registry) { - } - public static void registerAllExtensions( - com.google.protobuf.ExtensionRegistry registry) { - registerAllExtensions( - (com.google.protobuf.ExtensionRegistryLite) registry); + 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_iam_v1_GetPolicyOptions_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_iam_v1_GetPolicyOptions_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internal_static_google_iam_v1_GetPolicyOptions_fieldAccessorTable; - public static com.google.protobuf.Descriptors.FileDescriptor - getDescriptor() { + public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { return descriptor; } - private static com.google.protobuf.Descriptors.FileDescriptor - descriptor; + + private static com.google.protobuf.Descriptors.FileDescriptor descriptor; + static { - String[] descriptorData = { - "\n\033google/iam/v1/options.proto\022\rgoogle.ia" + - "m.v1\032\034google/api/annotations.proto\"4\n\020Ge" + - "tPolicyOptions\022 \n\030requested_policy_versi" + - "on\030\001 \001(\005B\204\001\n\021com.google.iam.v1B\014OptionsP" + - "rotoP\001Z0google.golang.org/genproto/googl" + - "eapis/iam/v1;iam\370\001\001\252\002\023Google.Cloud.Iam.V" + - "1\312\002\023Google\\Cloud\\Iam\\V1b\006proto3" + java.lang.String[] descriptorData = { + "\n\033google/iam/v1/options.proto\022\rgoogle.ia" + + "m.v1\032\034google/api/annotations.proto\"4\n\020Ge" + + "tPolicyOptions\022 \n\030requested_policy_versi" + + "on\030\001 \001(\005B\204\001\n\021com.google.iam.v1B\014OptionsP" + + "rotoP\001Z0google.golang.org/genproto/googl" + + "eapis/iam/v1;iam\370\001\001\252\002\023Google.Cloud.Iam.V" + + "1\312\002\023Google\\Cloud\\Iam\\V1b\006proto3" }; - com.google.protobuf.Descriptors.FileDescriptor.InternalDescriptorAssigner assigner = - new com.google.protobuf.Descriptors.FileDescriptor. InternalDescriptorAssigner() { - public com.google.protobuf.ExtensionRegistry assignDescriptors( - com.google.protobuf.Descriptors.FileDescriptor root) { - descriptor = root; - return null; - } - }; - com.google.protobuf.Descriptors.FileDescriptor - .internalBuildGeneratedFileFrom(descriptorData, - new com.google.protobuf.Descriptors.FileDescriptor[] { - com.google.api.AnnotationsProto.getDescriptor(), - }, assigner); + descriptor = + com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( + descriptorData, + new com.google.protobuf.Descriptors.FileDescriptor[] { + com.google.api.AnnotationsProto.getDescriptor(), + }); internal_static_google_iam_v1_GetPolicyOptions_descriptor = - getDescriptor().getMessageTypes().get(0); - internal_static_google_iam_v1_GetPolicyOptions_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_iam_v1_GetPolicyOptions_descriptor, - new String[] { "RequestedPolicyVersion", }); + getDescriptor().getMessageTypes().get(0); + internal_static_google_iam_v1_GetPolicyOptions_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_iam_v1_GetPolicyOptions_descriptor, + new java.lang.String[] { + "RequestedPolicyVersion", + }); com.google.api.AnnotationsProto.getDescriptor(); } diff --git a/proto-google-iam-v1/src/main/java/com/google/iam/v1/Policy.java b/proto-google-iam-v1/src/main/java/com/google/iam/v1/Policy.java index 7db80fad..dc77fb6c 100644 --- a/proto-google-iam-v1/src/main/java/com/google/iam/v1/Policy.java +++ b/proto-google-iam-v1/src/main/java/com/google/iam/v1/Policy.java @@ -1,9 +1,26 @@ +/* + * 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/iam/v1/policy.proto package com.google.iam.v1; /** + * + * *
  * Defines an Identity and Access Management (IAM) policy. It is used to
  * specify access control policies for Cloud Platform resources.
@@ -59,32 +76,39 @@
  *
  * Protobuf type {@code google.iam.v1.Policy}
  */
-public  final class Policy extends
-    com.google.protobuf.GeneratedMessageV3 implements
+public final class Policy extends com.google.protobuf.GeneratedMessageV3
+    implements
     // @@protoc_insertion_point(message_implements:google.iam.v1.Policy)
     PolicyOrBuilder {
-private static final long serialVersionUID = 0L;
+  private static final long serialVersionUID = 0L;
   // Use Policy.newBuilder() to construct.
   private Policy(com.google.protobuf.GeneratedMessageV3.Builder builder) {
     super(builder);
   }
+
   private Policy() {
     bindings_ = java.util.Collections.emptyList();
     etag_ = com.google.protobuf.ByteString.EMPTY;
   }
 
-  @Override
-  public final com.google.protobuf.UnknownFieldSet
-  getUnknownFields() {
+  @java.lang.Override
+  @SuppressWarnings({"unused"})
+  protected java.lang.Object newInstance(UnusedPrivateParameter unused) {
+    return new Policy();
+  }
+
+  @java.lang.Override
+  public final com.google.protobuf.UnknownFieldSet getUnknownFields() {
     return this.unknownFields;
   }
+
   private Policy(
       com.google.protobuf.CodedInputStream input,
       com.google.protobuf.ExtensionRegistryLite extensionRegistry)
       throws com.google.protobuf.InvalidProtocolBufferException {
     this();
     if (extensionRegistry == null) {
-      throw new NullPointerException();
+      throw new java.lang.NullPointerException();
     }
     int mutable_bitField0_ = 0;
     com.google.protobuf.UnknownFieldSet.Builder unknownFields =
@@ -97,78 +121,82 @@ private Policy(
           case 0:
             done = true;
             break;
-          case 8: {
-
-            version_ = input.readInt32();
-            break;
-          }
-          case 26: {
-
-            etag_ = input.readBytes();
-            break;
-          }
-          case 34: {
-            if (!((mutable_bitField0_ & 0x00000002) != 0)) {
-              bindings_ = new java.util.ArrayList();
-              mutable_bitField0_ |= 0x00000002;
+          case 8:
+            {
+              version_ = input.readInt32();
+              break;
             }
-            bindings_.add(
-                input.readMessage(com.google.iam.v1.Binding.parser(), extensionRegistry));
-            break;
-          }
-          default: {
-            if (!parseUnknownField(
-                input, unknownFields, extensionRegistry, tag)) {
-              done = true;
+          case 26:
+            {
+              etag_ = input.readBytes();
+              break;
+            }
+          case 34:
+            {
+              if (!((mutable_bitField0_ & 0x00000001) != 0)) {
+                bindings_ = new java.util.ArrayList();
+                mutable_bitField0_ |= 0x00000001;
+              }
+              bindings_.add(
+                  input.readMessage(com.google.iam.v1.Binding.parser(), extensionRegistry));
+              break;
+            }
+          default:
+            {
+              if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) {
+                done = true;
+              }
+              break;
             }
-            break;
-          }
         }
       }
     } catch (com.google.protobuf.InvalidProtocolBufferException e) {
       throw e.setUnfinishedMessage(this);
     } catch (java.io.IOException e) {
-      throw new com.google.protobuf.InvalidProtocolBufferException(
-          e).setUnfinishedMessage(this);
+      throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this);
     } finally {
-      if (((mutable_bitField0_ & 0x00000002) != 0)) {
+      if (((mutable_bitField0_ & 0x00000001) != 0)) {
         bindings_ = java.util.Collections.unmodifiableList(bindings_);
       }
       this.unknownFields = unknownFields.build();
       makeExtensionsImmutable();
     }
   }
-  public static final com.google.protobuf.Descriptors.Descriptor
-      getDescriptor() {
+
+  public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() {
     return com.google.iam.v1.PolicyProto.internal_static_google_iam_v1_Policy_descriptor;
   }
 
-  @Override
-  protected FieldAccessorTable
+  @java.lang.Override
+  protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
       internalGetFieldAccessorTable() {
     return com.google.iam.v1.PolicyProto.internal_static_google_iam_v1_Policy_fieldAccessorTable
         .ensureFieldAccessorsInitialized(
-            Policy.class, Builder.class);
+            com.google.iam.v1.Policy.class, com.google.iam.v1.Policy.Builder.class);
   }
 
-  private int bitField0_;
   public static final int VERSION_FIELD_NUMBER = 1;
   private int version_;
   /**
+   *
+   *
    * 
    * Specifies the format of the policy.
    * Valid values are 0, 1, and 3. Requests specifying an invalid value will be
    * rejected.
    * Operations affecting conditional bindings must specify version 3. This can
    * be either setting a conditional policy, modifying a conditional binding,
-   * or removing a conditional binding from the stored conditional policy.
+   * or removing a binding (conditional or unconditional) from the stored
+   * conditional policy.
    * Operations on non-conditional policies may specify any valid value or
    * leave the field unset.
-   * If no etag is provided in the call to `setIamPolicy`, any version
-   * compliance checks on the incoming and/or stored policy is skipped.
+   * If no etag is provided in the call to `setIamPolicy`, version compliance
+   * checks against the stored policy is skipped.
    * 
* * int32 version = 1; + * + * @return The version. */ public int getVersion() { return version_; @@ -177,6 +205,8 @@ public int getVersion() { public static final int BINDINGS_FIELD_NUMBER = 4; private java.util.List bindings_; /** + * + * *
    * Associates a list of `members` to a `role`. Optionally may specify a
    * `condition` that determines when binding is in effect.
@@ -189,6 +219,8 @@ public java.util.List getBindingsList() {
     return bindings_;
   }
   /**
+   *
+   *
    * 
    * Associates a list of `members` to a `role`. Optionally may specify a
    * `condition` that determines when binding is in effect.
@@ -197,11 +229,12 @@ public java.util.List getBindingsList() {
    *
    * repeated .google.iam.v1.Binding bindings = 4;
    */
-  public java.util.List 
-      getBindingsOrBuilderList() {
+  public java.util.List getBindingsOrBuilderList() {
     return bindings_;
   }
   /**
+   *
+   *
    * 
    * Associates a list of `members` to a `role`. Optionally may specify a
    * `condition` that determines when binding is in effect.
@@ -214,6 +247,8 @@ public int getBindingsCount() {
     return bindings_.size();
   }
   /**
+   *
+   *
    * 
    * Associates a list of `members` to a `role`. Optionally may specify a
    * `condition` that determines when binding is in effect.
@@ -226,6 +261,8 @@ public com.google.iam.v1.Binding getBindings(int index) {
     return bindings_.get(index);
   }
   /**
+   *
+   *
    * 
    * Associates a list of `members` to a `role`. Optionally may specify a
    * `condition` that determines when binding is in effect.
@@ -234,14 +271,15 @@ public com.google.iam.v1.Binding getBindings(int index) {
    *
    * repeated .google.iam.v1.Binding bindings = 4;
    */
-  public com.google.iam.v1.BindingOrBuilder getBindingsOrBuilder(
-      int index) {
+  public com.google.iam.v1.BindingOrBuilder getBindingsOrBuilder(int index) {
     return bindings_.get(index);
   }
 
   public static final int ETAG_FIELD_NUMBER = 3;
   private com.google.protobuf.ByteString etag_;
   /**
+   *
+   *
    * 
    * `etag` is used for optimistic concurrency control as a way to help
    * prevent simultaneous updates of a policy from overwriting each other.
@@ -252,18 +290,21 @@ public com.google.iam.v1.BindingOrBuilder getBindingsOrBuilder(
    * ensure that their change will be applied to the same version of the policy.
    * If no `etag` is provided in the call to `setIamPolicy`, then the existing
    * policy is overwritten. Due to blind-set semantics of an etag-less policy,
-   * 'setIamPolicy' will not fail even if either of incoming or stored policy
-   * does not meet the version requirements.
+   * 'setIamPolicy' will not fail even if the incoming policy version does not
+   * meet the requirements for modifying the stored policy.
    * 
* * bytes etag = 3; + * + * @return The etag. */ public com.google.protobuf.ByteString getEtag() { return etag_; } private byte memoizedIsInitialized = -1; - @Override + + @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; if (isInitialized == 1) return true; @@ -273,9 +314,8 @@ public final boolean isInitialized() { return true; } - @Override - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (version_ != 0) { output.writeInt32(1, version_); } @@ -288,50 +328,44 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) unknownFields.writeTo(output); } - @Override + @java.lang.Override public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; if (version_ != 0) { - size += com.google.protobuf.CodedOutputStream - .computeInt32Size(1, version_); + size += com.google.protobuf.CodedOutputStream.computeInt32Size(1, version_); } if (!etag_.isEmpty()) { - size += com.google.protobuf.CodedOutputStream - .computeBytesSize(3, etag_); + size += com.google.protobuf.CodedOutputStream.computeBytesSize(3, etag_); } for (int i = 0; i < bindings_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(4, bindings_.get(i)); + size += com.google.protobuf.CodedOutputStream.computeMessageSize(4, bindings_.get(i)); } size += unknownFields.getSerializedSize(); memoizedSize = size; return size; } - @Override - public boolean equals(final Object obj) { + @java.lang.Override + public boolean equals(final java.lang.Object obj) { if (obj == this) { - return true; + return true; } - if (!(obj instanceof Policy)) { + if (!(obj instanceof com.google.iam.v1.Policy)) { return super.equals(obj); } - Policy other = (Policy) obj; - - if (getVersion() - != other.getVersion()) return false; - if (!getBindingsList() - .equals(other.getBindingsList())) return false; - if (!getEtag() - .equals(other.getEtag())) return false; + com.google.iam.v1.Policy other = (com.google.iam.v1.Policy) obj; + + if (getVersion() != other.getVersion()) return false; + if (!getBindingsList().equals(other.getBindingsList())) return false; + if (!getEtag().equals(other.getEtag())) return false; if (!unknownFields.equals(other.unknownFields)) return false; return true; } - @Override + @java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; @@ -351,97 +385,103 @@ public int hashCode() { return hash; } - public static Policy parseFrom( - java.nio.ByteBuffer data) + public static com.google.iam.v1.Policy parseFrom(java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } - public static Policy parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + + public static com.google.iam.v1.Policy parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static Policy parseFrom( - com.google.protobuf.ByteString data) + + public static com.google.iam.v1.Policy parseFrom(com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } - public static Policy parseFrom( + + public static com.google.iam.v1.Policy parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static Policy parseFrom(byte[] data) + + public static com.google.iam.v1.Policy parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } - public static Policy parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + + public static com.google.iam.v1.Policy parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static Policy parseFrom(java.io.InputStream input) + + public static com.google.iam.v1.Policy parseFrom(java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } - public static Policy parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + + public static com.google.iam.v1.Policy parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } - public static Policy parseDelimitedFrom(java.io.InputStream input) + + public static com.google.iam.v1.Policy parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } - public static Policy parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + + public static com.google.iam.v1.Policy parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); } - public static Policy parseFrom( - com.google.protobuf.CodedInputStream input) + + public static com.google.iam.v1.Policy parseFrom(com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } - public static Policy parseFrom( + + public static com.google.iam.v1.Policy parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); } - @Override - public Builder newBuilderForType() { return newBuilder(); } public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } - public static Builder newBuilder(Policy prototype) { + + public static Builder newBuilder(com.google.iam.v1.Policy prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } - @Override + + @java.lang.Override public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } - @Override - protected Builder newBuilderForType( - BuilderParent parent) { + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** + * + * *
    * Defines an Identity and Access Management (IAM) policy. It is used to
    * specify access control policies for Cloud Platform resources.
@@ -497,21 +537,20 @@ protected Builder newBuilderForType(
    *
    * Protobuf type {@code google.iam.v1.Policy}
    */
-  public static final class Builder extends
-      com.google.protobuf.GeneratedMessageV3.Builder implements
+  public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder
+      implements
       // @@protoc_insertion_point(builder_implements:google.iam.v1.Policy)
       com.google.iam.v1.PolicyOrBuilder {
-    public static final com.google.protobuf.Descriptors.Descriptor
-        getDescriptor() {
+    public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() {
       return com.google.iam.v1.PolicyProto.internal_static_google_iam_v1_Policy_descriptor;
     }
 
-    @Override
-    protected FieldAccessorTable
+    @java.lang.Override
+    protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
         internalGetFieldAccessorTable() {
       return com.google.iam.v1.PolicyProto.internal_static_google_iam_v1_Policy_fieldAccessorTable
           .ensureFieldAccessorsInitialized(
-              Policy.class, Builder.class);
+              com.google.iam.v1.Policy.class, com.google.iam.v1.Policy.Builder.class);
     }
 
     // Construct using com.google.iam.v1.Policy.newBuilder()
@@ -519,25 +558,25 @@ private Builder() {
       maybeForceBuilderInitialization();
     }
 
-    private Builder(
-        BuilderParent parent) {
+    private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
       super(parent);
       maybeForceBuilderInitialization();
     }
+
     private void maybeForceBuilderInitialization() {
-      if (com.google.protobuf.GeneratedMessageV3
-              .alwaysUseFieldBuilders) {
+      if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {
         getBindingsFieldBuilder();
       }
     }
-    @Override
+
+    @java.lang.Override
     public Builder clear() {
       super.clear();
       version_ = 0;
 
       if (bindingsBuilder_ == null) {
         bindings_ = java.util.Collections.emptyList();
-        bitField0_ = (bitField0_ & ~0x00000002);
+        bitField0_ = (bitField0_ & ~0x00000001);
       } else {
         bindingsBuilder_.clear();
       }
@@ -546,91 +585,89 @@ public Builder clear() {
       return this;
     }
 
-    @Override
-    public com.google.protobuf.Descriptors.Descriptor
-        getDescriptorForType() {
+    @java.lang.Override
+    public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() {
       return com.google.iam.v1.PolicyProto.internal_static_google_iam_v1_Policy_descriptor;
     }
 
-    @Override
-    public Policy getDefaultInstanceForType() {
-      return Policy.getDefaultInstance();
+    @java.lang.Override
+    public com.google.iam.v1.Policy getDefaultInstanceForType() {
+      return com.google.iam.v1.Policy.getDefaultInstance();
     }
 
-    @Override
-    public Policy build() {
-      Policy result = buildPartial();
+    @java.lang.Override
+    public com.google.iam.v1.Policy build() {
+      com.google.iam.v1.Policy result = buildPartial();
       if (!result.isInitialized()) {
         throw newUninitializedMessageException(result);
       }
       return result;
     }
 
-    @Override
-    public Policy buildPartial() {
-      Policy result = new Policy(this);
+    @java.lang.Override
+    public com.google.iam.v1.Policy buildPartial() {
+      com.google.iam.v1.Policy result = new com.google.iam.v1.Policy(this);
       int from_bitField0_ = bitField0_;
-      int to_bitField0_ = 0;
       result.version_ = version_;
       if (bindingsBuilder_ == null) {
-        if (((bitField0_ & 0x00000002) != 0)) {
+        if (((bitField0_ & 0x00000001) != 0)) {
           bindings_ = java.util.Collections.unmodifiableList(bindings_);
-          bitField0_ = (bitField0_ & ~0x00000002);
+          bitField0_ = (bitField0_ & ~0x00000001);
         }
         result.bindings_ = bindings_;
       } else {
         result.bindings_ = bindingsBuilder_.build();
       }
       result.etag_ = etag_;
-      result.bitField0_ = to_bitField0_;
       onBuilt();
       return result;
     }
 
-    @Override
+    @java.lang.Override
     public Builder clone() {
       return super.clone();
     }
-    @Override
+
+    @java.lang.Override
     public Builder setField(
-        com.google.protobuf.Descriptors.FieldDescriptor field,
-        Object value) {
+        com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) {
       return super.setField(field, value);
     }
-    @Override
-    public Builder clearField(
-        com.google.protobuf.Descriptors.FieldDescriptor field) {
+
+    @java.lang.Override
+    public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) {
       return super.clearField(field);
     }
-    @Override
-    public Builder clearOneof(
-        com.google.protobuf.Descriptors.OneofDescriptor oneof) {
+
+    @java.lang.Override
+    public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) {
       return super.clearOneof(oneof);
     }
-    @Override
+
+    @java.lang.Override
     public Builder setRepeatedField(
-        com.google.protobuf.Descriptors.FieldDescriptor field,
-        int index, Object value) {
+        com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) {
       return super.setRepeatedField(field, index, value);
     }
-    @Override
+
+    @java.lang.Override
     public Builder addRepeatedField(
-        com.google.protobuf.Descriptors.FieldDescriptor field,
-        Object value) {
+        com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) {
       return super.addRepeatedField(field, value);
     }
-    @Override
+
+    @java.lang.Override
     public Builder mergeFrom(com.google.protobuf.Message other) {
-      if (other instanceof Policy) {
-        return mergeFrom((Policy)other);
+      if (other instanceof com.google.iam.v1.Policy) {
+        return mergeFrom((com.google.iam.v1.Policy) other);
       } else {
         super.mergeFrom(other);
         return this;
       }
     }
 
-    public Builder mergeFrom(Policy other) {
-      if (other == Policy.getDefaultInstance()) return this;
+    public Builder mergeFrom(com.google.iam.v1.Policy other) {
+      if (other == com.google.iam.v1.Policy.getDefaultInstance()) return this;
       if (other.getVersion() != 0) {
         setVersion(other.getVersion());
       }
@@ -638,7 +675,7 @@ public Builder mergeFrom(Policy other) {
         if (!other.bindings_.isEmpty()) {
           if (bindings_.isEmpty()) {
             bindings_ = other.bindings_;
-            bitField0_ = (bitField0_ & ~0x00000002);
+            bitField0_ = (bitField0_ & ~0x00000001);
           } else {
             ensureBindingsIsMutable();
             bindings_.addAll(other.bindings_);
@@ -651,10 +688,11 @@ public Builder mergeFrom(Policy other) {
             bindingsBuilder_.dispose();
             bindingsBuilder_ = null;
             bindings_ = other.bindings_;
-            bitField0_ = (bitField0_ & ~0x00000002);
-            bindingsBuilder_ = 
-              com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ?
-                 getBindingsFieldBuilder() : null;
+            bitField0_ = (bitField0_ & ~0x00000001);
+            bindingsBuilder_ =
+                com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders
+                    ? getBindingsFieldBuilder()
+                    : null;
           } else {
             bindingsBuilder_.addAllMessages(other.bindings_);
           }
@@ -668,21 +706,21 @@ public Builder mergeFrom(Policy other) {
       return this;
     }
 
-    @Override
+    @java.lang.Override
     public final boolean isInitialized() {
       return true;
     }
 
-    @Override
+    @java.lang.Override
     public Builder mergeFrom(
         com.google.protobuf.CodedInputStream input,
         com.google.protobuf.ExtensionRegistryLite extensionRegistry)
         throws java.io.IOException {
-      Policy parsedMessage = null;
+      com.google.iam.v1.Policy parsedMessage = null;
       try {
         parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
       } catch (com.google.protobuf.InvalidProtocolBufferException e) {
-        parsedMessage = (Policy) e.getUnfinishedMessage();
+        parsedMessage = (com.google.iam.v1.Policy) e.getUnfinishedMessage();
         throw e.unwrapIOException();
       } finally {
         if (parsedMessage != null) {
@@ -691,86 +729,108 @@ public Builder mergeFrom(
       }
       return this;
     }
+
     private int bitField0_;
 
-    private int version_ ;
+    private int version_;
     /**
+     *
+     *
      * 
      * Specifies the format of the policy.
      * Valid values are 0, 1, and 3. Requests specifying an invalid value will be
      * rejected.
      * Operations affecting conditional bindings must specify version 3. This can
      * be either setting a conditional policy, modifying a conditional binding,
-     * or removing a conditional binding from the stored conditional policy.
+     * or removing a binding (conditional or unconditional) from the stored
+     * conditional policy.
      * Operations on non-conditional policies may specify any valid value or
      * leave the field unset.
-     * If no etag is provided in the call to `setIamPolicy`, any version
-     * compliance checks on the incoming and/or stored policy is skipped.
+     * If no etag is provided in the call to `setIamPolicy`, version compliance
+     * checks against the stored policy is skipped.
      * 
* * int32 version = 1; + * + * @return The version. */ public int getVersion() { return version_; } /** + * + * *
      * Specifies the format of the policy.
      * Valid values are 0, 1, and 3. Requests specifying an invalid value will be
      * rejected.
      * Operations affecting conditional bindings must specify version 3. This can
      * be either setting a conditional policy, modifying a conditional binding,
-     * or removing a conditional binding from the stored conditional policy.
+     * or removing a binding (conditional or unconditional) from the stored
+     * conditional policy.
      * Operations on non-conditional policies may specify any valid value or
      * leave the field unset.
-     * If no etag is provided in the call to `setIamPolicy`, any version
-     * compliance checks on the incoming and/or stored policy is skipped.
+     * If no etag is provided in the call to `setIamPolicy`, version compliance
+     * checks against the stored policy is skipped.
      * 
* * int32 version = 1; + * + * @param value The version to set. + * @return This builder for chaining. */ public Builder setVersion(int value) { - + version_ = value; onChanged(); return this; } /** + * + * *
      * Specifies the format of the policy.
      * Valid values are 0, 1, and 3. Requests specifying an invalid value will be
      * rejected.
      * Operations affecting conditional bindings must specify version 3. This can
      * be either setting a conditional policy, modifying a conditional binding,
-     * or removing a conditional binding from the stored conditional policy.
+     * or removing a binding (conditional or unconditional) from the stored
+     * conditional policy.
      * Operations on non-conditional policies may specify any valid value or
      * leave the field unset.
-     * If no etag is provided in the call to `setIamPolicy`, any version
-     * compliance checks on the incoming and/or stored policy is skipped.
+     * If no etag is provided in the call to `setIamPolicy`, version compliance
+     * checks against the stored policy is skipped.
      * 
* * int32 version = 1; + * + * @return This builder for chaining. */ public Builder clearVersion() { - + version_ = 0; onChanged(); return this; } - private java.util.List bindings_ = - java.util.Collections.emptyList(); + private java.util.List bindings_ = java.util.Collections.emptyList(); + private void ensureBindingsIsMutable() { - if (!((bitField0_ & 0x00000002) != 0)) { + if (!((bitField0_ & 0x00000001) != 0)) { bindings_ = new java.util.ArrayList(bindings_); - bitField0_ |= 0x00000002; - } + bitField0_ |= 0x00000001; + } } private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.iam.v1.Binding, com.google.iam.v1.Binding.Builder, com.google.iam.v1.BindingOrBuilder> bindingsBuilder_; + com.google.iam.v1.Binding, + com.google.iam.v1.Binding.Builder, + com.google.iam.v1.BindingOrBuilder> + bindingsBuilder_; /** + * + * *
      * Associates a list of `members` to a `role`. Optionally may specify a
      * `condition` that determines when binding is in effect.
@@ -787,6 +847,8 @@ public java.util.List getBindingsList() {
       }
     }
     /**
+     *
+     *
      * 
      * Associates a list of `members` to a `role`. Optionally may specify a
      * `condition` that determines when binding is in effect.
@@ -803,6 +865,8 @@ public int getBindingsCount() {
       }
     }
     /**
+     *
+     *
      * 
      * Associates a list of `members` to a `role`. Optionally may specify a
      * `condition` that determines when binding is in effect.
@@ -819,6 +883,8 @@ public com.google.iam.v1.Binding getBindings(int index) {
       }
     }
     /**
+     *
+     *
      * 
      * Associates a list of `members` to a `role`. Optionally may specify a
      * `condition` that determines when binding is in effect.
@@ -827,8 +893,7 @@ public com.google.iam.v1.Binding getBindings(int index) {
      *
      * repeated .google.iam.v1.Binding bindings = 4;
      */
-    public Builder setBindings(
-        int index, com.google.iam.v1.Binding value) {
+    public Builder setBindings(int index, com.google.iam.v1.Binding value) {
       if (bindingsBuilder_ == null) {
         if (value == null) {
           throw new NullPointerException();
@@ -842,6 +907,8 @@ public Builder setBindings(
       return this;
     }
     /**
+     *
+     *
      * 
      * Associates a list of `members` to a `role`. Optionally may specify a
      * `condition` that determines when binding is in effect.
@@ -850,8 +917,7 @@ public Builder setBindings(
      *
      * repeated .google.iam.v1.Binding bindings = 4;
      */
-    public Builder setBindings(
-        int index, com.google.iam.v1.Binding.Builder builderForValue) {
+    public Builder setBindings(int index, com.google.iam.v1.Binding.Builder builderForValue) {
       if (bindingsBuilder_ == null) {
         ensureBindingsIsMutable();
         bindings_.set(index, builderForValue.build());
@@ -862,6 +928,8 @@ public Builder setBindings(
       return this;
     }
     /**
+     *
+     *
      * 
      * Associates a list of `members` to a `role`. Optionally may specify a
      * `condition` that determines when binding is in effect.
@@ -884,6 +952,8 @@ public Builder addBindings(com.google.iam.v1.Binding value) {
       return this;
     }
     /**
+     *
+     *
      * 
      * Associates a list of `members` to a `role`. Optionally may specify a
      * `condition` that determines when binding is in effect.
@@ -892,8 +962,7 @@ public Builder addBindings(com.google.iam.v1.Binding value) {
      *
      * repeated .google.iam.v1.Binding bindings = 4;
      */
-    public Builder addBindings(
-        int index, com.google.iam.v1.Binding value) {
+    public Builder addBindings(int index, com.google.iam.v1.Binding value) {
       if (bindingsBuilder_ == null) {
         if (value == null) {
           throw new NullPointerException();
@@ -907,6 +976,8 @@ public Builder addBindings(
       return this;
     }
     /**
+     *
+     *
      * 
      * Associates a list of `members` to a `role`. Optionally may specify a
      * `condition` that determines when binding is in effect.
@@ -915,8 +986,7 @@ public Builder addBindings(
      *
      * repeated .google.iam.v1.Binding bindings = 4;
      */
-    public Builder addBindings(
-        com.google.iam.v1.Binding.Builder builderForValue) {
+    public Builder addBindings(com.google.iam.v1.Binding.Builder builderForValue) {
       if (bindingsBuilder_ == null) {
         ensureBindingsIsMutable();
         bindings_.add(builderForValue.build());
@@ -927,6 +997,8 @@ public Builder addBindings(
       return this;
     }
     /**
+     *
+     *
      * 
      * Associates a list of `members` to a `role`. Optionally may specify a
      * `condition` that determines when binding is in effect.
@@ -935,8 +1007,7 @@ public Builder addBindings(
      *
      * repeated .google.iam.v1.Binding bindings = 4;
      */
-    public Builder addBindings(
-        int index, com.google.iam.v1.Binding.Builder builderForValue) {
+    public Builder addBindings(int index, com.google.iam.v1.Binding.Builder builderForValue) {
       if (bindingsBuilder_ == null) {
         ensureBindingsIsMutable();
         bindings_.add(index, builderForValue.build());
@@ -947,6 +1018,8 @@ public Builder addBindings(
       return this;
     }
     /**
+     *
+     *
      * 
      * Associates a list of `members` to a `role`. Optionally may specify a
      * `condition` that determines when binding is in effect.
@@ -955,12 +1028,10 @@ public Builder addBindings(
      *
      * repeated .google.iam.v1.Binding bindings = 4;
      */
-    public Builder addAllBindings(
-        Iterable values) {
+    public Builder addAllBindings(java.lang.Iterable values) {
       if (bindingsBuilder_ == null) {
         ensureBindingsIsMutable();
-        com.google.protobuf.AbstractMessageLite.Builder.addAll(
-            values, bindings_);
+        com.google.protobuf.AbstractMessageLite.Builder.addAll(values, bindings_);
         onChanged();
       } else {
         bindingsBuilder_.addAllMessages(values);
@@ -968,6 +1039,8 @@ public Builder addAllBindings(
       return this;
     }
     /**
+     *
+     *
      * 
      * Associates a list of `members` to a `role`. Optionally may specify a
      * `condition` that determines when binding is in effect.
@@ -979,7 +1052,7 @@ public Builder addAllBindings(
     public Builder clearBindings() {
       if (bindingsBuilder_ == null) {
         bindings_ = java.util.Collections.emptyList();
-        bitField0_ = (bitField0_ & ~0x00000002);
+        bitField0_ = (bitField0_ & ~0x00000001);
         onChanged();
       } else {
         bindingsBuilder_.clear();
@@ -987,6 +1060,8 @@ public Builder clearBindings() {
       return this;
     }
     /**
+     *
+     *
      * 
      * Associates a list of `members` to a `role`. Optionally may specify a
      * `condition` that determines when binding is in effect.
@@ -1006,6 +1081,8 @@ public Builder removeBindings(int index) {
       return this;
     }
     /**
+     *
+     *
      * 
      * Associates a list of `members` to a `role`. Optionally may specify a
      * `condition` that determines when binding is in effect.
@@ -1014,11 +1091,12 @@ public Builder removeBindings(int index) {
      *
      * repeated .google.iam.v1.Binding bindings = 4;
      */
-    public com.google.iam.v1.Binding.Builder getBindingsBuilder(
-        int index) {
+    public com.google.iam.v1.Binding.Builder getBindingsBuilder(int index) {
       return getBindingsFieldBuilder().getBuilder(index);
     }
     /**
+     *
+     *
      * 
      * Associates a list of `members` to a `role`. Optionally may specify a
      * `condition` that determines when binding is in effect.
@@ -1027,14 +1105,16 @@ public com.google.iam.v1.Binding.Builder getBindingsBuilder(
      *
      * repeated .google.iam.v1.Binding bindings = 4;
      */
-    public com.google.iam.v1.BindingOrBuilder getBindingsOrBuilder(
-        int index) {
+    public com.google.iam.v1.BindingOrBuilder getBindingsOrBuilder(int index) {
       if (bindingsBuilder_ == null) {
-        return bindings_.get(index);  } else {
+        return bindings_.get(index);
+      } else {
         return bindingsBuilder_.getMessageOrBuilder(index);
       }
     }
     /**
+     *
+     *
      * 
      * Associates a list of `members` to a `role`. Optionally may specify a
      * `condition` that determines when binding is in effect.
@@ -1043,8 +1123,7 @@ public com.google.iam.v1.BindingOrBuilder getBindingsOrBuilder(
      *
      * repeated .google.iam.v1.Binding bindings = 4;
      */
-    public java.util.List 
-         getBindingsOrBuilderList() {
+    public java.util.List getBindingsOrBuilderList() {
       if (bindingsBuilder_ != null) {
         return bindingsBuilder_.getMessageOrBuilderList();
       } else {
@@ -1052,6 +1131,8 @@ public com.google.iam.v1.BindingOrBuilder getBindingsOrBuilder(
       }
     }
     /**
+     *
+     *
      * 
      * Associates a list of `members` to a `role`. Optionally may specify a
      * `condition` that determines when binding is in effect.
@@ -1061,10 +1142,11 @@ public com.google.iam.v1.BindingOrBuilder getBindingsOrBuilder(
      * repeated .google.iam.v1.Binding bindings = 4;
      */
     public com.google.iam.v1.Binding.Builder addBindingsBuilder() {
-      return getBindingsFieldBuilder().addBuilder(
-          com.google.iam.v1.Binding.getDefaultInstance());
+      return getBindingsFieldBuilder().addBuilder(com.google.iam.v1.Binding.getDefaultInstance());
     }
     /**
+     *
+     *
      * 
      * Associates a list of `members` to a `role`. Optionally may specify a
      * `condition` that determines when binding is in effect.
@@ -1073,12 +1155,13 @@ public com.google.iam.v1.Binding.Builder addBindingsBuilder() {
      *
      * repeated .google.iam.v1.Binding bindings = 4;
      */
-    public com.google.iam.v1.Binding.Builder addBindingsBuilder(
-        int index) {
-      return getBindingsFieldBuilder().addBuilder(
-          index, com.google.iam.v1.Binding.getDefaultInstance());
+    public com.google.iam.v1.Binding.Builder addBindingsBuilder(int index) {
+      return getBindingsFieldBuilder()
+          .addBuilder(index, com.google.iam.v1.Binding.getDefaultInstance());
     }
     /**
+     *
+     *
      * 
      * Associates a list of `members` to a `role`. Optionally may specify a
      * `condition` that determines when binding is in effect.
@@ -1087,20 +1170,22 @@ public com.google.iam.v1.Binding.Builder addBindingsBuilder(
      *
      * repeated .google.iam.v1.Binding bindings = 4;
      */
-    public java.util.List 
-         getBindingsBuilderList() {
+    public java.util.List getBindingsBuilderList() {
       return getBindingsFieldBuilder().getBuilderList();
     }
+
     private com.google.protobuf.RepeatedFieldBuilderV3<
-        com.google.iam.v1.Binding, com.google.iam.v1.Binding.Builder, com.google.iam.v1.BindingOrBuilder> 
+            com.google.iam.v1.Binding,
+            com.google.iam.v1.Binding.Builder,
+            com.google.iam.v1.BindingOrBuilder>
         getBindingsFieldBuilder() {
       if (bindingsBuilder_ == null) {
-        bindingsBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3<
-            com.google.iam.v1.Binding, com.google.iam.v1.Binding.Builder, com.google.iam.v1.BindingOrBuilder>(
-                bindings_,
-                ((bitField0_ & 0x00000002) != 0),
-                getParentForChildren(),
-                isClean());
+        bindingsBuilder_ =
+            new com.google.protobuf.RepeatedFieldBuilderV3<
+                com.google.iam.v1.Binding,
+                com.google.iam.v1.Binding.Builder,
+                com.google.iam.v1.BindingOrBuilder>(
+                bindings_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), isClean());
         bindings_ = null;
       }
       return bindingsBuilder_;
@@ -1108,6 +1193,8 @@ public com.google.iam.v1.Binding.Builder addBindingsBuilder(
 
     private com.google.protobuf.ByteString etag_ = com.google.protobuf.ByteString.EMPTY;
     /**
+     *
+     *
      * 
      * `etag` is used for optimistic concurrency control as a way to help
      * prevent simultaneous updates of a policy from overwriting each other.
@@ -1118,16 +1205,20 @@ public com.google.iam.v1.Binding.Builder addBindingsBuilder(
      * ensure that their change will be applied to the same version of the policy.
      * If no `etag` is provided in the call to `setIamPolicy`, then the existing
      * policy is overwritten. Due to blind-set semantics of an etag-less policy,
-     * 'setIamPolicy' will not fail even if either of incoming or stored policy
-     * does not meet the version requirements.
+     * 'setIamPolicy' will not fail even if the incoming policy version does not
+     * meet the requirements for modifying the stored policy.
      * 
* * bytes etag = 3; + * + * @return The etag. */ public com.google.protobuf.ByteString getEtag() { return etag_; } /** + * + * *
      * `etag` is used for optimistic concurrency control as a way to help
      * prevent simultaneous updates of a policy from overwriting each other.
@@ -1138,22 +1229,27 @@ public com.google.protobuf.ByteString getEtag() {
      * ensure that their change will be applied to the same version of the policy.
      * If no `etag` is provided in the call to `setIamPolicy`, then the existing
      * policy is overwritten. Due to blind-set semantics of an etag-less policy,
-     * 'setIamPolicy' will not fail even if either of incoming or stored policy
-     * does not meet the version requirements.
+     * 'setIamPolicy' will not fail even if the incoming policy version does not
+     * meet the requirements for modifying the stored policy.
      * 
* * bytes etag = 3; + * + * @param value The etag to set. + * @return This builder for chaining. */ public Builder setEtag(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + etag_ = value; onChanged(); return this; } /** + * + * *
      * `etag` is used for optimistic concurrency control as a way to help
      * prevent simultaneous updates of a policy from overwriting each other.
@@ -1164,68 +1260,68 @@ public Builder setEtag(com.google.protobuf.ByteString value) {
      * ensure that their change will be applied to the same version of the policy.
      * If no `etag` is provided in the call to `setIamPolicy`, then the existing
      * policy is overwritten. Due to blind-set semantics of an etag-less policy,
-     * 'setIamPolicy' will not fail even if either of incoming or stored policy
-     * does not meet the version requirements.
+     * 'setIamPolicy' will not fail even if the incoming policy version does not
+     * meet the requirements for modifying the stored policy.
      * 
* * bytes etag = 3; + * + * @return This builder for chaining. */ public Builder clearEtag() { - + etag_ = getDefaultInstance().getEtag(); onChanged(); return this; } - @Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } - @Override + @java.lang.Override public final Builder mergeUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return super.mergeUnknownFields(unknownFields); } - // @@protoc_insertion_point(builder_scope:google.iam.v1.Policy) } // @@protoc_insertion_point(class_scope:google.iam.v1.Policy) - private static final Policy DEFAULT_INSTANCE; + private static final com.google.iam.v1.Policy DEFAULT_INSTANCE; + static { - DEFAULT_INSTANCE = new Policy(); + DEFAULT_INSTANCE = new com.google.iam.v1.Policy(); } - public static Policy getDefaultInstance() { + public static com.google.iam.v1.Policy getDefaultInstance() { return DEFAULT_INSTANCE; } - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - @Override - public Policy parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new Policy(input, extensionRegistry); - } - }; + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public Policy parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new Policy(input, extensionRegistry); + } + }; public static com.google.protobuf.Parser parser() { return PARSER; } - @Override + @java.lang.Override public com.google.protobuf.Parser getParserForType() { return PARSER; } - @Override - public Policy getDefaultInstanceForType() { + @java.lang.Override + public com.google.iam.v1.Policy getDefaultInstanceForType() { return DEFAULT_INSTANCE; } - } - diff --git a/proto-google-iam-v1/src/main/java/com/google/iam/v1/PolicyDelta.java b/proto-google-iam-v1/src/main/java/com/google/iam/v1/PolicyDelta.java index 937707bd..eeb22488 100644 --- a/proto-google-iam-v1/src/main/java/com/google/iam/v1/PolicyDelta.java +++ b/proto-google-iam-v1/src/main/java/com/google/iam/v1/PolicyDelta.java @@ -1,41 +1,65 @@ +/* + * 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/iam/v1/policy.proto package com.google.iam.v1; /** + * + * *
  * The difference delta between two policies.
  * 
* * Protobuf type {@code google.iam.v1.PolicyDelta} */ -public final class PolicyDelta extends - com.google.protobuf.GeneratedMessageV3 implements +public final class PolicyDelta extends com.google.protobuf.GeneratedMessageV3 + implements // @@protoc_insertion_point(message_implements:google.iam.v1.PolicyDelta) PolicyDeltaOrBuilder { -private static final long serialVersionUID = 0L; + private static final long serialVersionUID = 0L; // Use PolicyDelta.newBuilder() to construct. private PolicyDelta(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } + private PolicyDelta() { bindingDeltas_ = java.util.Collections.emptyList(); auditConfigDeltas_ = java.util.Collections.emptyList(); } - @Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new PolicyDelta(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } + private PolicyDelta( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { this(); if (extensionRegistry == null) { - throw new NullPointerException(); + throw new java.lang.NullPointerException(); } int mutable_bitField0_ = 0; com.google.protobuf.UnknownFieldSet.Builder unknownFields = @@ -48,38 +72,40 @@ private PolicyDelta( case 0: done = true; break; - case 10: { - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - bindingDeltas_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000001; + case 10: + { + if (!((mutable_bitField0_ & 0x00000001) != 0)) { + bindingDeltas_ = new java.util.ArrayList(); + mutable_bitField0_ |= 0x00000001; + } + bindingDeltas_.add( + input.readMessage(com.google.iam.v1.BindingDelta.parser(), extensionRegistry)); + break; } - bindingDeltas_.add( - input.readMessage(com.google.iam.v1.BindingDelta.parser(), extensionRegistry)); - break; - } - case 18: { - if (!((mutable_bitField0_ & 0x00000002) != 0)) { - auditConfigDeltas_ = new java.util.ArrayList(); - mutable_bitField0_ |= 0x00000002; + case 18: + { + if (!((mutable_bitField0_ & 0x00000002) != 0)) { + auditConfigDeltas_ = new java.util.ArrayList(); + mutable_bitField0_ |= 0x00000002; + } + auditConfigDeltas_.add( + input.readMessage( + com.google.iam.v1.AuditConfigDelta.parser(), extensionRegistry)); + break; } - auditConfigDeltas_.add( - input.readMessage(com.google.iam.v1.AuditConfigDelta.parser(), extensionRegistry)); - break; - } - default: { - if (!parseUnknownField( - input, unknownFields, extensionRegistry, tag)) { - done = true; + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; } - break; - } } } } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(this); } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException( - e).setUnfinishedMessage(this); + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); } finally { if (((mutable_bitField0_ & 0x00000001) != 0)) { bindingDeltas_ = java.util.Collections.unmodifiableList(bindingDeltas_); @@ -91,22 +117,25 @@ private PolicyDelta( makeExtensionsImmutable(); } } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.iam.v1.PolicyProto.internal_static_google_iam_v1_PolicyDelta_descriptor; } - @Override - protected FieldAccessorTable + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.iam.v1.PolicyProto.internal_static_google_iam_v1_PolicyDelta_fieldAccessorTable + return com.google.iam.v1.PolicyProto + .internal_static_google_iam_v1_PolicyDelta_fieldAccessorTable .ensureFieldAccessorsInitialized( - PolicyDelta.class, Builder.class); + com.google.iam.v1.PolicyDelta.class, com.google.iam.v1.PolicyDelta.Builder.class); } public static final int BINDING_DELTAS_FIELD_NUMBER = 1; private java.util.List bindingDeltas_; /** + * + * *
    * The delta for Bindings between two policies.
    * 
@@ -117,17 +146,21 @@ public java.util.List getBindingDeltasList() { return bindingDeltas_; } /** + * + * *
    * The delta for Bindings between two policies.
    * 
* * repeated .google.iam.v1.BindingDelta binding_deltas = 1; */ - public java.util.List + public java.util.List getBindingDeltasOrBuilderList() { return bindingDeltas_; } /** + * + * *
    * The delta for Bindings between two policies.
    * 
@@ -138,6 +171,8 @@ public int getBindingDeltasCount() { return bindingDeltas_.size(); } /** + * + * *
    * The delta for Bindings between two policies.
    * 
@@ -148,20 +183,23 @@ public com.google.iam.v1.BindingDelta getBindingDeltas(int index) { return bindingDeltas_.get(index); } /** + * + * *
    * The delta for Bindings between two policies.
    * 
* * repeated .google.iam.v1.BindingDelta binding_deltas = 1; */ - public com.google.iam.v1.BindingDeltaOrBuilder getBindingDeltasOrBuilder( - int index) { + public com.google.iam.v1.BindingDeltaOrBuilder getBindingDeltasOrBuilder(int index) { return bindingDeltas_.get(index); } public static final int AUDIT_CONFIG_DELTAS_FIELD_NUMBER = 2; private java.util.List auditConfigDeltas_; /** + * + * *
    * The delta for AuditConfigs between two policies.
    * 
@@ -172,17 +210,21 @@ public java.util.List getAuditConfigDeltasLi return auditConfigDeltas_; } /** + * + * *
    * The delta for AuditConfigs between two policies.
    * 
* * repeated .google.iam.v1.AuditConfigDelta audit_config_deltas = 2; */ - public java.util.List + public java.util.List getAuditConfigDeltasOrBuilderList() { return auditConfigDeltas_; } /** + * + * *
    * The delta for AuditConfigs between two policies.
    * 
@@ -193,6 +235,8 @@ public int getAuditConfigDeltasCount() { return auditConfigDeltas_.size(); } /** + * + * *
    * The delta for AuditConfigs between two policies.
    * 
@@ -203,19 +247,21 @@ public com.google.iam.v1.AuditConfigDelta getAuditConfigDeltas(int index) { return auditConfigDeltas_.get(index); } /** + * + * *
    * The delta for AuditConfigs between two policies.
    * 
* * repeated .google.iam.v1.AuditConfigDelta audit_config_deltas = 2; */ - public com.google.iam.v1.AuditConfigDeltaOrBuilder getAuditConfigDeltasOrBuilder( - int index) { + public com.google.iam.v1.AuditConfigDeltaOrBuilder getAuditConfigDeltasOrBuilder(int index) { return auditConfigDeltas_.get(index); } private byte memoizedIsInitialized = -1; - @Override + + @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; if (isInitialized == 1) return true; @@ -225,9 +271,8 @@ public final boolean isInitialized() { return true; } - @Override - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { for (int i = 0; i < bindingDeltas_.size(); i++) { output.writeMessage(1, bindingDeltas_.get(i)); } @@ -237,44 +282,41 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) unknownFields.writeTo(output); } - @Override + @java.lang.Override public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; for (int i = 0; i < bindingDeltas_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, bindingDeltas_.get(i)); + size += com.google.protobuf.CodedOutputStream.computeMessageSize(1, bindingDeltas_.get(i)); } for (int i = 0; i < auditConfigDeltas_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(2, auditConfigDeltas_.get(i)); + size += + com.google.protobuf.CodedOutputStream.computeMessageSize(2, auditConfigDeltas_.get(i)); } size += unknownFields.getSerializedSize(); memoizedSize = size; return size; } - @Override - public boolean equals(final Object obj) { + @java.lang.Override + public boolean equals(final java.lang.Object obj) { if (obj == this) { - return true; + return true; } - if (!(obj instanceof PolicyDelta)) { + if (!(obj instanceof com.google.iam.v1.PolicyDelta)) { return super.equals(obj); } - PolicyDelta other = (PolicyDelta) obj; + com.google.iam.v1.PolicyDelta other = (com.google.iam.v1.PolicyDelta) obj; - if (!getBindingDeltasList() - .equals(other.getBindingDeltasList())) return false; - if (!getAuditConfigDeltasList() - .equals(other.getAuditConfigDeltasList())) return false; + if (!getBindingDeltasList().equals(other.getBindingDeltasList())) return false; + if (!getAuditConfigDeltasList().equals(other.getAuditConfigDeltasList())) return false; if (!unknownFields.equals(other.unknownFields)) return false; return true; } - @Override + @java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; @@ -294,118 +336,124 @@ public int hashCode() { return hash; } - public static PolicyDelta parseFrom( - java.nio.ByteBuffer data) + public static com.google.iam.v1.PolicyDelta parseFrom(java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } - public static PolicyDelta parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + + public static com.google.iam.v1.PolicyDelta parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static PolicyDelta parseFrom( - com.google.protobuf.ByteString data) + + public static com.google.iam.v1.PolicyDelta parseFrom(com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } - public static PolicyDelta parseFrom( + + public static com.google.iam.v1.PolicyDelta parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static PolicyDelta parseFrom(byte[] data) + + public static com.google.iam.v1.PolicyDelta parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } - public static PolicyDelta parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + + public static com.google.iam.v1.PolicyDelta parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static PolicyDelta parseFrom(java.io.InputStream input) + + public static com.google.iam.v1.PolicyDelta parseFrom(java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } - public static PolicyDelta parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + + public static com.google.iam.v1.PolicyDelta parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } - public static PolicyDelta parseDelimitedFrom(java.io.InputStream input) + + public static com.google.iam.v1.PolicyDelta parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } - public static PolicyDelta parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + + public static com.google.iam.v1.PolicyDelta parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); } - public static PolicyDelta parseFrom( - com.google.protobuf.CodedInputStream input) + + public static com.google.iam.v1.PolicyDelta parseFrom(com.google.protobuf.CodedInputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } - public static PolicyDelta parseFrom( + + public static com.google.iam.v1.PolicyDelta parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); } - @Override - public Builder newBuilderForType() { return newBuilder(); } public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } - public static Builder newBuilder(PolicyDelta prototype) { + + public static Builder newBuilder(com.google.iam.v1.PolicyDelta prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } - @Override + + @java.lang.Override public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } - @Override - protected Builder newBuilderForType( - BuilderParent parent) { + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** + * + * *
    * The difference delta between two policies.
    * 
* * Protobuf type {@code google.iam.v1.PolicyDelta} */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements // @@protoc_insertion_point(builder_implements:google.iam.v1.PolicyDelta) com.google.iam.v1.PolicyDeltaOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { return com.google.iam.v1.PolicyProto.internal_static_google_iam_v1_PolicyDelta_descriptor; } - @Override - protected FieldAccessorTable + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return com.google.iam.v1.PolicyProto.internal_static_google_iam_v1_PolicyDelta_fieldAccessorTable + return com.google.iam.v1.PolicyProto + .internal_static_google_iam_v1_PolicyDelta_fieldAccessorTable .ensureFieldAccessorsInitialized( - PolicyDelta.class, Builder.class); + com.google.iam.v1.PolicyDelta.class, com.google.iam.v1.PolicyDelta.Builder.class); } // Construct using com.google.iam.v1.PolicyDelta.newBuilder() @@ -413,19 +461,19 @@ private Builder() { maybeForceBuilderInitialization(); } - private Builder( - BuilderParent parent) { + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); maybeForceBuilderInitialization(); } + private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) { getBindingDeltasFieldBuilder(); getAuditConfigDeltasFieldBuilder(); } } - @Override + + @java.lang.Override public Builder clear() { super.clear(); if (bindingDeltasBuilder_ == null) { @@ -443,29 +491,28 @@ public Builder clear() { return this; } - @Override - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { return com.google.iam.v1.PolicyProto.internal_static_google_iam_v1_PolicyDelta_descriptor; } - @Override - public PolicyDelta getDefaultInstanceForType() { - return PolicyDelta.getDefaultInstance(); + @java.lang.Override + public com.google.iam.v1.PolicyDelta getDefaultInstanceForType() { + return com.google.iam.v1.PolicyDelta.getDefaultInstance(); } - @Override - public PolicyDelta build() { - PolicyDelta result = buildPartial(); + @java.lang.Override + public com.google.iam.v1.PolicyDelta build() { + com.google.iam.v1.PolicyDelta result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } - @Override - public PolicyDelta buildPartial() { - PolicyDelta result = new PolicyDelta(this); + @java.lang.Override + public com.google.iam.v1.PolicyDelta buildPartial() { + com.google.iam.v1.PolicyDelta result = new com.google.iam.v1.PolicyDelta(this); int from_bitField0_ = bitField0_; if (bindingDeltasBuilder_ == null) { if (((bitField0_ & 0x00000001) != 0)) { @@ -489,50 +536,51 @@ public PolicyDelta buildPartial() { return result; } - @Override + @java.lang.Override public Builder clone() { return super.clone(); } - @Override + + @java.lang.Override public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } - @Override - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } - @Override - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } - @Override + + @java.lang.Override public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } - @Override + + @java.lang.Override public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } - @Override + + @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof PolicyDelta) { - return mergeFrom((PolicyDelta)other); + if (other instanceof com.google.iam.v1.PolicyDelta) { + return mergeFrom((com.google.iam.v1.PolicyDelta) other); } else { super.mergeFrom(other); return this; } } - public Builder mergeFrom(PolicyDelta other) { - if (other == PolicyDelta.getDefaultInstance()) return this; + public Builder mergeFrom(com.google.iam.v1.PolicyDelta other) { + if (other == com.google.iam.v1.PolicyDelta.getDefaultInstance()) return this; if (bindingDeltasBuilder_ == null) { if (!other.bindingDeltas_.isEmpty()) { if (bindingDeltas_.isEmpty()) { @@ -551,9 +599,10 @@ public Builder mergeFrom(PolicyDelta other) { bindingDeltasBuilder_ = null; bindingDeltas_ = other.bindingDeltas_; bitField0_ = (bitField0_ & ~0x00000001); - bindingDeltasBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getBindingDeltasFieldBuilder() : null; + bindingDeltasBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getBindingDeltasFieldBuilder() + : null; } else { bindingDeltasBuilder_.addAllMessages(other.bindingDeltas_); } @@ -577,9 +626,10 @@ public Builder mergeFrom(PolicyDelta other) { auditConfigDeltasBuilder_ = null; auditConfigDeltas_ = other.auditConfigDeltas_; bitField0_ = (bitField0_ & ~0x00000002); - auditConfigDeltasBuilder_ = - com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ? - getAuditConfigDeltasFieldBuilder() : null; + auditConfigDeltasBuilder_ = + com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders + ? getAuditConfigDeltasFieldBuilder() + : null; } else { auditConfigDeltasBuilder_.addAllMessages(other.auditConfigDeltas_); } @@ -590,21 +640,21 @@ public Builder mergeFrom(PolicyDelta other) { return this; } - @Override + @java.lang.Override public final boolean isInitialized() { return true; } - @Override + @java.lang.Override public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - PolicyDelta parsedMessage = null; + com.google.iam.v1.PolicyDelta parsedMessage = null; try { parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (PolicyDelta) e.getUnfinishedMessage(); + parsedMessage = (com.google.iam.v1.PolicyDelta) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { if (parsedMessage != null) { @@ -613,21 +663,28 @@ public Builder mergeFrom( } return this; } + private int bitField0_; private java.util.List bindingDeltas_ = - java.util.Collections.emptyList(); + java.util.Collections.emptyList(); + private void ensureBindingDeltasIsMutable() { if (!((bitField0_ & 0x00000001) != 0)) { bindingDeltas_ = new java.util.ArrayList(bindingDeltas_); bitField0_ |= 0x00000001; - } + } } private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.iam.v1.BindingDelta, com.google.iam.v1.BindingDelta.Builder, com.google.iam.v1.BindingDeltaOrBuilder> bindingDeltasBuilder_; + com.google.iam.v1.BindingDelta, + com.google.iam.v1.BindingDelta.Builder, + com.google.iam.v1.BindingDeltaOrBuilder> + bindingDeltasBuilder_; /** + * + * *
      * The delta for Bindings between two policies.
      * 
@@ -642,6 +699,8 @@ public java.util.List getBindingDeltasList() { } } /** + * + * *
      * The delta for Bindings between two policies.
      * 
@@ -656,6 +715,8 @@ public int getBindingDeltasCount() { } } /** + * + * *
      * The delta for Bindings between two policies.
      * 
@@ -670,14 +731,15 @@ public com.google.iam.v1.BindingDelta getBindingDeltas(int index) { } } /** + * + * *
      * The delta for Bindings between two policies.
      * 
* * repeated .google.iam.v1.BindingDelta binding_deltas = 1; */ - public Builder setBindingDeltas( - int index, com.google.iam.v1.BindingDelta value) { + public Builder setBindingDeltas(int index, com.google.iam.v1.BindingDelta value) { if (bindingDeltasBuilder_ == null) { if (value == null) { throw new NullPointerException(); @@ -691,6 +753,8 @@ public Builder setBindingDeltas( return this; } /** + * + * *
      * The delta for Bindings between two policies.
      * 
@@ -709,6 +773,8 @@ public Builder setBindingDeltas( return this; } /** + * + * *
      * The delta for Bindings between two policies.
      * 
@@ -729,14 +795,15 @@ public Builder addBindingDeltas(com.google.iam.v1.BindingDelta value) { return this; } /** + * + * *
      * The delta for Bindings between two policies.
      * 
* * repeated .google.iam.v1.BindingDelta binding_deltas = 1; */ - public Builder addBindingDeltas( - int index, com.google.iam.v1.BindingDelta value) { + public Builder addBindingDeltas(int index, com.google.iam.v1.BindingDelta value) { if (bindingDeltasBuilder_ == null) { if (value == null) { throw new NullPointerException(); @@ -750,14 +817,15 @@ public Builder addBindingDeltas( return this; } /** + * + * *
      * The delta for Bindings between two policies.
      * 
* * repeated .google.iam.v1.BindingDelta binding_deltas = 1; */ - public Builder addBindingDeltas( - com.google.iam.v1.BindingDelta.Builder builderForValue) { + public Builder addBindingDeltas(com.google.iam.v1.BindingDelta.Builder builderForValue) { if (bindingDeltasBuilder_ == null) { ensureBindingDeltasIsMutable(); bindingDeltas_.add(builderForValue.build()); @@ -768,6 +836,8 @@ public Builder addBindingDeltas( return this; } /** + * + * *
      * The delta for Bindings between two policies.
      * 
@@ -786,6 +856,8 @@ public Builder addBindingDeltas( return this; } /** + * + * *
      * The delta for Bindings between two policies.
      * 
@@ -793,11 +865,10 @@ public Builder addBindingDeltas( * repeated .google.iam.v1.BindingDelta binding_deltas = 1; */ public Builder addAllBindingDeltas( - Iterable values) { + java.lang.Iterable values) { if (bindingDeltasBuilder_ == null) { ensureBindingDeltasIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, bindingDeltas_); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, bindingDeltas_); onChanged(); } else { bindingDeltasBuilder_.addAllMessages(values); @@ -805,6 +876,8 @@ public Builder addAllBindingDeltas( return this; } /** + * + * *
      * The delta for Bindings between two policies.
      * 
@@ -822,6 +895,8 @@ public Builder clearBindingDeltas() { return this; } /** + * + * *
      * The delta for Bindings between two policies.
      * 
@@ -839,39 +914,44 @@ public Builder removeBindingDeltas(int index) { return this; } /** + * + * *
      * The delta for Bindings between two policies.
      * 
* * repeated .google.iam.v1.BindingDelta binding_deltas = 1; */ - public com.google.iam.v1.BindingDelta.Builder getBindingDeltasBuilder( - int index) { + public com.google.iam.v1.BindingDelta.Builder getBindingDeltasBuilder(int index) { return getBindingDeltasFieldBuilder().getBuilder(index); } /** + * + * *
      * The delta for Bindings between two policies.
      * 
* * repeated .google.iam.v1.BindingDelta binding_deltas = 1; */ - public com.google.iam.v1.BindingDeltaOrBuilder getBindingDeltasOrBuilder( - int index) { + public com.google.iam.v1.BindingDeltaOrBuilder getBindingDeltasOrBuilder(int index) { if (bindingDeltasBuilder_ == null) { - return bindingDeltas_.get(index); } else { + return bindingDeltas_.get(index); + } else { return bindingDeltasBuilder_.getMessageOrBuilder(index); } } /** + * + * *
      * The delta for Bindings between two policies.
      * 
* * repeated .google.iam.v1.BindingDelta binding_deltas = 1; */ - public java.util.List - getBindingDeltasOrBuilderList() { + public java.util.List + getBindingDeltasOrBuilderList() { if (bindingDeltasBuilder_ != null) { return bindingDeltasBuilder_.getMessageOrBuilderList(); } else { @@ -879,6 +959,8 @@ public com.google.iam.v1.BindingDeltaOrBuilder getBindingDeltasOrBuilder( } } /** + * + * *
      * The delta for Bindings between two policies.
      * 
@@ -886,38 +968,46 @@ public com.google.iam.v1.BindingDeltaOrBuilder getBindingDeltasOrBuilder( * repeated .google.iam.v1.BindingDelta binding_deltas = 1; */ public com.google.iam.v1.BindingDelta.Builder addBindingDeltasBuilder() { - return getBindingDeltasFieldBuilder().addBuilder( - com.google.iam.v1.BindingDelta.getDefaultInstance()); + return getBindingDeltasFieldBuilder() + .addBuilder(com.google.iam.v1.BindingDelta.getDefaultInstance()); } /** + * + * *
      * The delta for Bindings between two policies.
      * 
* * repeated .google.iam.v1.BindingDelta binding_deltas = 1; */ - public com.google.iam.v1.BindingDelta.Builder addBindingDeltasBuilder( - int index) { - return getBindingDeltasFieldBuilder().addBuilder( - index, com.google.iam.v1.BindingDelta.getDefaultInstance()); + public com.google.iam.v1.BindingDelta.Builder addBindingDeltasBuilder(int index) { + return getBindingDeltasFieldBuilder() + .addBuilder(index, com.google.iam.v1.BindingDelta.getDefaultInstance()); } /** + * + * *
      * The delta for Bindings between two policies.
      * 
* * repeated .google.iam.v1.BindingDelta binding_deltas = 1; */ - public java.util.List - getBindingDeltasBuilderList() { + public java.util.List getBindingDeltasBuilderList() { return getBindingDeltasFieldBuilder().getBuilderList(); } + private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.iam.v1.BindingDelta, com.google.iam.v1.BindingDelta.Builder, com.google.iam.v1.BindingDeltaOrBuilder> + com.google.iam.v1.BindingDelta, + com.google.iam.v1.BindingDelta.Builder, + com.google.iam.v1.BindingDeltaOrBuilder> getBindingDeltasFieldBuilder() { if (bindingDeltasBuilder_ == null) { - bindingDeltasBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.iam.v1.BindingDelta, com.google.iam.v1.BindingDelta.Builder, com.google.iam.v1.BindingDeltaOrBuilder>( + bindingDeltasBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.iam.v1.BindingDelta, + com.google.iam.v1.BindingDelta.Builder, + com.google.iam.v1.BindingDeltaOrBuilder>( bindingDeltas_, ((bitField0_ & 0x00000001) != 0), getParentForChildren(), @@ -928,18 +1018,25 @@ public com.google.iam.v1.BindingDelta.Builder addBindingDeltasBuilder( } private java.util.List auditConfigDeltas_ = - java.util.Collections.emptyList(); + java.util.Collections.emptyList(); + private void ensureAuditConfigDeltasIsMutable() { if (!((bitField0_ & 0x00000002) != 0)) { - auditConfigDeltas_ = new java.util.ArrayList(auditConfigDeltas_); + auditConfigDeltas_ = + new java.util.ArrayList(auditConfigDeltas_); bitField0_ |= 0x00000002; - } + } } private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.iam.v1.AuditConfigDelta, com.google.iam.v1.AuditConfigDelta.Builder, com.google.iam.v1.AuditConfigDeltaOrBuilder> auditConfigDeltasBuilder_; + com.google.iam.v1.AuditConfigDelta, + com.google.iam.v1.AuditConfigDelta.Builder, + com.google.iam.v1.AuditConfigDeltaOrBuilder> + auditConfigDeltasBuilder_; /** + * + * *
      * The delta for AuditConfigs between two policies.
      * 
@@ -954,6 +1051,8 @@ public java.util.List getAuditConfigDeltasLi } } /** + * + * *
      * The delta for AuditConfigs between two policies.
      * 
@@ -968,6 +1067,8 @@ public int getAuditConfigDeltasCount() { } } /** + * + * *
      * The delta for AuditConfigs between two policies.
      * 
@@ -982,14 +1083,15 @@ public com.google.iam.v1.AuditConfigDelta getAuditConfigDeltas(int index) { } } /** + * + * *
      * The delta for AuditConfigs between two policies.
      * 
* * repeated .google.iam.v1.AuditConfigDelta audit_config_deltas = 2; */ - public Builder setAuditConfigDeltas( - int index, com.google.iam.v1.AuditConfigDelta value) { + public Builder setAuditConfigDeltas(int index, com.google.iam.v1.AuditConfigDelta value) { if (auditConfigDeltasBuilder_ == null) { if (value == null) { throw new NullPointerException(); @@ -1003,6 +1105,8 @@ public Builder setAuditConfigDeltas( return this; } /** + * + * *
      * The delta for AuditConfigs between two policies.
      * 
@@ -1021,6 +1125,8 @@ public Builder setAuditConfigDeltas( return this; } /** + * + * *
      * The delta for AuditConfigs between two policies.
      * 
@@ -1041,14 +1147,15 @@ public Builder addAuditConfigDeltas(com.google.iam.v1.AuditConfigDelta value) { return this; } /** + * + * *
      * The delta for AuditConfigs between two policies.
      * 
* * repeated .google.iam.v1.AuditConfigDelta audit_config_deltas = 2; */ - public Builder addAuditConfigDeltas( - int index, com.google.iam.v1.AuditConfigDelta value) { + public Builder addAuditConfigDeltas(int index, com.google.iam.v1.AuditConfigDelta value) { if (auditConfigDeltasBuilder_ == null) { if (value == null) { throw new NullPointerException(); @@ -1062,6 +1169,8 @@ public Builder addAuditConfigDeltas( return this; } /** + * + * *
      * The delta for AuditConfigs between two policies.
      * 
@@ -1080,6 +1189,8 @@ public Builder addAuditConfigDeltas( return this; } /** + * + * *
      * The delta for AuditConfigs between two policies.
      * 
@@ -1098,6 +1209,8 @@ public Builder addAuditConfigDeltas( return this; } /** + * + * *
      * The delta for AuditConfigs between two policies.
      * 
@@ -1105,11 +1218,10 @@ public Builder addAuditConfigDeltas( * repeated .google.iam.v1.AuditConfigDelta audit_config_deltas = 2; */ public Builder addAllAuditConfigDeltas( - Iterable values) { + java.lang.Iterable values) { if (auditConfigDeltasBuilder_ == null) { ensureAuditConfigDeltasIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, auditConfigDeltas_); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, auditConfigDeltas_); onChanged(); } else { auditConfigDeltasBuilder_.addAllMessages(values); @@ -1117,6 +1229,8 @@ public Builder addAllAuditConfigDeltas( return this; } /** + * + * *
      * The delta for AuditConfigs between two policies.
      * 
@@ -1134,6 +1248,8 @@ public Builder clearAuditConfigDeltas() { return this; } /** + * + * *
      * The delta for AuditConfigs between two policies.
      * 
@@ -1151,39 +1267,44 @@ public Builder removeAuditConfigDeltas(int index) { return this; } /** + * + * *
      * The delta for AuditConfigs between two policies.
      * 
* * repeated .google.iam.v1.AuditConfigDelta audit_config_deltas = 2; */ - public com.google.iam.v1.AuditConfigDelta.Builder getAuditConfigDeltasBuilder( - int index) { + public com.google.iam.v1.AuditConfigDelta.Builder getAuditConfigDeltasBuilder(int index) { return getAuditConfigDeltasFieldBuilder().getBuilder(index); } /** + * + * *
      * The delta for AuditConfigs between two policies.
      * 
* * repeated .google.iam.v1.AuditConfigDelta audit_config_deltas = 2; */ - public com.google.iam.v1.AuditConfigDeltaOrBuilder getAuditConfigDeltasOrBuilder( - int index) { + public com.google.iam.v1.AuditConfigDeltaOrBuilder getAuditConfigDeltasOrBuilder(int index) { if (auditConfigDeltasBuilder_ == null) { - return auditConfigDeltas_.get(index); } else { + return auditConfigDeltas_.get(index); + } else { return auditConfigDeltasBuilder_.getMessageOrBuilder(index); } } /** + * + * *
      * The delta for AuditConfigs between two policies.
      * 
* * repeated .google.iam.v1.AuditConfigDelta audit_config_deltas = 2; */ - public java.util.List - getAuditConfigDeltasOrBuilderList() { + public java.util.List + getAuditConfigDeltasOrBuilderList() { if (auditConfigDeltasBuilder_ != null) { return auditConfigDeltasBuilder_.getMessageOrBuilderList(); } else { @@ -1191,6 +1312,8 @@ public com.google.iam.v1.AuditConfigDeltaOrBuilder getAuditConfigDeltasOrBuilder } } /** + * + * *
      * The delta for AuditConfigs between two policies.
      * 
@@ -1198,38 +1321,47 @@ public com.google.iam.v1.AuditConfigDeltaOrBuilder getAuditConfigDeltasOrBuilder * repeated .google.iam.v1.AuditConfigDelta audit_config_deltas = 2; */ public com.google.iam.v1.AuditConfigDelta.Builder addAuditConfigDeltasBuilder() { - return getAuditConfigDeltasFieldBuilder().addBuilder( - com.google.iam.v1.AuditConfigDelta.getDefaultInstance()); + return getAuditConfigDeltasFieldBuilder() + .addBuilder(com.google.iam.v1.AuditConfigDelta.getDefaultInstance()); } /** + * + * *
      * The delta for AuditConfigs between two policies.
      * 
* * repeated .google.iam.v1.AuditConfigDelta audit_config_deltas = 2; */ - public com.google.iam.v1.AuditConfigDelta.Builder addAuditConfigDeltasBuilder( - int index) { - return getAuditConfigDeltasFieldBuilder().addBuilder( - index, com.google.iam.v1.AuditConfigDelta.getDefaultInstance()); + public com.google.iam.v1.AuditConfigDelta.Builder addAuditConfigDeltasBuilder(int index) { + return getAuditConfigDeltasFieldBuilder() + .addBuilder(index, com.google.iam.v1.AuditConfigDelta.getDefaultInstance()); } /** + * + * *
      * The delta for AuditConfigs between two policies.
      * 
* * repeated .google.iam.v1.AuditConfigDelta audit_config_deltas = 2; */ - public java.util.List - getAuditConfigDeltasBuilderList() { + public java.util.List + getAuditConfigDeltasBuilderList() { return getAuditConfigDeltasFieldBuilder().getBuilderList(); } + private com.google.protobuf.RepeatedFieldBuilderV3< - com.google.iam.v1.AuditConfigDelta, com.google.iam.v1.AuditConfigDelta.Builder, com.google.iam.v1.AuditConfigDeltaOrBuilder> + com.google.iam.v1.AuditConfigDelta, + com.google.iam.v1.AuditConfigDelta.Builder, + com.google.iam.v1.AuditConfigDeltaOrBuilder> getAuditConfigDeltasFieldBuilder() { if (auditConfigDeltasBuilder_ == null) { - auditConfigDeltasBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3< - com.google.iam.v1.AuditConfigDelta, com.google.iam.v1.AuditConfigDelta.Builder, com.google.iam.v1.AuditConfigDeltaOrBuilder>( + auditConfigDeltasBuilder_ = + new com.google.protobuf.RepeatedFieldBuilderV3< + com.google.iam.v1.AuditConfigDelta, + com.google.iam.v1.AuditConfigDelta.Builder, + com.google.iam.v1.AuditConfigDeltaOrBuilder>( auditConfigDeltas_, ((bitField0_ & 0x00000002) != 0), getParentForChildren(), @@ -1238,56 +1370,54 @@ public com.google.iam.v1.AuditConfigDelta.Builder addAuditConfigDeltasBuilder( } return auditConfigDeltasBuilder_; } - @Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } - @Override + @java.lang.Override public final Builder mergeUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return super.mergeUnknownFields(unknownFields); } - // @@protoc_insertion_point(builder_scope:google.iam.v1.PolicyDelta) } // @@protoc_insertion_point(class_scope:google.iam.v1.PolicyDelta) - private static final PolicyDelta DEFAULT_INSTANCE; + private static final com.google.iam.v1.PolicyDelta DEFAULT_INSTANCE; + static { - DEFAULT_INSTANCE = new PolicyDelta(); + DEFAULT_INSTANCE = new com.google.iam.v1.PolicyDelta(); } - public static PolicyDelta getDefaultInstance() { + public static com.google.iam.v1.PolicyDelta getDefaultInstance() { return DEFAULT_INSTANCE; } - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - @Override - public PolicyDelta parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new PolicyDelta(input, extensionRegistry); - } - }; + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public PolicyDelta parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new PolicyDelta(input, extensionRegistry); + } + }; public static com.google.protobuf.Parser parser() { return PARSER; } - @Override + @java.lang.Override public com.google.protobuf.Parser getParserForType() { return PARSER; } - @Override - public PolicyDelta getDefaultInstanceForType() { + @java.lang.Override + public com.google.iam.v1.PolicyDelta getDefaultInstanceForType() { return DEFAULT_INSTANCE; } - } - diff --git a/proto-google-iam-v1/src/main/java/com/google/iam/v1/PolicyDeltaOrBuilder.java b/proto-google-iam-v1/src/main/java/com/google/iam/v1/PolicyDeltaOrBuilder.java index e1735b94..fd3e1c0d 100644 --- a/proto-google-iam-v1/src/main/java/com/google/iam/v1/PolicyDeltaOrBuilder.java +++ b/proto-google-iam-v1/src/main/java/com/google/iam/v1/PolicyDeltaOrBuilder.java @@ -1,30 +1,51 @@ +/* + * 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/iam/v1/policy.proto package com.google.iam.v1; -public interface PolicyDeltaOrBuilder extends +public interface PolicyDeltaOrBuilder + extends // @@protoc_insertion_point(interface_extends:google.iam.v1.PolicyDelta) com.google.protobuf.MessageOrBuilder { /** + * + * *
    * The delta for Bindings between two policies.
    * 
* * repeated .google.iam.v1.BindingDelta binding_deltas = 1; */ - java.util.List - getBindingDeltasList(); + java.util.List getBindingDeltasList(); /** + * + * *
    * The delta for Bindings between two policies.
    * 
* * repeated .google.iam.v1.BindingDelta binding_deltas = 1; */ - BindingDelta getBindingDeltas(int index); + com.google.iam.v1.BindingDelta getBindingDeltas(int index); /** + * + * *
    * The delta for Bindings between two policies.
    * 
@@ -33,42 +54,49 @@ public interface PolicyDeltaOrBuilder extends */ int getBindingDeltasCount(); /** + * + * *
    * The delta for Bindings between two policies.
    * 
* * repeated .google.iam.v1.BindingDelta binding_deltas = 1; */ - java.util.List - getBindingDeltasOrBuilderList(); + java.util.List getBindingDeltasOrBuilderList(); /** + * + * *
    * The delta for Bindings between two policies.
    * 
* * repeated .google.iam.v1.BindingDelta binding_deltas = 1; */ - com.google.iam.v1.BindingDeltaOrBuilder getBindingDeltasOrBuilder( - int index); + com.google.iam.v1.BindingDeltaOrBuilder getBindingDeltasOrBuilder(int index); /** + * + * *
    * The delta for AuditConfigs between two policies.
    * 
* * repeated .google.iam.v1.AuditConfigDelta audit_config_deltas = 2; */ - java.util.List - getAuditConfigDeltasList(); + java.util.List getAuditConfigDeltasList(); /** + * + * *
    * The delta for AuditConfigs between two policies.
    * 
* * repeated .google.iam.v1.AuditConfigDelta audit_config_deltas = 2; */ - AuditConfigDelta getAuditConfigDeltas(int index); + com.google.iam.v1.AuditConfigDelta getAuditConfigDeltas(int index); /** + * + * *
    * The delta for AuditConfigs between two policies.
    * 
@@ -77,21 +105,24 @@ com.google.iam.v1.BindingDeltaOrBuilder getBindingDeltasOrBuilder( */ int getAuditConfigDeltasCount(); /** + * + * *
    * The delta for AuditConfigs between two policies.
    * 
* * repeated .google.iam.v1.AuditConfigDelta audit_config_deltas = 2; */ - java.util.List + java.util.List getAuditConfigDeltasOrBuilderList(); /** + * + * *
    * The delta for AuditConfigs between two policies.
    * 
* * repeated .google.iam.v1.AuditConfigDelta audit_config_deltas = 2; */ - com.google.iam.v1.AuditConfigDeltaOrBuilder getAuditConfigDeltasOrBuilder( - int index); + com.google.iam.v1.AuditConfigDeltaOrBuilder getAuditConfigDeltasOrBuilder(int index); } diff --git a/proto-google-iam-v1/src/main/java/com/google/iam/v1/PolicyOrBuilder.java b/proto-google-iam-v1/src/main/java/com/google/iam/v1/PolicyOrBuilder.java index 99b9548b..6be361f3 100644 --- a/proto-google-iam-v1/src/main/java/com/google/iam/v1/PolicyOrBuilder.java +++ b/proto-google-iam-v1/src/main/java/com/google/iam/v1/PolicyOrBuilder.java @@ -1,31 +1,54 @@ +/* + * 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/iam/v1/policy.proto package com.google.iam.v1; -public interface PolicyOrBuilder extends +public interface PolicyOrBuilder + extends // @@protoc_insertion_point(interface_extends:google.iam.v1.Policy) com.google.protobuf.MessageOrBuilder { /** + * + * *
    * Specifies the format of the policy.
    * Valid values are 0, 1, and 3. Requests specifying an invalid value will be
    * rejected.
    * Operations affecting conditional bindings must specify version 3. This can
    * be either setting a conditional policy, modifying a conditional binding,
-   * or removing a conditional binding from the stored conditional policy.
+   * or removing a binding (conditional or unconditional) from the stored
+   * conditional policy.
    * Operations on non-conditional policies may specify any valid value or
    * leave the field unset.
-   * If no etag is provided in the call to `setIamPolicy`, any version
-   * compliance checks on the incoming and/or stored policy is skipped.
+   * If no etag is provided in the call to `setIamPolicy`, version compliance
+   * checks against the stored policy is skipped.
    * 
* * int32 version = 1; + * + * @return The version. */ int getVersion(); /** + * + * *
    * Associates a list of `members` to a `role`. Optionally may specify a
    * `condition` that determines when binding is in effect.
@@ -34,9 +57,10 @@ public interface PolicyOrBuilder extends
    *
    * repeated .google.iam.v1.Binding bindings = 4;
    */
-  java.util.List
-      getBindingsList();
+  java.util.List getBindingsList();
   /**
+   *
+   *
    * 
    * Associates a list of `members` to a `role`. Optionally may specify a
    * `condition` that determines when binding is in effect.
@@ -45,8 +69,10 @@ public interface PolicyOrBuilder extends
    *
    * repeated .google.iam.v1.Binding bindings = 4;
    */
-  Binding getBindings(int index);
+  com.google.iam.v1.Binding getBindings(int index);
   /**
+   *
+   *
    * 
    * Associates a list of `members` to a `role`. Optionally may specify a
    * `condition` that determines when binding is in effect.
@@ -57,6 +83,8 @@ public interface PolicyOrBuilder extends
    */
   int getBindingsCount();
   /**
+   *
+   *
    * 
    * Associates a list of `members` to a `role`. Optionally may specify a
    * `condition` that determines when binding is in effect.
@@ -65,9 +93,10 @@ public interface PolicyOrBuilder extends
    *
    * repeated .google.iam.v1.Binding bindings = 4;
    */
-  java.util.List 
-      getBindingsOrBuilderList();
+  java.util.List getBindingsOrBuilderList();
   /**
+   *
+   *
    * 
    * Associates a list of `members` to a `role`. Optionally may specify a
    * `condition` that determines when binding is in effect.
@@ -76,10 +105,11 @@ public interface PolicyOrBuilder extends
    *
    * repeated .google.iam.v1.Binding bindings = 4;
    */
-  com.google.iam.v1.BindingOrBuilder getBindingsOrBuilder(
-      int index);
+  com.google.iam.v1.BindingOrBuilder getBindingsOrBuilder(int index);
 
   /**
+   *
+   *
    * 
    * `etag` is used for optimistic concurrency control as a way to help
    * prevent simultaneous updates of a policy from overwriting each other.
@@ -90,11 +120,13 @@ com.google.iam.v1.BindingOrBuilder getBindingsOrBuilder(
    * ensure that their change will be applied to the same version of the policy.
    * If no `etag` is provided in the call to `setIamPolicy`, then the existing
    * policy is overwritten. Due to blind-set semantics of an etag-less policy,
-   * 'setIamPolicy' will not fail even if either of incoming or stored policy
-   * does not meet the version requirements.
+   * 'setIamPolicy' will not fail even if the incoming policy version does not
+   * meet the requirements for modifying the stored policy.
    * 
* * bytes etag = 3; + * + * @return The etag. */ com.google.protobuf.ByteString getEtag(); } diff --git a/proto-google-iam-v1/src/main/java/com/google/iam/v1/PolicyProto.java b/proto-google-iam-v1/src/main/java/com/google/iam/v1/PolicyProto.java index d25ff666..2eee39d0 100644 --- a/proto-google-iam-v1/src/main/java/com/google/iam/v1/PolicyProto.java +++ b/proto-google-iam-v1/src/main/java/com/google/iam/v1/PolicyProto.java @@ -1,3 +1,18 @@ +/* + * 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/iam/v1/policy.proto @@ -5,117 +20,110 @@ public final class PolicyProto { private PolicyProto() {} - public static void registerAllExtensions( - com.google.protobuf.ExtensionRegistryLite registry) { - } - public static void registerAllExtensions( - com.google.protobuf.ExtensionRegistry registry) { - registerAllExtensions( - (com.google.protobuf.ExtensionRegistryLite) registry); + 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_iam_v1_Policy_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_iam_v1_Policy_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internal_static_google_iam_v1_Policy_fieldAccessorTable; static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_iam_v1_Binding_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_iam_v1_Binding_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internal_static_google_iam_v1_Binding_fieldAccessorTable; static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_iam_v1_PolicyDelta_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_iam_v1_PolicyDelta_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internal_static_google_iam_v1_PolicyDelta_fieldAccessorTable; static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_iam_v1_BindingDelta_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_iam_v1_BindingDelta_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internal_static_google_iam_v1_BindingDelta_fieldAccessorTable; static final com.google.protobuf.Descriptors.Descriptor - internal_static_google_iam_v1_AuditConfigDelta_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_iam_v1_AuditConfigDelta_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internal_static_google_iam_v1_AuditConfigDelta_fieldAccessorTable; - public static com.google.protobuf.Descriptors.FileDescriptor - getDescriptor() { + public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { return descriptor; } - private static com.google.protobuf.Descriptors.FileDescriptor - descriptor; + + private static com.google.protobuf.Descriptors.FileDescriptor descriptor; + static { - String[] descriptorData = { - "\n\032google/iam/v1/policy.proto\022\rgoogle.iam" + - ".v1\032\026google/type/expr.proto\032\034google/api/" + - "annotations.proto\"Q\n\006Policy\022\017\n\007version\030\001" + - " \001(\005\022(\n\010bindings\030\004 \003(\0132\026.google.iam.v1.B" + - "inding\022\014\n\004etag\030\003 \001(\014\"N\n\007Binding\022\014\n\004role\030" + - "\001 \001(\t\022\017\n\007members\030\002 \003(\t\022$\n\tcondition\030\003 \001(" + - "\0132\021.google.type.Expr\"\200\001\n\013PolicyDelta\0223\n\016" + - "binding_deltas\030\001 \003(\0132\033.google.iam.v1.Bin" + - "dingDelta\022<\n\023audit_config_deltas\030\002 \003(\0132\037" + - ".google.iam.v1.AuditConfigDelta\"\275\001\n\014Bind" + - "ingDelta\0222\n\006action\030\001 \001(\0162\".google.iam.v1" + - ".BindingDelta.Action\022\014\n\004role\030\002 \001(\t\022\016\n\006me" + - "mber\030\003 \001(\t\022$\n\tcondition\030\004 \001(\0132\021.google.t" + - "ype.Expr\"5\n\006Action\022\026\n\022ACTION_UNSPECIFIED" + - "\020\000\022\007\n\003ADD\020\001\022\n\n\006REMOVE\020\002\"\275\001\n\020AuditConfigD" + - "elta\0226\n\006action\030\001 \001(\0162&.google.iam.v1.Aud" + - "itConfigDelta.Action\022\017\n\007service\030\002 \001(\t\022\027\n" + - "\017exempted_member\030\003 \001(\t\022\020\n\010log_type\030\004 \001(\t" + - "\"5\n\006Action\022\026\n\022ACTION_UNSPECIFIED\020\000\022\007\n\003AD" + - "D\020\001\022\n\n\006REMOVE\020\002B\203\001\n\021com.google.iam.v1B\013P" + - "olicyProtoP\001Z0google.golang.org/genproto" + - "/googleapis/iam/v1;iam\370\001\001\252\002\023Google.Cloud" + - ".Iam.V1\312\002\023Google\\Cloud\\Iam\\V1b\006proto3" + java.lang.String[] descriptorData = { + "\n\032google/iam/v1/policy.proto\022\rgoogle.iam" + + ".v1\032\026google/type/expr.proto\032\034google/api/" + + "annotations.proto\"Q\n\006Policy\022\017\n\007version\030\001" + + " \001(\005\022(\n\010bindings\030\004 \003(\0132\026.google.iam.v1.B" + + "inding\022\014\n\004etag\030\003 \001(\014\"N\n\007Binding\022\014\n\004role\030" + + "\001 \001(\t\022\017\n\007members\030\002 \003(\t\022$\n\tcondition\030\003 \001(" + + "\0132\021.google.type.Expr\"\200\001\n\013PolicyDelta\0223\n\016" + + "binding_deltas\030\001 \003(\0132\033.google.iam.v1.Bin" + + "dingDelta\022<\n\023audit_config_deltas\030\002 \003(\0132\037" + + ".google.iam.v1.AuditConfigDelta\"\275\001\n\014Bind" + + "ingDelta\0222\n\006action\030\001 \001(\0162\".google.iam.v1" + + ".BindingDelta.Action\022\014\n\004role\030\002 \001(\t\022\016\n\006me" + + "mber\030\003 \001(\t\022$\n\tcondition\030\004 \001(\0132\021.google.t" + + "ype.Expr\"5\n\006Action\022\026\n\022ACTION_UNSPECIFIED" + + "\020\000\022\007\n\003ADD\020\001\022\n\n\006REMOVE\020\002\"\275\001\n\020AuditConfigD" + + "elta\0226\n\006action\030\001 \001(\0162&.google.iam.v1.Aud" + + "itConfigDelta.Action\022\017\n\007service\030\002 \001(\t\022\027\n" + + "\017exempted_member\030\003 \001(\t\022\020\n\010log_type\030\004 \001(\t" + + "\"5\n\006Action\022\026\n\022ACTION_UNSPECIFIED\020\000\022\007\n\003AD" + + "D\020\001\022\n\n\006REMOVE\020\002B\203\001\n\021com.google.iam.v1B\013P" + + "olicyProtoP\001Z0google.golang.org/genproto" + + "/googleapis/iam/v1;iam\370\001\001\252\002\023Google.Cloud" + + ".Iam.V1\312\002\023Google\\Cloud\\Iam\\V1b\006proto3" }; - com.google.protobuf.Descriptors.FileDescriptor.InternalDescriptorAssigner assigner = - new com.google.protobuf.Descriptors.FileDescriptor. InternalDescriptorAssigner() { - public com.google.protobuf.ExtensionRegistry assignDescriptors( - com.google.protobuf.Descriptors.FileDescriptor root) { - descriptor = root; - return null; - } - }; - com.google.protobuf.Descriptors.FileDescriptor - .internalBuildGeneratedFileFrom(descriptorData, - new com.google.protobuf.Descriptors.FileDescriptor[] { - com.google.type.ExprProto.getDescriptor(), - com.google.api.AnnotationsProto.getDescriptor(), - }, assigner); - internal_static_google_iam_v1_Policy_descriptor = - getDescriptor().getMessageTypes().get(0); - internal_static_google_iam_v1_Policy_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_iam_v1_Policy_descriptor, - new String[] { "Version", "Bindings", "Etag", }); - internal_static_google_iam_v1_Binding_descriptor = - getDescriptor().getMessageTypes().get(1); - internal_static_google_iam_v1_Binding_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_iam_v1_Binding_descriptor, - new String[] { "Role", "Members", "Condition", }); - internal_static_google_iam_v1_PolicyDelta_descriptor = - getDescriptor().getMessageTypes().get(2); - internal_static_google_iam_v1_PolicyDelta_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_iam_v1_PolicyDelta_descriptor, - new String[] { "BindingDeltas", "AuditConfigDeltas", }); + descriptor = + com.google.protobuf.Descriptors.FileDescriptor.internalBuildGeneratedFileFrom( + descriptorData, + new com.google.protobuf.Descriptors.FileDescriptor[] { + com.google.type.ExprProto.getDescriptor(), + com.google.api.AnnotationsProto.getDescriptor(), + }); + internal_static_google_iam_v1_Policy_descriptor = getDescriptor().getMessageTypes().get(0); + internal_static_google_iam_v1_Policy_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_iam_v1_Policy_descriptor, + new java.lang.String[] { + "Version", "Bindings", "Etag", + }); + internal_static_google_iam_v1_Binding_descriptor = getDescriptor().getMessageTypes().get(1); + internal_static_google_iam_v1_Binding_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_iam_v1_Binding_descriptor, + new java.lang.String[] { + "Role", "Members", "Condition", + }); + internal_static_google_iam_v1_PolicyDelta_descriptor = getDescriptor().getMessageTypes().get(2); + internal_static_google_iam_v1_PolicyDelta_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_iam_v1_PolicyDelta_descriptor, + new java.lang.String[] { + "BindingDeltas", "AuditConfigDeltas", + }); internal_static_google_iam_v1_BindingDelta_descriptor = - getDescriptor().getMessageTypes().get(3); - internal_static_google_iam_v1_BindingDelta_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_iam_v1_BindingDelta_descriptor, - new String[] { "Action", "Role", "Member", "Condition", }); + getDescriptor().getMessageTypes().get(3); + internal_static_google_iam_v1_BindingDelta_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_iam_v1_BindingDelta_descriptor, + new java.lang.String[] { + "Action", "Role", "Member", "Condition", + }); internal_static_google_iam_v1_AuditConfigDelta_descriptor = - getDescriptor().getMessageTypes().get(4); - internal_static_google_iam_v1_AuditConfigDelta_fieldAccessorTable = new - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( - internal_static_google_iam_v1_AuditConfigDelta_descriptor, - new String[] { "Action", "Service", "ExemptedMember", "LogType", }); + getDescriptor().getMessageTypes().get(4); + internal_static_google_iam_v1_AuditConfigDelta_fieldAccessorTable = + new com.google.protobuf.GeneratedMessageV3.FieldAccessorTable( + internal_static_google_iam_v1_AuditConfigDelta_descriptor, + new java.lang.String[] { + "Action", "Service", "ExemptedMember", "LogType", + }); com.google.type.ExprProto.getDescriptor(); com.google.api.AnnotationsProto.getDescriptor(); } diff --git a/proto-google-iam-v1/src/main/java/com/google/iam/v1/SetIamPolicyRequest.java b/proto-google-iam-v1/src/main/java/com/google/iam/v1/SetIamPolicyRequest.java index 98e5af3d..ead65341 100644 --- a/proto-google-iam-v1/src/main/java/com/google/iam/v1/SetIamPolicyRequest.java +++ b/proto-google-iam-v1/src/main/java/com/google/iam/v1/SetIamPolicyRequest.java @@ -1,42 +1,65 @@ +/* + * 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/iam/v1/iam_policy.proto package com.google.iam.v1; /** + * + * *
  * Request message for `SetIamPolicy` method.
  * 
* * Protobuf type {@code google.iam.v1.SetIamPolicyRequest} */ -public final class SetIamPolicyRequest extends - com.google.protobuf.GeneratedMessageV3 implements +public final class SetIamPolicyRequest extends com.google.protobuf.GeneratedMessageV3 + implements // @@protoc_insertion_point(message_implements:google.iam.v1.SetIamPolicyRequest) SetIamPolicyRequestOrBuilder { -private static final long serialVersionUID = 0L; + private static final long serialVersionUID = 0L; // Use SetIamPolicyRequest.newBuilder() to construct. private SetIamPolicyRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } + private SetIamPolicyRequest() { resource_ = ""; } - @Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new SetIamPolicyRequest(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } + private SetIamPolicyRequest( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { this(); if (extensionRegistry == null) { - throw new NullPointerException(); + throw new java.lang.NullPointerException(); } - int mutable_bitField0_ = 0; com.google.protobuf.UnknownFieldSet.Builder unknownFields = com.google.protobuf.UnknownFieldSet.newBuilder(); try { @@ -47,94 +70,107 @@ private SetIamPolicyRequest( case 0: done = true; break; - case 10: { - String s = input.readStringRequireUtf8(); + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); - resource_ = s; - break; - } - case 18: { - Policy.Builder subBuilder = null; - if (policy_ != null) { - subBuilder = policy_.toBuilder(); + resource_ = s; + break; } - policy_ = input.readMessage(Policy.parser(), extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(policy_); - policy_ = subBuilder.buildPartial(); + case 18: + { + com.google.iam.v1.Policy.Builder subBuilder = null; + if (policy_ != null) { + subBuilder = policy_.toBuilder(); + } + policy_ = input.readMessage(com.google.iam.v1.Policy.parser(), extensionRegistry); + if (subBuilder != null) { + subBuilder.mergeFrom(policy_); + policy_ = subBuilder.buildPartial(); + } + + break; } - - break; - } - default: { - if (!parseUnknownField( - input, unknownFields, extensionRegistry, tag)) { - done = true; + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; } - break; - } } } } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(this); } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException( - e).setUnfinishedMessage(this); + 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 IamPolicyProto.internal_static_google_iam_v1_SetIamPolicyRequest_descriptor; + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.iam.v1.IamPolicyProto + .internal_static_google_iam_v1_SetIamPolicyRequest_descriptor; } - @Override - protected FieldAccessorTable + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return IamPolicyProto.internal_static_google_iam_v1_SetIamPolicyRequest_fieldAccessorTable + return com.google.iam.v1.IamPolicyProto + .internal_static_google_iam_v1_SetIamPolicyRequest_fieldAccessorTable .ensureFieldAccessorsInitialized( - SetIamPolicyRequest.class, Builder.class); + com.google.iam.v1.SetIamPolicyRequest.class, + com.google.iam.v1.SetIamPolicyRequest.Builder.class); } public static final int RESOURCE_FIELD_NUMBER = 1; - private volatile Object resource_; + private volatile java.lang.Object resource_; /** + * + * *
    * REQUIRED: The resource for which the policy is being specified.
    * See the operation documentation for the appropriate value for this field.
    * 
* - * string resource = 1; + * + * string resource = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The resource. */ - public String getResource() { - Object ref = resource_; - if (ref instanceof String) { - return (String) ref; + public java.lang.String getResource() { + java.lang.Object ref = resource_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - String s = bs.toStringUtf8(); + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); resource_ = s; return s; } } /** + * + * *
    * REQUIRED: The resource for which the policy is being specified.
    * See the operation documentation for the appropriate value for this field.
    * 
* - * string resource = 1; + * + * string resource = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for resource. */ - public com.google.protobuf.ByteString - getResourceBytes() { - Object ref = resource_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (String) ref); + public com.google.protobuf.ByteString getResourceBytes() { + java.lang.Object ref = resource_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); resource_ = b; return b; } else { @@ -143,8 +179,10 @@ public String getResource() { } public static final int POLICY_FIELD_NUMBER = 2; - private Policy policy_; + private com.google.iam.v1.Policy policy_; /** + * + * *
    * REQUIRED: The complete policy to be applied to the `resource`. The size of
    * the policy is limited to a few 10s of KB. An empty policy is a
@@ -152,12 +190,16 @@ public String getResource() {
    * might reject them.
    * 
* - * .google.iam.v1.Policy policy = 2; + * .google.iam.v1.Policy policy = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return Whether the policy field is set. */ public boolean hasPolicy() { return policy_ != null; } /** + * + * *
    * REQUIRED: The complete policy to be applied to the `resource`. The size of
    * the policy is limited to a few 10s of KB. An empty policy is a
@@ -165,12 +207,16 @@ public boolean hasPolicy() {
    * might reject them.
    * 
* - * .google.iam.v1.Policy policy = 2; + * .google.iam.v1.Policy policy = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The policy. */ - public Policy getPolicy() { - return policy_ == null ? Policy.getDefaultInstance() : policy_; + public com.google.iam.v1.Policy getPolicy() { + return policy_ == null ? com.google.iam.v1.Policy.getDefaultInstance() : policy_; } /** + * + * *
    * REQUIRED: The complete policy to be applied to the `resource`. The size of
    * the policy is limited to a few 10s of KB. An empty policy is a
@@ -178,14 +224,15 @@ public Policy getPolicy() {
    * might reject them.
    * 
* - * .google.iam.v1.Policy policy = 2; + * .google.iam.v1.Policy policy = 2 [(.google.api.field_behavior) = REQUIRED]; */ - public PolicyOrBuilder getPolicyOrBuilder() { + public com.google.iam.v1.PolicyOrBuilder getPolicyOrBuilder() { return getPolicy(); } private byte memoizedIsInitialized = -1; - @Override + + @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; if (isInitialized == 1) return true; @@ -195,9 +242,8 @@ public final boolean isInitialized() { return true; } - @Override - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (!getResourceBytes().isEmpty()) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, resource_); } @@ -207,7 +253,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) unknownFields.writeTo(output); } - @Override + @java.lang.Override public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; @@ -217,36 +263,33 @@ public int getSerializedSize() { size += com.google.protobuf.GeneratedMessageV3.computeStringSize(1, resource_); } if (policy_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(2, getPolicy()); + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getPolicy()); } size += unknownFields.getSerializedSize(); memoizedSize = size; return size; } - @Override - public boolean equals(final Object obj) { + @java.lang.Override + public boolean equals(final java.lang.Object obj) { if (obj == this) { - return true; + return true; } - if (!(obj instanceof SetIamPolicyRequest)) { + if (!(obj instanceof com.google.iam.v1.SetIamPolicyRequest)) { return super.equals(obj); } - SetIamPolicyRequest other = (SetIamPolicyRequest) obj; + com.google.iam.v1.SetIamPolicyRequest other = (com.google.iam.v1.SetIamPolicyRequest) obj; - if (!getResource() - .equals(other.getResource())) return false; + if (!getResource().equals(other.getResource())) return false; if (hasPolicy() != other.hasPolicy()) return false; if (hasPolicy()) { - if (!getPolicy() - .equals(other.getPolicy())) return false; + if (!getPolicy().equals(other.getPolicy())) return false; } if (!unknownFields.equals(other.unknownFields)) return false; return true; } - @Override + @java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; @@ -264,118 +307,126 @@ public int hashCode() { return hash; } - public static SetIamPolicyRequest parseFrom( - java.nio.ByteBuffer data) + public static com.google.iam.v1.SetIamPolicyRequest parseFrom(java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } - public static SetIamPolicyRequest parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + + public static com.google.iam.v1.SetIamPolicyRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static SetIamPolicyRequest parseFrom( - com.google.protobuf.ByteString data) + + public static com.google.iam.v1.SetIamPolicyRequest parseFrom(com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } - public static SetIamPolicyRequest parseFrom( + + public static com.google.iam.v1.SetIamPolicyRequest parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static SetIamPolicyRequest parseFrom(byte[] data) + + public static com.google.iam.v1.SetIamPolicyRequest parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } - public static SetIamPolicyRequest parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + + public static com.google.iam.v1.SetIamPolicyRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static SetIamPolicyRequest parseFrom(java.io.InputStream input) + + public static com.google.iam.v1.SetIamPolicyRequest parseFrom(java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } - public static SetIamPolicyRequest parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + + public static com.google.iam.v1.SetIamPolicyRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } - public static SetIamPolicyRequest parseDelimitedFrom(java.io.InputStream input) + + public static com.google.iam.v1.SetIamPolicyRequest parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } - public static SetIamPolicyRequest parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + + public static com.google.iam.v1.SetIamPolicyRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); } - public static SetIamPolicyRequest parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + + public static com.google.iam.v1.SetIamPolicyRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } - public static SetIamPolicyRequest parseFrom( + + public static com.google.iam.v1.SetIamPolicyRequest parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); } - @Override - public Builder newBuilderForType() { return newBuilder(); } public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } - public static Builder newBuilder(SetIamPolicyRequest prototype) { + + public static Builder newBuilder(com.google.iam.v1.SetIamPolicyRequest prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } - @Override + + @java.lang.Override public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } - @Override - protected Builder newBuilderForType( - BuilderParent parent) { + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** + * + * *
    * Request message for `SetIamPolicy` method.
    * 
* * Protobuf type {@code google.iam.v1.SetIamPolicyRequest} */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements // @@protoc_insertion_point(builder_implements:google.iam.v1.SetIamPolicyRequest) com.google.iam.v1.SetIamPolicyRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return IamPolicyProto.internal_static_google_iam_v1_SetIamPolicyRequest_descriptor; + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.iam.v1.IamPolicyProto + .internal_static_google_iam_v1_SetIamPolicyRequest_descriptor; } - @Override - protected FieldAccessorTable + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return IamPolicyProto.internal_static_google_iam_v1_SetIamPolicyRequest_fieldAccessorTable + return com.google.iam.v1.IamPolicyProto + .internal_static_google_iam_v1_SetIamPolicyRequest_fieldAccessorTable .ensureFieldAccessorsInitialized( - SetIamPolicyRequest.class, Builder.class); + com.google.iam.v1.SetIamPolicyRequest.class, + com.google.iam.v1.SetIamPolicyRequest.Builder.class); } // Construct using com.google.iam.v1.SetIamPolicyRequest.newBuilder() @@ -383,17 +434,16 @@ private Builder() { maybeForceBuilderInitialization(); } - private Builder( - BuilderParent parent) { + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); maybeForceBuilderInitialization(); } + private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } - @Override + + @java.lang.Override public Builder clear() { super.clear(); resource_ = ""; @@ -407,29 +457,30 @@ public Builder clear() { return this; } - @Override - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return IamPolicyProto.internal_static_google_iam_v1_SetIamPolicyRequest_descriptor; + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.iam.v1.IamPolicyProto + .internal_static_google_iam_v1_SetIamPolicyRequest_descriptor; } - @Override - public SetIamPolicyRequest getDefaultInstanceForType() { - return SetIamPolicyRequest.getDefaultInstance(); + @java.lang.Override + public com.google.iam.v1.SetIamPolicyRequest getDefaultInstanceForType() { + return com.google.iam.v1.SetIamPolicyRequest.getDefaultInstance(); } - @Override - public SetIamPolicyRequest build() { - SetIamPolicyRequest result = buildPartial(); + @java.lang.Override + public com.google.iam.v1.SetIamPolicyRequest build() { + com.google.iam.v1.SetIamPolicyRequest result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } - @Override - public SetIamPolicyRequest buildPartial() { - SetIamPolicyRequest result = new SetIamPolicyRequest(this); + @java.lang.Override + public com.google.iam.v1.SetIamPolicyRequest buildPartial() { + com.google.iam.v1.SetIamPolicyRequest result = + new com.google.iam.v1.SetIamPolicyRequest(this); result.resource_ = resource_; if (policyBuilder_ == null) { result.policy_ = policy_; @@ -440,50 +491,51 @@ public SetIamPolicyRequest buildPartial() { return result; } - @Override + @java.lang.Override public Builder clone() { return super.clone(); } - @Override + + @java.lang.Override public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } - @Override - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } - @Override - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } - @Override + + @java.lang.Override public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } - @Override + + @java.lang.Override public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } - @Override + + @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof SetIamPolicyRequest) { - return mergeFrom((SetIamPolicyRequest)other); + if (other instanceof com.google.iam.v1.SetIamPolicyRequest) { + return mergeFrom((com.google.iam.v1.SetIamPolicyRequest) other); } else { super.mergeFrom(other); return this; } } - public Builder mergeFrom(SetIamPolicyRequest other) { - if (other == SetIamPolicyRequest.getDefaultInstance()) return this; + public Builder mergeFrom(com.google.iam.v1.SetIamPolicyRequest other) { + if (other == com.google.iam.v1.SetIamPolicyRequest.getDefaultInstance()) return this; if (!other.getResource().isEmpty()) { resource_ = other.resource_; onChanged(); @@ -496,21 +548,21 @@ public Builder mergeFrom(SetIamPolicyRequest other) { return this; } - @Override + @java.lang.Override public final boolean isInitialized() { return true; } - @Override + @java.lang.Override public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - SetIamPolicyRequest parsedMessage = null; + com.google.iam.v1.SetIamPolicyRequest parsedMessage = null; try { parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (SetIamPolicyRequest) e.getUnfinishedMessage(); + parsedMessage = (com.google.iam.v1.SetIamPolicyRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { if (parsedMessage != null) { @@ -520,42 +572,51 @@ public Builder mergeFrom( return this; } - private Object resource_ = ""; + private java.lang.Object resource_ = ""; /** + * + * *
      * REQUIRED: The resource for which the policy is being specified.
      * See the operation documentation for the appropriate value for this field.
      * 
* - * string resource = 1; + * + * string resource = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The resource. */ - public String getResource() { - Object ref = resource_; - if (!(ref instanceof String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - String s = bs.toStringUtf8(); + public java.lang.String getResource() { + java.lang.Object ref = resource_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); resource_ = s; return s; } else { - return (String) ref; + return (java.lang.String) ref; } } /** + * + * *
      * REQUIRED: The resource for which the policy is being specified.
      * See the operation documentation for the appropriate value for this field.
      * 
* - * string resource = 1; + * + * string resource = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for resource. */ - public com.google.protobuf.ByteString - getResourceBytes() { - Object ref = resource_; + public com.google.protobuf.ByteString getResourceBytes() { + java.lang.Object ref = resource_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); resource_ = b; return b; } else { @@ -563,61 +624,84 @@ public String getResource() { } } /** + * + * *
      * REQUIRED: The resource for which the policy is being specified.
      * See the operation documentation for the appropriate value for this field.
      * 
* - * string resource = 1; + * + * string resource = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The resource to set. + * @return This builder for chaining. */ - public Builder setResource( - String value) { + public Builder setResource(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + resource_ = value; onChanged(); return this; } /** + * + * *
      * REQUIRED: The resource for which the policy is being specified.
      * See the operation documentation for the appropriate value for this field.
      * 
* - * string resource = 1; + * + * string resource = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. */ public Builder clearResource() { - + resource_ = getDefaultInstance().getResource(); onChanged(); return this; } /** + * + * *
      * REQUIRED: The resource for which the policy is being specified.
      * See the operation documentation for the appropriate value for this field.
      * 
* - * string resource = 1; + * + * string resource = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for resource to set. + * @return This builder for chaining. */ - public Builder setResourceBytes( - com.google.protobuf.ByteString value) { + public Builder setResourceBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + resource_ = value; onChanged(); return this; } - private Policy policy_; + private com.google.iam.v1.Policy policy_; private com.google.protobuf.SingleFieldBuilderV3< - Policy, Policy.Builder, PolicyOrBuilder> policyBuilder_; + com.google.iam.v1.Policy, + com.google.iam.v1.Policy.Builder, + com.google.iam.v1.PolicyOrBuilder> + policyBuilder_; /** + * + * *
      * REQUIRED: The complete policy to be applied to the `resource`. The size of
      * the policy is limited to a few 10s of KB. An empty policy is a
@@ -625,12 +709,16 @@ public Builder setResourceBytes(
      * might reject them.
      * 
* - * .google.iam.v1.Policy policy = 2; + * .google.iam.v1.Policy policy = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return Whether the policy field is set. */ public boolean hasPolicy() { return policyBuilder_ != null || policy_ != null; } /** + * + * *
      * REQUIRED: The complete policy to be applied to the `resource`. The size of
      * the policy is limited to a few 10s of KB. An empty policy is a
@@ -638,16 +726,20 @@ public boolean hasPolicy() {
      * might reject them.
      * 
* - * .google.iam.v1.Policy policy = 2; + * .google.iam.v1.Policy policy = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The policy. */ - public Policy getPolicy() { + public com.google.iam.v1.Policy getPolicy() { if (policyBuilder_ == null) { - return policy_ == null ? Policy.getDefaultInstance() : policy_; + return policy_ == null ? com.google.iam.v1.Policy.getDefaultInstance() : policy_; } else { return policyBuilder_.getMessage(); } } /** + * + * *
      * REQUIRED: The complete policy to be applied to the `resource`. The size of
      * the policy is limited to a few 10s of KB. An empty policy is a
@@ -655,9 +747,9 @@ public Policy getPolicy() {
      * might reject them.
      * 
* - * .google.iam.v1.Policy policy = 2; + * .google.iam.v1.Policy policy = 2 [(.google.api.field_behavior) = REQUIRED]; */ - public Builder setPolicy(Policy value) { + public Builder setPolicy(com.google.iam.v1.Policy value) { if (policyBuilder_ == null) { if (value == null) { throw new NullPointerException(); @@ -671,6 +763,8 @@ public Builder setPolicy(Policy value) { return this; } /** + * + * *
      * REQUIRED: The complete policy to be applied to the `resource`. The size of
      * the policy is limited to a few 10s of KB. An empty policy is a
@@ -678,10 +772,9 @@ public Builder setPolicy(Policy value) {
      * might reject them.
      * 
* - * .google.iam.v1.Policy policy = 2; + * .google.iam.v1.Policy policy = 2 [(.google.api.field_behavior) = REQUIRED]; */ - public Builder setPolicy( - Policy.Builder builderForValue) { + public Builder setPolicy(com.google.iam.v1.Policy.Builder builderForValue) { if (policyBuilder_ == null) { policy_ = builderForValue.build(); onChanged(); @@ -692,6 +785,8 @@ public Builder setPolicy( return this; } /** + * + * *
      * REQUIRED: The complete policy to be applied to the `resource`. The size of
      * the policy is limited to a few 10s of KB. An empty policy is a
@@ -699,13 +794,12 @@ public Builder setPolicy(
      * might reject them.
      * 
* - * .google.iam.v1.Policy policy = 2; + * .google.iam.v1.Policy policy = 2 [(.google.api.field_behavior) = REQUIRED]; */ - public Builder mergePolicy(Policy value) { + public Builder mergePolicy(com.google.iam.v1.Policy value) { if (policyBuilder_ == null) { if (policy_ != null) { - policy_ = - Policy.newBuilder(policy_).mergeFrom(value).buildPartial(); + policy_ = com.google.iam.v1.Policy.newBuilder(policy_).mergeFrom(value).buildPartial(); } else { policy_ = value; } @@ -717,6 +811,8 @@ public Builder mergePolicy(Policy value) { return this; } /** + * + * *
      * REQUIRED: The complete policy to be applied to the `resource`. The size of
      * the policy is limited to a few 10s of KB. An empty policy is a
@@ -724,7 +820,7 @@ public Builder mergePolicy(Policy value) {
      * might reject them.
      * 
* - * .google.iam.v1.Policy policy = 2; + * .google.iam.v1.Policy policy = 2 [(.google.api.field_behavior) = REQUIRED]; */ public Builder clearPolicy() { if (policyBuilder_ == null) { @@ -738,6 +834,8 @@ public Builder clearPolicy() { return this; } /** + * + * *
      * REQUIRED: The complete policy to be applied to the `resource`. The size of
      * the policy is limited to a few 10s of KB. An empty policy is a
@@ -745,14 +843,16 @@ public Builder clearPolicy() {
      * might reject them.
      * 
* - * .google.iam.v1.Policy policy = 2; + * .google.iam.v1.Policy policy = 2 [(.google.api.field_behavior) = REQUIRED]; */ - public Policy.Builder getPolicyBuilder() { - + public com.google.iam.v1.Policy.Builder getPolicyBuilder() { + onChanged(); return getPolicyFieldBuilder().getBuilder(); } /** + * + * *
      * REQUIRED: The complete policy to be applied to the `resource`. The size of
      * the policy is limited to a few 10s of KB. An empty policy is a
@@ -760,17 +860,18 @@ public Policy.Builder getPolicyBuilder() {
      * might reject them.
      * 
* - * .google.iam.v1.Policy policy = 2; + * .google.iam.v1.Policy policy = 2 [(.google.api.field_behavior) = REQUIRED]; */ - public PolicyOrBuilder getPolicyOrBuilder() { + public com.google.iam.v1.PolicyOrBuilder getPolicyOrBuilder() { if (policyBuilder_ != null) { return policyBuilder_.getMessageOrBuilder(); } else { - return policy_ == null ? - Policy.getDefaultInstance() : policy_; + return policy_ == null ? com.google.iam.v1.Policy.getDefaultInstance() : policy_; } } /** + * + * *
      * REQUIRED: The complete policy to be applied to the `resource`. The size of
      * the policy is limited to a few 10s of KB. An empty policy is a
@@ -778,71 +879,71 @@ public PolicyOrBuilder getPolicyOrBuilder() {
      * might reject them.
      * 
* - * .google.iam.v1.Policy policy = 2; + * .google.iam.v1.Policy policy = 2 [(.google.api.field_behavior) = REQUIRED]; */ private com.google.protobuf.SingleFieldBuilderV3< - Policy, Policy.Builder, PolicyOrBuilder> + com.google.iam.v1.Policy, + com.google.iam.v1.Policy.Builder, + com.google.iam.v1.PolicyOrBuilder> getPolicyFieldBuilder() { if (policyBuilder_ == null) { - policyBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - Policy, Policy.Builder, PolicyOrBuilder>( - getPolicy(), - getParentForChildren(), - isClean()); + policyBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.iam.v1.Policy, + com.google.iam.v1.Policy.Builder, + com.google.iam.v1.PolicyOrBuilder>(getPolicy(), getParentForChildren(), isClean()); policy_ = null; } return policyBuilder_; } - @Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } - @Override + @java.lang.Override public final Builder mergeUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return super.mergeUnknownFields(unknownFields); } - // @@protoc_insertion_point(builder_scope:google.iam.v1.SetIamPolicyRequest) } // @@protoc_insertion_point(class_scope:google.iam.v1.SetIamPolicyRequest) - private static final SetIamPolicyRequest DEFAULT_INSTANCE; + private static final com.google.iam.v1.SetIamPolicyRequest DEFAULT_INSTANCE; + static { - DEFAULT_INSTANCE = new SetIamPolicyRequest(); + DEFAULT_INSTANCE = new com.google.iam.v1.SetIamPolicyRequest(); } - public static SetIamPolicyRequest getDefaultInstance() { + public static com.google.iam.v1.SetIamPolicyRequest getDefaultInstance() { return DEFAULT_INSTANCE; } - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - @Override - public SetIamPolicyRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new SetIamPolicyRequest(input, extensionRegistry); - } - }; + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public SetIamPolicyRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new SetIamPolicyRequest(input, extensionRegistry); + } + }; public static com.google.protobuf.Parser parser() { return PARSER; } - @Override + @java.lang.Override public com.google.protobuf.Parser getParserForType() { return PARSER; } - @Override - public SetIamPolicyRequest getDefaultInstanceForType() { + @java.lang.Override + public com.google.iam.v1.SetIamPolicyRequest getDefaultInstanceForType() { return DEFAULT_INSTANCE; } - } - diff --git a/proto-google-iam-v1/src/main/java/com/google/iam/v1/SetIamPolicyRequestOrBuilder.java b/proto-google-iam-v1/src/main/java/com/google/iam/v1/SetIamPolicyRequestOrBuilder.java index e0e2e888..135cf6dc 100644 --- a/proto-google-iam-v1/src/main/java/com/google/iam/v1/SetIamPolicyRequestOrBuilder.java +++ b/proto-google-iam-v1/src/main/java/com/google/iam/v1/SetIamPolicyRequestOrBuilder.java @@ -1,33 +1,62 @@ +/* + * 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/iam/v1/iam_policy.proto package com.google.iam.v1; -public interface SetIamPolicyRequestOrBuilder extends +public interface SetIamPolicyRequestOrBuilder + extends // @@protoc_insertion_point(interface_extends:google.iam.v1.SetIamPolicyRequest) com.google.protobuf.MessageOrBuilder { /** + * + * *
    * REQUIRED: The resource for which the policy is being specified.
    * See the operation documentation for the appropriate value for this field.
    * 
* - * string resource = 1; + * + * string resource = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The resource. */ - String getResource(); + java.lang.String getResource(); /** + * + * *
    * REQUIRED: The resource for which the policy is being specified.
    * See the operation documentation for the appropriate value for this field.
    * 
* - * string resource = 1; + * + * string resource = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for resource. */ - com.google.protobuf.ByteString - getResourceBytes(); + com.google.protobuf.ByteString getResourceBytes(); /** + * + * *
    * REQUIRED: The complete policy to be applied to the `resource`. The size of
    * the policy is limited to a few 10s of KB. An empty policy is a
@@ -35,10 +64,14 @@ public interface SetIamPolicyRequestOrBuilder extends
    * might reject them.
    * 
* - * .google.iam.v1.Policy policy = 2; + * .google.iam.v1.Policy policy = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return Whether the policy field is set. */ boolean hasPolicy(); /** + * + * *
    * REQUIRED: The complete policy to be applied to the `resource`. The size of
    * the policy is limited to a few 10s of KB. An empty policy is a
@@ -46,10 +79,14 @@ public interface SetIamPolicyRequestOrBuilder extends
    * might reject them.
    * 
* - * .google.iam.v1.Policy policy = 2; + * .google.iam.v1.Policy policy = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The policy. */ - Policy getPolicy(); + com.google.iam.v1.Policy getPolicy(); /** + * + * *
    * REQUIRED: The complete policy to be applied to the `resource`. The size of
    * the policy is limited to a few 10s of KB. An empty policy is a
@@ -57,7 +94,7 @@ public interface SetIamPolicyRequestOrBuilder extends
    * might reject them.
    * 
* - * .google.iam.v1.Policy policy = 2; + * .google.iam.v1.Policy policy = 2 [(.google.api.field_behavior) = REQUIRED]; */ - PolicyOrBuilder getPolicyOrBuilder(); + com.google.iam.v1.PolicyOrBuilder getPolicyOrBuilder(); } diff --git a/proto-google-iam-v1/src/main/java/com/google/iam/v1/TestIamPermissionsRequest.java b/proto-google-iam-v1/src/main/java/com/google/iam/v1/TestIamPermissionsRequest.java index 95a56fcb..784d2beb 100644 --- a/proto-google-iam-v1/src/main/java/com/google/iam/v1/TestIamPermissionsRequest.java +++ b/proto-google-iam-v1/src/main/java/com/google/iam/v1/TestIamPermissionsRequest.java @@ -1,41 +1,65 @@ +/* + * 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/iam/v1/iam_policy.proto package com.google.iam.v1; /** + * + * *
  * Request message for `TestIamPermissions` method.
  * 
* * Protobuf type {@code google.iam.v1.TestIamPermissionsRequest} */ -public final class TestIamPermissionsRequest extends - com.google.protobuf.GeneratedMessageV3 implements +public final class TestIamPermissionsRequest extends com.google.protobuf.GeneratedMessageV3 + implements // @@protoc_insertion_point(message_implements:google.iam.v1.TestIamPermissionsRequest) TestIamPermissionsRequestOrBuilder { -private static final long serialVersionUID = 0L; + private static final long serialVersionUID = 0L; // Use TestIamPermissionsRequest.newBuilder() to construct. private TestIamPermissionsRequest(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } + private TestIamPermissionsRequest() { resource_ = ""; permissions_ = com.google.protobuf.LazyStringArrayList.EMPTY; } - @Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new TestIamPermissionsRequest(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } + private TestIamPermissionsRequest( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { this(); if (extensionRegistry == null) { - throw new NullPointerException(); + throw new java.lang.NullPointerException(); } int mutable_bitField0_ = 0; com.google.protobuf.UnknownFieldSet.Builder unknownFields = @@ -48,94 +72,106 @@ private TestIamPermissionsRequest( case 0: done = true; break; - case 10: { - String s = input.readStringRequireUtf8(); + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); - resource_ = s; - break; - } - case 18: { - String s = input.readStringRequireUtf8(); - if (!((mutable_bitField0_ & 0x00000002) != 0)) { - permissions_ = new com.google.protobuf.LazyStringArrayList(); - mutable_bitField0_ |= 0x00000002; + resource_ = s; + break; } - permissions_.add(s); - break; - } - default: { - if (!parseUnknownField( - input, unknownFields, extensionRegistry, tag)) { - done = true; + case 18: + { + java.lang.String s = input.readStringRequireUtf8(); + if (!((mutable_bitField0_ & 0x00000001) != 0)) { + permissions_ = new com.google.protobuf.LazyStringArrayList(); + mutable_bitField0_ |= 0x00000001; + } + permissions_.add(s); + break; + } + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; } - break; - } } } } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(this); } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException( - e).setUnfinishedMessage(this); + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); } finally { - if (((mutable_bitField0_ & 0x00000002) != 0)) { + if (((mutable_bitField0_ & 0x00000001) != 0)) { permissions_ = permissions_.getUnmodifiableView(); } this.unknownFields = unknownFields.build(); makeExtensionsImmutable(); } } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return IamPolicyProto.internal_static_google_iam_v1_TestIamPermissionsRequest_descriptor; + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.iam.v1.IamPolicyProto + .internal_static_google_iam_v1_TestIamPermissionsRequest_descriptor; } - @Override - protected FieldAccessorTable + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return IamPolicyProto.internal_static_google_iam_v1_TestIamPermissionsRequest_fieldAccessorTable + return com.google.iam.v1.IamPolicyProto + .internal_static_google_iam_v1_TestIamPermissionsRequest_fieldAccessorTable .ensureFieldAccessorsInitialized( - TestIamPermissionsRequest.class, Builder.class); + com.google.iam.v1.TestIamPermissionsRequest.class, + com.google.iam.v1.TestIamPermissionsRequest.Builder.class); } - private int bitField0_; public static final int RESOURCE_FIELD_NUMBER = 1; - private volatile Object resource_; + private volatile java.lang.Object resource_; /** + * + * *
    * REQUIRED: The resource for which the policy detail is being requested.
    * See the operation documentation for the appropriate value for this field.
    * 
* - * string resource = 1; + * + * string resource = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The resource. */ - public String getResource() { - Object ref = resource_; - if (ref instanceof String) { - return (String) ref; + public java.lang.String getResource() { + java.lang.Object ref = resource_; + if (ref instanceof java.lang.String) { + return (java.lang.String) ref; } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - String s = bs.toStringUtf8(); + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); resource_ = s; return s; } } /** + * + * *
    * REQUIRED: The resource for which the policy detail is being requested.
    * See the operation documentation for the appropriate value for this field.
    * 
* - * string resource = 1; + * + * string resource = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for resource. */ - public com.google.protobuf.ByteString - getResourceBytes() { - Object ref = resource_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (String) ref); + public com.google.protobuf.ByteString getResourceBytes() { + java.lang.Object ref = resource_; + if (ref instanceof java.lang.String) { + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); resource_ = b; return b; } else { @@ -146,6 +182,8 @@ public String getResource() { public static final int PERMISSIONS_FIELD_NUMBER = 2; private com.google.protobuf.LazyStringList permissions_; /** + * + * *
    * The set of permissions to check for the `resource`. Permissions with
    * wildcards (such as '*' or 'storage.*') are not allowed. For more
@@ -153,13 +191,16 @@ public String getResource() {
    * [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions).
    * 
* - * repeated string permissions = 2; + * repeated string permissions = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return A list containing the permissions. */ - public com.google.protobuf.ProtocolStringList - getPermissionsList() { + public com.google.protobuf.ProtocolStringList getPermissionsList() { return permissions_; } /** + * + * *
    * The set of permissions to check for the `resource`. Permissions with
    * wildcards (such as '*' or 'storage.*') are not allowed. For more
@@ -167,12 +208,16 @@ public String getResource() {
    * [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions).
    * 
* - * repeated string permissions = 2; + * repeated string permissions = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The count of permissions. */ public int getPermissionsCount() { return permissions_.size(); } /** + * + * *
    * The set of permissions to check for the `resource`. Permissions with
    * wildcards (such as '*' or 'storage.*') are not allowed. For more
@@ -180,12 +225,17 @@ public int getPermissionsCount() {
    * [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions).
    * 
* - * repeated string permissions = 2; + * repeated string permissions = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @param index The index of the element to return. + * @return The permissions at the given index. */ - public String getPermissions(int index) { + public java.lang.String getPermissions(int index) { return permissions_.get(index); } /** + * + * *
    * The set of permissions to check for the `resource`. Permissions with
    * wildcards (such as '*' or 'storage.*') are not allowed. For more
@@ -193,15 +243,18 @@ public String getPermissions(int index) {
    * [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions).
    * 
* - * repeated string permissions = 2; + * repeated string permissions = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @param index The index of the value to return. + * @return The bytes of the permissions at the given index. */ - public com.google.protobuf.ByteString - getPermissionsBytes(int index) { + public com.google.protobuf.ByteString getPermissionsBytes(int index) { return permissions_.getByteString(index); } private byte memoizedIsInitialized = -1; - @Override + + @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; if (isInitialized == 1) return true; @@ -211,9 +264,8 @@ public final boolean isInitialized() { return true; } - @Override - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (!getResourceBytes().isEmpty()) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, resource_); } @@ -223,7 +275,7 @@ public void writeTo(com.google.protobuf.CodedOutputStream output) unknownFields.writeTo(output); } - @Override + @java.lang.Override public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; @@ -245,25 +297,24 @@ public int getSerializedSize() { return size; } - @Override - public boolean equals(final Object obj) { + @java.lang.Override + public boolean equals(final java.lang.Object obj) { if (obj == this) { - return true; + return true; } - if (!(obj instanceof TestIamPermissionsRequest)) { + if (!(obj instanceof com.google.iam.v1.TestIamPermissionsRequest)) { return super.equals(obj); } - TestIamPermissionsRequest other = (TestIamPermissionsRequest) obj; + com.google.iam.v1.TestIamPermissionsRequest other = + (com.google.iam.v1.TestIamPermissionsRequest) obj; - if (!getResource() - .equals(other.getResource())) return false; - if (!getPermissionsList() - .equals(other.getPermissionsList())) return false; + if (!getResource().equals(other.getResource())) return false; + if (!getPermissionsList().equals(other.getPermissionsList())) return false; if (!unknownFields.equals(other.unknownFields)) return false; return true; } - @Override + @java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; @@ -281,118 +332,127 @@ public int hashCode() { return hash; } - public static TestIamPermissionsRequest parseFrom( - java.nio.ByteBuffer data) + public static com.google.iam.v1.TestIamPermissionsRequest parseFrom(java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } - public static TestIamPermissionsRequest parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + + public static com.google.iam.v1.TestIamPermissionsRequest parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static TestIamPermissionsRequest parseFrom( + + public static com.google.iam.v1.TestIamPermissionsRequest parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } - public static TestIamPermissionsRequest parseFrom( + + public static com.google.iam.v1.TestIamPermissionsRequest parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static TestIamPermissionsRequest parseFrom(byte[] data) + + public static com.google.iam.v1.TestIamPermissionsRequest parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } - public static TestIamPermissionsRequest parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + + public static com.google.iam.v1.TestIamPermissionsRequest parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static TestIamPermissionsRequest parseFrom(java.io.InputStream input) + + public static com.google.iam.v1.TestIamPermissionsRequest parseFrom(java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } - public static TestIamPermissionsRequest parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + + public static com.google.iam.v1.TestIamPermissionsRequest parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } - public static TestIamPermissionsRequest parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); + + public static com.google.iam.v1.TestIamPermissionsRequest parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } - public static TestIamPermissionsRequest parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + + public static com.google.iam.v1.TestIamPermissionsRequest parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); } - public static TestIamPermissionsRequest parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + + public static com.google.iam.v1.TestIamPermissionsRequest parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } - public static TestIamPermissionsRequest parseFrom( + + public static com.google.iam.v1.TestIamPermissionsRequest parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); } - @Override - public Builder newBuilderForType() { return newBuilder(); } public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } - public static Builder newBuilder(TestIamPermissionsRequest prototype) { + + public static Builder newBuilder(com.google.iam.v1.TestIamPermissionsRequest prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } - @Override + + @java.lang.Override public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } - @Override - protected Builder newBuilderForType( - BuilderParent parent) { + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** + * + * *
    * Request message for `TestIamPermissions` method.
    * 
* * Protobuf type {@code google.iam.v1.TestIamPermissionsRequest} */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements // @@protoc_insertion_point(builder_implements:google.iam.v1.TestIamPermissionsRequest) com.google.iam.v1.TestIamPermissionsRequestOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return IamPolicyProto.internal_static_google_iam_v1_TestIamPermissionsRequest_descriptor; + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.iam.v1.IamPolicyProto + .internal_static_google_iam_v1_TestIamPermissionsRequest_descriptor; } - @Override - protected FieldAccessorTable + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return IamPolicyProto.internal_static_google_iam_v1_TestIamPermissionsRequest_fieldAccessorTable + return com.google.iam.v1.IamPolicyProto + .internal_static_google_iam_v1_TestIamPermissionsRequest_fieldAccessorTable .ensureFieldAccessorsInitialized( - TestIamPermissionsRequest.class, Builder.class); + com.google.iam.v1.TestIamPermissionsRequest.class, + com.google.iam.v1.TestIamPermissionsRequest.Builder.class); } // Construct using com.google.iam.v1.TestIamPermissionsRequest.newBuilder() @@ -400,106 +460,105 @@ private Builder() { maybeForceBuilderInitialization(); } - private Builder( - BuilderParent parent) { + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); maybeForceBuilderInitialization(); } + private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } - @Override + + @java.lang.Override public Builder clear() { super.clear(); resource_ = ""; permissions_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000002); + bitField0_ = (bitField0_ & ~0x00000001); return this; } - @Override - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return IamPolicyProto.internal_static_google_iam_v1_TestIamPermissionsRequest_descriptor; + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.iam.v1.IamPolicyProto + .internal_static_google_iam_v1_TestIamPermissionsRequest_descriptor; } - @Override - public TestIamPermissionsRequest getDefaultInstanceForType() { - return TestIamPermissionsRequest.getDefaultInstance(); + @java.lang.Override + public com.google.iam.v1.TestIamPermissionsRequest getDefaultInstanceForType() { + return com.google.iam.v1.TestIamPermissionsRequest.getDefaultInstance(); } - @Override - public TestIamPermissionsRequest build() { - TestIamPermissionsRequest result = buildPartial(); + @java.lang.Override + public com.google.iam.v1.TestIamPermissionsRequest build() { + com.google.iam.v1.TestIamPermissionsRequest result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } - @Override - public TestIamPermissionsRequest buildPartial() { - TestIamPermissionsRequest result = new TestIamPermissionsRequest(this); + @java.lang.Override + public com.google.iam.v1.TestIamPermissionsRequest buildPartial() { + com.google.iam.v1.TestIamPermissionsRequest result = + new com.google.iam.v1.TestIamPermissionsRequest(this); int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; result.resource_ = resource_; - if (((bitField0_ & 0x00000002) != 0)) { + if (((bitField0_ & 0x00000001) != 0)) { permissions_ = permissions_.getUnmodifiableView(); - bitField0_ = (bitField0_ & ~0x00000002); + bitField0_ = (bitField0_ & ~0x00000001); } result.permissions_ = permissions_; - result.bitField0_ = to_bitField0_; onBuilt(); return result; } - @Override + @java.lang.Override public Builder clone() { return super.clone(); } - @Override + + @java.lang.Override public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } - @Override - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } - @Override - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } - @Override + + @java.lang.Override public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } - @Override + + @java.lang.Override public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } - @Override + + @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof TestIamPermissionsRequest) { - return mergeFrom((TestIamPermissionsRequest)other); + if (other instanceof com.google.iam.v1.TestIamPermissionsRequest) { + return mergeFrom((com.google.iam.v1.TestIamPermissionsRequest) other); } else { super.mergeFrom(other); return this; } } - public Builder mergeFrom(TestIamPermissionsRequest other) { - if (other == TestIamPermissionsRequest.getDefaultInstance()) return this; + public Builder mergeFrom(com.google.iam.v1.TestIamPermissionsRequest other) { + if (other == com.google.iam.v1.TestIamPermissionsRequest.getDefaultInstance()) return this; if (!other.getResource().isEmpty()) { resource_ = other.resource_; onChanged(); @@ -507,7 +566,7 @@ public Builder mergeFrom(TestIamPermissionsRequest other) { if (!other.permissions_.isEmpty()) { if (permissions_.isEmpty()) { permissions_ = other.permissions_; - bitField0_ = (bitField0_ & ~0x00000002); + bitField0_ = (bitField0_ & ~0x00000001); } else { ensurePermissionsIsMutable(); permissions_.addAll(other.permissions_); @@ -519,21 +578,21 @@ public Builder mergeFrom(TestIamPermissionsRequest other) { return this; } - @Override + @java.lang.Override public final boolean isInitialized() { return true; } - @Override + @java.lang.Override public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - TestIamPermissionsRequest parsedMessage = null; + com.google.iam.v1.TestIamPermissionsRequest parsedMessage = null; try { parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (TestIamPermissionsRequest) e.getUnfinishedMessage(); + parsedMessage = (com.google.iam.v1.TestIamPermissionsRequest) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { if (parsedMessage != null) { @@ -542,44 +601,54 @@ public Builder mergeFrom( } return this; } + private int bitField0_; - private Object resource_ = ""; + private java.lang.Object resource_ = ""; /** + * + * *
      * REQUIRED: The resource for which the policy detail is being requested.
      * See the operation documentation for the appropriate value for this field.
      * 
* - * string resource = 1; + * + * string resource = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The resource. */ - public String getResource() { - Object ref = resource_; - if (!(ref instanceof String)) { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - String s = bs.toStringUtf8(); + public java.lang.String getResource() { + java.lang.Object ref = resource_; + if (!(ref instanceof java.lang.String)) { + com.google.protobuf.ByteString bs = (com.google.protobuf.ByteString) ref; + java.lang.String s = bs.toStringUtf8(); resource_ = s; return s; } else { - return (String) ref; + return (java.lang.String) ref; } } /** + * + * *
      * REQUIRED: The resource for which the policy detail is being requested.
      * See the operation documentation for the appropriate value for this field.
      * 
* - * string resource = 1; + * + * string resource = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for resource. */ - public com.google.protobuf.ByteString - getResourceBytes() { - Object ref = resource_; + public com.google.protobuf.ByteString getResourceBytes() { + java.lang.Object ref = resource_; if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (String) ref); + com.google.protobuf.ByteString b = + com.google.protobuf.ByteString.copyFromUtf8((java.lang.String) ref); resource_ = b; return b; } else { @@ -587,65 +656,87 @@ public String getResource() { } } /** + * + * *
      * REQUIRED: The resource for which the policy detail is being requested.
      * See the operation documentation for the appropriate value for this field.
      * 
* - * string resource = 1; + * + * string resource = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The resource to set. + * @return This builder for chaining. */ - public Builder setResource( - String value) { + public Builder setResource(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - + throw new NullPointerException(); + } + resource_ = value; onChanged(); return this; } /** + * + * *
      * REQUIRED: The resource for which the policy detail is being requested.
      * See the operation documentation for the appropriate value for this field.
      * 
* - * string resource = 1; + * + * string resource = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return This builder for chaining. */ public Builder clearResource() { - + resource_ = getDefaultInstance().getResource(); onChanged(); return this; } /** + * + * *
      * REQUIRED: The resource for which the policy detail is being requested.
      * See the operation documentation for the appropriate value for this field.
      * 
* - * string resource = 1; + * + * string resource = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @param value The bytes for resource to set. + * @return This builder for chaining. */ - public Builder setResourceBytes( - com.google.protobuf.ByteString value) { + public Builder setResourceBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); - + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); + resource_ = value; onChanged(); return this; } - private com.google.protobuf.LazyStringList permissions_ = com.google.protobuf.LazyStringArrayList.EMPTY; + private com.google.protobuf.LazyStringList permissions_ = + com.google.protobuf.LazyStringArrayList.EMPTY; + private void ensurePermissionsIsMutable() { - if (!((bitField0_ & 0x00000002) != 0)) { + if (!((bitField0_ & 0x00000001) != 0)) { permissions_ = new com.google.protobuf.LazyStringArrayList(permissions_); - bitField0_ |= 0x00000002; - } + bitField0_ |= 0x00000001; + } } /** + * + * *
      * The set of permissions to check for the `resource`. Permissions with
      * wildcards (such as '*' or 'storage.*') are not allowed. For more
@@ -653,13 +744,16 @@ private void ensurePermissionsIsMutable() {
      * [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions).
      * 
* - * repeated string permissions = 2; + * repeated string permissions = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return A list containing the permissions. */ - public com.google.protobuf.ProtocolStringList - getPermissionsList() { + public com.google.protobuf.ProtocolStringList getPermissionsList() { return permissions_.getUnmodifiableView(); } /** + * + * *
      * The set of permissions to check for the `resource`. Permissions with
      * wildcards (such as '*' or 'storage.*') are not allowed. For more
@@ -667,12 +761,16 @@ private void ensurePermissionsIsMutable() {
      * [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions).
      * 
* - * repeated string permissions = 2; + * repeated string permissions = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The count of permissions. */ public int getPermissionsCount() { return permissions_.size(); } /** + * + * *
      * The set of permissions to check for the `resource`. Permissions with
      * wildcards (such as '*' or 'storage.*') are not allowed. For more
@@ -680,12 +778,17 @@ public int getPermissionsCount() {
      * [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions).
      * 
* - * repeated string permissions = 2; + * repeated string permissions = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @param index The index of the element to return. + * @return The permissions at the given index. */ - public String getPermissions(int index) { + public java.lang.String getPermissions(int index) { return permissions_.get(index); } /** + * + * *
      * The set of permissions to check for the `resource`. Permissions with
      * wildcards (such as '*' or 'storage.*') are not allowed. For more
@@ -693,13 +796,17 @@ public String getPermissions(int index) {
      * [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions).
      * 
* - * repeated string permissions = 2; + * repeated string permissions = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @param index The index of the value to return. + * @return The bytes of the permissions at the given index. */ - public com.google.protobuf.ByteString - getPermissionsBytes(int index) { + public com.google.protobuf.ByteString getPermissionsBytes(int index) { return permissions_.getByteString(index); } /** + * + * *
      * The set of permissions to check for the `resource`. Permissions with
      * wildcards (such as '*' or 'storage.*') are not allowed. For more
@@ -707,19 +814,24 @@ public String getPermissions(int index) {
      * [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions).
      * 
* - * repeated string permissions = 2; + * repeated string permissions = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @param index The index to set the value at. + * @param value The permissions to set. + * @return This builder for chaining. */ - public Builder setPermissions( - int index, String value) { + public Builder setPermissions(int index, java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - ensurePermissionsIsMutable(); + throw new NullPointerException(); + } + ensurePermissionsIsMutable(); permissions_.set(index, value); onChanged(); return this; } /** + * + * *
      * The set of permissions to check for the `resource`. Permissions with
      * wildcards (such as '*' or 'storage.*') are not allowed. For more
@@ -727,19 +839,23 @@ public Builder setPermissions(
      * [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions).
      * 
* - * repeated string permissions = 2; + * repeated string permissions = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The permissions to add. + * @return This builder for chaining. */ - public Builder addPermissions( - String value) { + public Builder addPermissions(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - ensurePermissionsIsMutable(); + throw new NullPointerException(); + } + ensurePermissionsIsMutable(); permissions_.add(value); onChanged(); return this; } /** + * + * *
      * The set of permissions to check for the `resource`. Permissions with
      * wildcards (such as '*' or 'storage.*') are not allowed. For more
@@ -747,17 +863,20 @@ public Builder addPermissions(
      * [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions).
      * 
* - * repeated string permissions = 2; + * repeated string permissions = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @param values The permissions to add. + * @return This builder for chaining. */ - public Builder addAllPermissions( - Iterable values) { + public Builder addAllPermissions(java.lang.Iterable values) { ensurePermissionsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, permissions_); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, permissions_); onChanged(); return this; } /** + * + * *
      * The set of permissions to check for the `resource`. Permissions with
      * wildcards (such as '*' or 'storage.*') are not allowed. For more
@@ -765,15 +884,19 @@ public Builder addAllPermissions(
      * [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions).
      * 
* - * repeated string permissions = 2; + * repeated string permissions = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return This builder for chaining. */ public Builder clearPermissions() { permissions_ = com.google.protobuf.LazyStringArrayList.EMPTY; - bitField0_ = (bitField0_ & ~0x00000002); + bitField0_ = (bitField0_ & ~0x00000001); onChanged(); return this; } /** + * + * *
      * The set of permissions to check for the `resource`. Permissions with
      * wildcards (such as '*' or 'storage.*') are not allowed. For more
@@ -781,69 +904,69 @@ public Builder clearPermissions() {
      * [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions).
      * 
* - * repeated string permissions = 2; + * repeated string permissions = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @param value The bytes of the permissions to add. + * @return This builder for chaining. */ - public Builder addPermissionsBytes( - com.google.protobuf.ByteString value) { + public Builder addPermissionsBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); ensurePermissionsIsMutable(); permissions_.add(value); onChanged(); return this; } - @Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } - @Override + @java.lang.Override public final Builder mergeUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return super.mergeUnknownFields(unknownFields); } - // @@protoc_insertion_point(builder_scope:google.iam.v1.TestIamPermissionsRequest) } // @@protoc_insertion_point(class_scope:google.iam.v1.TestIamPermissionsRequest) - private static final TestIamPermissionsRequest DEFAULT_INSTANCE; + private static final com.google.iam.v1.TestIamPermissionsRequest DEFAULT_INSTANCE; + static { - DEFAULT_INSTANCE = new TestIamPermissionsRequest(); + DEFAULT_INSTANCE = new com.google.iam.v1.TestIamPermissionsRequest(); } - public static TestIamPermissionsRequest getDefaultInstance() { + public static com.google.iam.v1.TestIamPermissionsRequest getDefaultInstance() { return DEFAULT_INSTANCE; } - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - @Override - public TestIamPermissionsRequest parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new TestIamPermissionsRequest(input, extensionRegistry); - } - }; + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public TestIamPermissionsRequest parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new TestIamPermissionsRequest(input, extensionRegistry); + } + }; public static com.google.protobuf.Parser parser() { return PARSER; } - @Override + @java.lang.Override public com.google.protobuf.Parser getParserForType() { return PARSER; } - @Override - public TestIamPermissionsRequest getDefaultInstanceForType() { + @java.lang.Override + public com.google.iam.v1.TestIamPermissionsRequest getDefaultInstanceForType() { return DEFAULT_INSTANCE; } - } - diff --git a/proto-google-iam-v1/src/main/java/com/google/iam/v1/TestIamPermissionsRequestOrBuilder.java b/proto-google-iam-v1/src/main/java/com/google/iam/v1/TestIamPermissionsRequestOrBuilder.java index cdb463c5..53b56f27 100644 --- a/proto-google-iam-v1/src/main/java/com/google/iam/v1/TestIamPermissionsRequestOrBuilder.java +++ b/proto-google-iam-v1/src/main/java/com/google/iam/v1/TestIamPermissionsRequestOrBuilder.java @@ -1,33 +1,62 @@ +/* + * 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/iam/v1/iam_policy.proto package com.google.iam.v1; -public interface TestIamPermissionsRequestOrBuilder extends +public interface TestIamPermissionsRequestOrBuilder + extends // @@protoc_insertion_point(interface_extends:google.iam.v1.TestIamPermissionsRequest) com.google.protobuf.MessageOrBuilder { /** + * + * *
    * REQUIRED: The resource for which the policy detail is being requested.
    * See the operation documentation for the appropriate value for this field.
    * 
* - * string resource = 1; + * + * string resource = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The resource. */ - String getResource(); + java.lang.String getResource(); /** + * + * *
    * REQUIRED: The resource for which the policy detail is being requested.
    * See the operation documentation for the appropriate value for this field.
    * 
* - * string resource = 1; + * + * string resource = 1 [(.google.api.field_behavior) = REQUIRED, (.google.api.resource_reference) = { ... } + * + * + * @return The bytes for resource. */ - com.google.protobuf.ByteString - getResourceBytes(); + com.google.protobuf.ByteString getResourceBytes(); /** + * + * *
    * The set of permissions to check for the `resource`. Permissions with
    * wildcards (such as '*' or 'storage.*') are not allowed. For more
@@ -35,11 +64,14 @@ public interface TestIamPermissionsRequestOrBuilder extends
    * [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions).
    * 
* - * repeated string permissions = 2; + * repeated string permissions = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return A list containing the permissions. */ - java.util.List - getPermissionsList(); + java.util.List getPermissionsList(); /** + * + * *
    * The set of permissions to check for the `resource`. Permissions with
    * wildcards (such as '*' or 'storage.*') are not allowed. For more
@@ -47,10 +79,14 @@ public interface TestIamPermissionsRequestOrBuilder extends
    * [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions).
    * 
* - * repeated string permissions = 2; + * repeated string permissions = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @return The count of permissions. */ int getPermissionsCount(); /** + * + * *
    * The set of permissions to check for the `resource`. Permissions with
    * wildcards (such as '*' or 'storage.*') are not allowed. For more
@@ -58,10 +94,15 @@ public interface TestIamPermissionsRequestOrBuilder extends
    * [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions).
    * 
* - * repeated string permissions = 2; + * repeated string permissions = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @param index The index of the element to return. + * @return The permissions at the given index. */ - String getPermissions(int index); + java.lang.String getPermissions(int index); /** + * + * *
    * The set of permissions to check for the `resource`. Permissions with
    * wildcards (such as '*' or 'storage.*') are not allowed. For more
@@ -69,8 +110,10 @@ public interface TestIamPermissionsRequestOrBuilder extends
    * [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions).
    * 
* - * repeated string permissions = 2; + * repeated string permissions = 2 [(.google.api.field_behavior) = REQUIRED]; + * + * @param index The index of the value to return. + * @return The bytes of the permissions at the given index. */ - com.google.protobuf.ByteString - getPermissionsBytes(int index); + com.google.protobuf.ByteString getPermissionsBytes(int index); } diff --git a/proto-google-iam-v1/src/main/java/com/google/iam/v1/TestIamPermissionsResponse.java b/proto-google-iam-v1/src/main/java/com/google/iam/v1/TestIamPermissionsResponse.java index cd6d2585..50400d50 100644 --- a/proto-google-iam-v1/src/main/java/com/google/iam/v1/TestIamPermissionsResponse.java +++ b/proto-google-iam-v1/src/main/java/com/google/iam/v1/TestIamPermissionsResponse.java @@ -1,40 +1,64 @@ +/* + * 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/iam/v1/iam_policy.proto package com.google.iam.v1; /** + * + * *
  * Response message for `TestIamPermissions` method.
  * 
* * Protobuf type {@code google.iam.v1.TestIamPermissionsResponse} */ -public final class TestIamPermissionsResponse extends - com.google.protobuf.GeneratedMessageV3 implements +public final class TestIamPermissionsResponse extends com.google.protobuf.GeneratedMessageV3 + implements // @@protoc_insertion_point(message_implements:google.iam.v1.TestIamPermissionsResponse) TestIamPermissionsResponseOrBuilder { -private static final long serialVersionUID = 0L; + private static final long serialVersionUID = 0L; // Use TestIamPermissionsResponse.newBuilder() to construct. private TestIamPermissionsResponse(com.google.protobuf.GeneratedMessageV3.Builder builder) { super(builder); } + private TestIamPermissionsResponse() { permissions_ = com.google.protobuf.LazyStringArrayList.EMPTY; } - @Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { + @java.lang.Override + @SuppressWarnings({"unused"}) + protected java.lang.Object newInstance(UnusedPrivateParameter unused) { + return new TestIamPermissionsResponse(); + } + + @java.lang.Override + public final com.google.protobuf.UnknownFieldSet getUnknownFields() { return this.unknownFields; } + private TestIamPermissionsResponse( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { this(); if (extensionRegistry == null) { - throw new NullPointerException(); + throw new java.lang.NullPointerException(); } int mutable_bitField0_ = 0; com.google.protobuf.UnknownFieldSet.Builder unknownFields = @@ -47,29 +71,29 @@ private TestIamPermissionsResponse( case 0: done = true; break; - case 10: { - String s = input.readStringRequireUtf8(); - if (!((mutable_bitField0_ & 0x00000001) != 0)) { - permissions_ = new com.google.protobuf.LazyStringArrayList(); - mutable_bitField0_ |= 0x00000001; + case 10: + { + java.lang.String s = input.readStringRequireUtf8(); + if (!((mutable_bitField0_ & 0x00000001) != 0)) { + permissions_ = new com.google.protobuf.LazyStringArrayList(); + mutable_bitField0_ |= 0x00000001; + } + permissions_.add(s); + break; } - permissions_.add(s); - break; - } - default: { - if (!parseUnknownField( - input, unknownFields, extensionRegistry, tag)) { - done = true; + default: + { + if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) { + done = true; + } + break; } - break; - } } } } catch (com.google.protobuf.InvalidProtocolBufferException e) { throw e.setUnfinishedMessage(this); } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException( - e).setUnfinishedMessage(this); + throw new com.google.protobuf.InvalidProtocolBufferException(e).setUnfinishedMessage(this); } finally { if (((mutable_bitField0_ & 0x00000001) != 0)) { permissions_ = permissions_.getUnmodifiableView(); @@ -78,70 +102,90 @@ private TestIamPermissionsResponse( makeExtensionsImmutable(); } } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return IamPolicyProto.internal_static_google_iam_v1_TestIamPermissionsResponse_descriptor; + + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.iam.v1.IamPolicyProto + .internal_static_google_iam_v1_TestIamPermissionsResponse_descriptor; } - @Override - protected FieldAccessorTable + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return IamPolicyProto.internal_static_google_iam_v1_TestIamPermissionsResponse_fieldAccessorTable + return com.google.iam.v1.IamPolicyProto + .internal_static_google_iam_v1_TestIamPermissionsResponse_fieldAccessorTable .ensureFieldAccessorsInitialized( - TestIamPermissionsResponse.class, Builder.class); + com.google.iam.v1.TestIamPermissionsResponse.class, + com.google.iam.v1.TestIamPermissionsResponse.Builder.class); } public static final int PERMISSIONS_FIELD_NUMBER = 1; private com.google.protobuf.LazyStringList permissions_; /** + * + * *
    * A subset of `TestPermissionsRequest.permissions` that the caller is
    * allowed.
    * 
* * repeated string permissions = 1; + * + * @return A list containing the permissions. */ - public com.google.protobuf.ProtocolStringList - getPermissionsList() { + public com.google.protobuf.ProtocolStringList getPermissionsList() { return permissions_; } /** + * + * *
    * A subset of `TestPermissionsRequest.permissions` that the caller is
    * allowed.
    * 
* * repeated string permissions = 1; + * + * @return The count of permissions. */ public int getPermissionsCount() { return permissions_.size(); } /** + * + * *
    * A subset of `TestPermissionsRequest.permissions` that the caller is
    * allowed.
    * 
* * repeated string permissions = 1; + * + * @param index The index of the element to return. + * @return The permissions at the given index. */ - public String getPermissions(int index) { + public java.lang.String getPermissions(int index) { return permissions_.get(index); } /** + * + * *
    * A subset of `TestPermissionsRequest.permissions` that the caller is
    * allowed.
    * 
* * repeated string permissions = 1; + * + * @param index The index of the value to return. + * @return The bytes of the permissions at the given index. */ - public com.google.protobuf.ByteString - getPermissionsBytes(int index) { + public com.google.protobuf.ByteString getPermissionsBytes(int index) { return permissions_.getByteString(index); } private byte memoizedIsInitialized = -1; - @Override + + @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; if (isInitialized == 1) return true; @@ -151,16 +195,15 @@ public final boolean isInitialized() { return true; } - @Override - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { for (int i = 0; i < permissions_.size(); i++) { com.google.protobuf.GeneratedMessageV3.writeString(output, 1, permissions_.getRaw(i)); } unknownFields.writeTo(output); } - @Override + @java.lang.Override public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; @@ -179,23 +222,23 @@ public int getSerializedSize() { return size; } - @Override - public boolean equals(final Object obj) { + @java.lang.Override + public boolean equals(final java.lang.Object obj) { if (obj == this) { - return true; + return true; } - if (!(obj instanceof TestIamPermissionsResponse)) { + if (!(obj instanceof com.google.iam.v1.TestIamPermissionsResponse)) { return super.equals(obj); } - TestIamPermissionsResponse other = (TestIamPermissionsResponse) obj; + com.google.iam.v1.TestIamPermissionsResponse other = + (com.google.iam.v1.TestIamPermissionsResponse) obj; - if (!getPermissionsList() - .equals(other.getPermissionsList())) return false; + if (!getPermissionsList().equals(other.getPermissionsList())) return false; if (!unknownFields.equals(other.unknownFields)) return false; return true; } - @Override + @java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; @@ -211,118 +254,127 @@ public int hashCode() { return hash; } - public static TestIamPermissionsResponse parseFrom( - java.nio.ByteBuffer data) + public static com.google.iam.v1.TestIamPermissionsResponse parseFrom(java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } - public static TestIamPermissionsResponse parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + + public static com.google.iam.v1.TestIamPermissionsResponse parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static TestIamPermissionsResponse parseFrom( + + public static com.google.iam.v1.TestIamPermissionsResponse parseFrom( com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } - public static TestIamPermissionsResponse parseFrom( + + public static com.google.iam.v1.TestIamPermissionsResponse parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static TestIamPermissionsResponse parseFrom(byte[] data) + + public static com.google.iam.v1.TestIamPermissionsResponse parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } - public static TestIamPermissionsResponse parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + + public static com.google.iam.v1.TestIamPermissionsResponse parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static TestIamPermissionsResponse parseFrom(java.io.InputStream input) + + public static com.google.iam.v1.TestIamPermissionsResponse parseFrom(java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } - public static TestIamPermissionsResponse parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + + public static com.google.iam.v1.TestIamPermissionsResponse parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } - public static TestIamPermissionsResponse parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); + + public static com.google.iam.v1.TestIamPermissionsResponse parseDelimitedFrom( + java.io.InputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } - public static TestIamPermissionsResponse parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + + public static com.google.iam.v1.TestIamPermissionsResponse parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); } - public static TestIamPermissionsResponse parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + + public static com.google.iam.v1.TestIamPermissionsResponse parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } - public static TestIamPermissionsResponse parseFrom( + + public static com.google.iam.v1.TestIamPermissionsResponse parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); } - @Override - public Builder newBuilderForType() { return newBuilder(); } public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } - public static Builder newBuilder(TestIamPermissionsResponse prototype) { + + public static Builder newBuilder(com.google.iam.v1.TestIamPermissionsResponse prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } - @Override + + @java.lang.Override public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } - @Override - protected Builder newBuilderForType( - BuilderParent parent) { + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** + * + * *
    * Response message for `TestIamPermissions` method.
    * 
* * Protobuf type {@code google.iam.v1.TestIamPermissionsResponse} */ - public static final class Builder extends - com.google.protobuf.GeneratedMessageV3.Builder implements + public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder + implements // @@protoc_insertion_point(builder_implements:google.iam.v1.TestIamPermissionsResponse) com.google.iam.v1.TestIamPermissionsResponseOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return IamPolicyProto.internal_static_google_iam_v1_TestIamPermissionsResponse_descriptor; + public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() { + return com.google.iam.v1.IamPolicyProto + .internal_static_google_iam_v1_TestIamPermissionsResponse_descriptor; } - @Override - protected FieldAccessorTable + @java.lang.Override + protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable() { - return IamPolicyProto.internal_static_google_iam_v1_TestIamPermissionsResponse_fieldAccessorTable + return com.google.iam.v1.IamPolicyProto + .internal_static_google_iam_v1_TestIamPermissionsResponse_fieldAccessorTable .ensureFieldAccessorsInitialized( - TestIamPermissionsResponse.class, Builder.class); + com.google.iam.v1.TestIamPermissionsResponse.class, + com.google.iam.v1.TestIamPermissionsResponse.Builder.class); } // Construct using com.google.iam.v1.TestIamPermissionsResponse.newBuilder() @@ -330,17 +382,16 @@ private Builder() { maybeForceBuilderInitialization(); } - private Builder( - BuilderParent parent) { + private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { super(parent); maybeForceBuilderInitialization(); } + private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessageV3 - .alwaysUseFieldBuilders) { - } + if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {} } - @Override + + @java.lang.Override public Builder clear() { super.clear(); permissions_ = com.google.protobuf.LazyStringArrayList.EMPTY; @@ -348,29 +399,30 @@ public Builder clear() { return this; } - @Override - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return IamPolicyProto.internal_static_google_iam_v1_TestIamPermissionsResponse_descriptor; + @java.lang.Override + public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() { + return com.google.iam.v1.IamPolicyProto + .internal_static_google_iam_v1_TestIamPermissionsResponse_descriptor; } - @Override - public TestIamPermissionsResponse getDefaultInstanceForType() { - return TestIamPermissionsResponse.getDefaultInstance(); + @java.lang.Override + public com.google.iam.v1.TestIamPermissionsResponse getDefaultInstanceForType() { + return com.google.iam.v1.TestIamPermissionsResponse.getDefaultInstance(); } - @Override - public TestIamPermissionsResponse build() { - TestIamPermissionsResponse result = buildPartial(); + @java.lang.Override + public com.google.iam.v1.TestIamPermissionsResponse build() { + com.google.iam.v1.TestIamPermissionsResponse result = buildPartial(); if (!result.isInitialized()) { throw newUninitializedMessageException(result); } return result; } - @Override - public TestIamPermissionsResponse buildPartial() { - TestIamPermissionsResponse result = new TestIamPermissionsResponse(this); + @java.lang.Override + public com.google.iam.v1.TestIamPermissionsResponse buildPartial() { + com.google.iam.v1.TestIamPermissionsResponse result = + new com.google.iam.v1.TestIamPermissionsResponse(this); int from_bitField0_ = bitField0_; if (((bitField0_ & 0x00000001) != 0)) { permissions_ = permissions_.getUnmodifiableView(); @@ -381,50 +433,51 @@ public TestIamPermissionsResponse buildPartial() { return result; } - @Override + @java.lang.Override public Builder clone() { return super.clone(); } - @Override + + @java.lang.Override public Builder setField( - com.google.protobuf.Descriptors.FieldDescriptor field, - Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.setField(field, value); } - @Override - public Builder clearField( - com.google.protobuf.Descriptors.FieldDescriptor field) { + + @java.lang.Override + public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) { return super.clearField(field); } - @Override - public Builder clearOneof( - com.google.protobuf.Descriptors.OneofDescriptor oneof) { + + @java.lang.Override + public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) { return super.clearOneof(oneof); } - @Override + + @java.lang.Override public Builder setRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - int index, Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) { return super.setRepeatedField(field, index, value); } - @Override + + @java.lang.Override public Builder addRepeatedField( - com.google.protobuf.Descriptors.FieldDescriptor field, - Object value) { + com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) { return super.addRepeatedField(field, value); } - @Override + + @java.lang.Override public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof TestIamPermissionsResponse) { - return mergeFrom((TestIamPermissionsResponse)other); + if (other instanceof com.google.iam.v1.TestIamPermissionsResponse) { + return mergeFrom((com.google.iam.v1.TestIamPermissionsResponse) other); } else { super.mergeFrom(other); return this; } } - public Builder mergeFrom(TestIamPermissionsResponse other) { - if (other == TestIamPermissionsResponse.getDefaultInstance()) return this; + public Builder mergeFrom(com.google.iam.v1.TestIamPermissionsResponse other) { + if (other == com.google.iam.v1.TestIamPermissionsResponse.getDefaultInstance()) return this; if (!other.permissions_.isEmpty()) { if (permissions_.isEmpty()) { permissions_ = other.permissions_; @@ -440,21 +493,21 @@ public Builder mergeFrom(TestIamPermissionsResponse other) { return this; } - @Override + @java.lang.Override public final boolean isInitialized() { return true; } - @Override + @java.lang.Override public Builder mergeFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - TestIamPermissionsResponse parsedMessage = null; + com.google.iam.v1.TestIamPermissionsResponse parsedMessage = null; try { parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (TestIamPermissionsResponse) e.getUnfinishedMessage(); + parsedMessage = (com.google.iam.v1.TestIamPermissionsResponse) e.getUnfinishedMessage(); throw e.unwrapIOException(); } finally { if (parsedMessage != null) { @@ -463,120 +516,155 @@ public Builder mergeFrom( } return this; } + private int bitField0_; - private com.google.protobuf.LazyStringList permissions_ = com.google.protobuf.LazyStringArrayList.EMPTY; + private com.google.protobuf.LazyStringList permissions_ = + com.google.protobuf.LazyStringArrayList.EMPTY; + private void ensurePermissionsIsMutable() { if (!((bitField0_ & 0x00000001) != 0)) { permissions_ = new com.google.protobuf.LazyStringArrayList(permissions_); bitField0_ |= 0x00000001; - } + } } /** + * + * *
      * A subset of `TestPermissionsRequest.permissions` that the caller is
      * allowed.
      * 
* * repeated string permissions = 1; + * + * @return A list containing the permissions. */ - public com.google.protobuf.ProtocolStringList - getPermissionsList() { + public com.google.protobuf.ProtocolStringList getPermissionsList() { return permissions_.getUnmodifiableView(); } /** + * + * *
      * A subset of `TestPermissionsRequest.permissions` that the caller is
      * allowed.
      * 
* * repeated string permissions = 1; + * + * @return The count of permissions. */ public int getPermissionsCount() { return permissions_.size(); } /** + * + * *
      * A subset of `TestPermissionsRequest.permissions` that the caller is
      * allowed.
      * 
* * repeated string permissions = 1; + * + * @param index The index of the element to return. + * @return The permissions at the given index. */ - public String getPermissions(int index) { + public java.lang.String getPermissions(int index) { return permissions_.get(index); } /** + * + * *
      * A subset of `TestPermissionsRequest.permissions` that the caller is
      * allowed.
      * 
* * repeated string permissions = 1; + * + * @param index The index of the value to return. + * @return The bytes of the permissions at the given index. */ - public com.google.protobuf.ByteString - getPermissionsBytes(int index) { + public com.google.protobuf.ByteString getPermissionsBytes(int index) { return permissions_.getByteString(index); } /** + * + * *
      * A subset of `TestPermissionsRequest.permissions` that the caller is
      * allowed.
      * 
* * repeated string permissions = 1; + * + * @param index The index to set the value at. + * @param value The permissions to set. + * @return This builder for chaining. */ - public Builder setPermissions( - int index, String value) { + public Builder setPermissions(int index, java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - ensurePermissionsIsMutable(); + throw new NullPointerException(); + } + ensurePermissionsIsMutable(); permissions_.set(index, value); onChanged(); return this; } /** + * + * *
      * A subset of `TestPermissionsRequest.permissions` that the caller is
      * allowed.
      * 
* * repeated string permissions = 1; + * + * @param value The permissions to add. + * @return This builder for chaining. */ - public Builder addPermissions( - String value) { + public Builder addPermissions(java.lang.String value) { if (value == null) { - throw new NullPointerException(); - } - ensurePermissionsIsMutable(); + throw new NullPointerException(); + } + ensurePermissionsIsMutable(); permissions_.add(value); onChanged(); return this; } /** + * + * *
      * A subset of `TestPermissionsRequest.permissions` that the caller is
      * allowed.
      * 
* * repeated string permissions = 1; + * + * @param values The permissions to add. + * @return This builder for chaining. */ - public Builder addAllPermissions( - Iterable values) { + public Builder addAllPermissions(java.lang.Iterable values) { ensurePermissionsIsMutable(); - com.google.protobuf.AbstractMessageLite.Builder.addAll( - values, permissions_); + com.google.protobuf.AbstractMessageLite.Builder.addAll(values, permissions_); onChanged(); return this; } /** + * + * *
      * A subset of `TestPermissionsRequest.permissions` that the caller is
      * allowed.
      * 
* * repeated string permissions = 1; + * + * @return This builder for chaining. */ public Builder clearPermissions() { permissions_ = com.google.protobuf.LazyStringArrayList.EMPTY; @@ -585,74 +673,76 @@ public Builder clearPermissions() { return this; } /** + * + * *
      * A subset of `TestPermissionsRequest.permissions` that the caller is
      * allowed.
      * 
* * repeated string permissions = 1; + * + * @param value The bytes of the permissions to add. + * @return This builder for chaining. */ - public Builder addPermissionsBytes( - com.google.protobuf.ByteString value) { + public Builder addPermissionsBytes(com.google.protobuf.ByteString value) { if (value == null) { - throw new NullPointerException(); - } - checkByteStringIsUtf8(value); + throw new NullPointerException(); + } + checkByteStringIsUtf8(value); ensurePermissionsIsMutable(); permissions_.add(value); onChanged(); return this; } - @Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } - @Override + @java.lang.Override public final Builder mergeUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return super.mergeUnknownFields(unknownFields); } - // @@protoc_insertion_point(builder_scope:google.iam.v1.TestIamPermissionsResponse) } // @@protoc_insertion_point(class_scope:google.iam.v1.TestIamPermissionsResponse) - private static final TestIamPermissionsResponse DEFAULT_INSTANCE; + private static final com.google.iam.v1.TestIamPermissionsResponse DEFAULT_INSTANCE; + static { - DEFAULT_INSTANCE = new TestIamPermissionsResponse(); + DEFAULT_INSTANCE = new com.google.iam.v1.TestIamPermissionsResponse(); } - public static TestIamPermissionsResponse getDefaultInstance() { + public static com.google.iam.v1.TestIamPermissionsResponse getDefaultInstance() { return DEFAULT_INSTANCE; } - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - @Override - public TestIamPermissionsResponse parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new TestIamPermissionsResponse(input, extensionRegistry); - } - }; + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public TestIamPermissionsResponse parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new TestIamPermissionsResponse(input, extensionRegistry); + } + }; public static com.google.protobuf.Parser parser() { return PARSER; } - @Override + @java.lang.Override public com.google.protobuf.Parser getParserForType() { return PARSER; } - @Override - public TestIamPermissionsResponse getDefaultInstanceForType() { + @java.lang.Override + public com.google.iam.v1.TestIamPermissionsResponse getDefaultInstanceForType() { return DEFAULT_INSTANCE; } - } - diff --git a/proto-google-iam-v1/src/main/java/com/google/iam/v1/TestIamPermissionsResponseOrBuilder.java b/proto-google-iam-v1/src/main/java/com/google/iam/v1/TestIamPermissionsResponseOrBuilder.java index bf0b513f..da677cbe 100644 --- a/proto-google-iam-v1/src/main/java/com/google/iam/v1/TestIamPermissionsResponseOrBuilder.java +++ b/proto-google-iam-v1/src/main/java/com/google/iam/v1/TestIamPermissionsResponseOrBuilder.java @@ -1,48 +1,80 @@ +/* + * 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/iam/v1/iam_policy.proto package com.google.iam.v1; -public interface TestIamPermissionsResponseOrBuilder extends +public interface TestIamPermissionsResponseOrBuilder + extends // @@protoc_insertion_point(interface_extends:google.iam.v1.TestIamPermissionsResponse) com.google.protobuf.MessageOrBuilder { /** + * + * *
    * A subset of `TestPermissionsRequest.permissions` that the caller is
    * allowed.
    * 
* * repeated string permissions = 1; + * + * @return A list containing the permissions. */ - java.util.List - getPermissionsList(); + java.util.List getPermissionsList(); /** + * + * *
    * A subset of `TestPermissionsRequest.permissions` that the caller is
    * allowed.
    * 
* * repeated string permissions = 1; + * + * @return The count of permissions. */ int getPermissionsCount(); /** + * + * *
    * A subset of `TestPermissionsRequest.permissions` that the caller is
    * allowed.
    * 
* * repeated string permissions = 1; + * + * @param index The index of the element to return. + * @return The permissions at the given index. */ - String getPermissions(int index); + java.lang.String getPermissions(int index); /** + * + * *
    * A subset of `TestPermissionsRequest.permissions` that the caller is
    * allowed.
    * 
* * repeated string permissions = 1; + * + * @param index The index of the value to return. + * @return The bytes of the permissions at the given index. */ - com.google.protobuf.ByteString - getPermissionsBytes(int index); + com.google.protobuf.ByteString getPermissionsBytes(int index); } diff --git a/proto-google-iam-v1/src/main/java/com/google/iam/v1/logging/AuditData.java b/proto-google-iam-v1/src/main/java/com/google/iam/v1/logging/AuditData.java index e248fdf2..926b0838 100644 --- a/proto-google-iam-v1/src/main/java/com/google/iam/v1/logging/AuditData.java +++ b/proto-google-iam-v1/src/main/java/com/google/iam/v1/logging/AuditData.java @@ -1,9 +1,26 @@ +/* + * 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/iam/v1/logging/audit_data.proto package com.google.iam.v1.logging; /** + * + * *
  * Audit log information specific to Cloud IAM. This message is serialized
  * as an `Any` type in the `ServiceData` message of an
@@ -12,32 +29,37 @@
  *
  * Protobuf type {@code google.iam.v1.logging.AuditData}
  */
-public  final class AuditData extends
-    com.google.protobuf.GeneratedMessageV3 implements
+public final class AuditData extends com.google.protobuf.GeneratedMessageV3
+    implements
     // @@protoc_insertion_point(message_implements:google.iam.v1.logging.AuditData)
     AuditDataOrBuilder {
-private static final long serialVersionUID = 0L;
+  private static final long serialVersionUID = 0L;
   // Use AuditData.newBuilder() to construct.
   private AuditData(com.google.protobuf.GeneratedMessageV3.Builder builder) {
     super(builder);
   }
-  private AuditData() {
+
+  private AuditData() {}
+
+  @java.lang.Override
+  @SuppressWarnings({"unused"})
+  protected java.lang.Object newInstance(UnusedPrivateParameter unused) {
+    return new AuditData();
   }
 
-  @Override
-  public final com.google.protobuf.UnknownFieldSet
-  getUnknownFields() {
+  @java.lang.Override
+  public final com.google.protobuf.UnknownFieldSet getUnknownFields() {
     return this.unknownFields;
   }
+
   private AuditData(
       com.google.protobuf.CodedInputStream input,
       com.google.protobuf.ExtensionRegistryLite extensionRegistry)
       throws com.google.protobuf.InvalidProtocolBufferException {
     this();
     if (extensionRegistry == null) {
-      throw new NullPointerException();
+      throw new java.lang.NullPointerException();
     }
-    int mutable_bitField0_ = 0;
     com.google.protobuf.UnknownFieldSet.Builder unknownFields =
         com.google.protobuf.UnknownFieldSet.newBuilder();
     try {
@@ -48,74 +70,88 @@ private AuditData(
           case 0:
             done = true;
             break;
-          case 18: {
-            com.google.iam.v1.PolicyDelta.Builder subBuilder = null;
-            if (policyDelta_ != null) {
-              subBuilder = policyDelta_.toBuilder();
+          case 18:
+            {
+              com.google.iam.v1.PolicyDelta.Builder subBuilder = null;
+              if (policyDelta_ != null) {
+                subBuilder = policyDelta_.toBuilder();
+              }
+              policyDelta_ =
+                  input.readMessage(com.google.iam.v1.PolicyDelta.parser(), extensionRegistry);
+              if (subBuilder != null) {
+                subBuilder.mergeFrom(policyDelta_);
+                policyDelta_ = subBuilder.buildPartial();
+              }
+
+              break;
             }
-            policyDelta_ = input.readMessage(com.google.iam.v1.PolicyDelta.parser(), extensionRegistry);
-            if (subBuilder != null) {
-              subBuilder.mergeFrom(policyDelta_);
-              policyDelta_ = subBuilder.buildPartial();
-            }
-
-            break;
-          }
-          default: {
-            if (!parseUnknownField(
-                input, unknownFields, extensionRegistry, tag)) {
-              done = true;
+          default:
+            {
+              if (!parseUnknownField(input, unknownFields, extensionRegistry, tag)) {
+                done = true;
+              }
+              break;
             }
-            break;
-          }
         }
       }
     } catch (com.google.protobuf.InvalidProtocolBufferException e) {
       throw e.setUnfinishedMessage(this);
     } catch (java.io.IOException e) {
-      throw new com.google.protobuf.InvalidProtocolBufferException(
-          e).setUnfinishedMessage(this);
+      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.iam.v1.logging.AuditDataProto.internal_static_google_iam_v1_logging_AuditData_descriptor;
+
+  public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() {
+    return com.google.iam.v1.logging.AuditDataProto
+        .internal_static_google_iam_v1_logging_AuditData_descriptor;
   }
 
-  @Override
-  protected FieldAccessorTable
+  @java.lang.Override
+  protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
       internalGetFieldAccessorTable() {
-    return com.google.iam.v1.logging.AuditDataProto.internal_static_google_iam_v1_logging_AuditData_fieldAccessorTable
+    return com.google.iam.v1.logging.AuditDataProto
+        .internal_static_google_iam_v1_logging_AuditData_fieldAccessorTable
         .ensureFieldAccessorsInitialized(
-            AuditData.class, Builder.class);
+            com.google.iam.v1.logging.AuditData.class,
+            com.google.iam.v1.logging.AuditData.Builder.class);
   }
 
   public static final int POLICY_DELTA_FIELD_NUMBER = 2;
   private com.google.iam.v1.PolicyDelta policyDelta_;
   /**
+   *
+   *
    * 
    * Policy delta between the original policy and the newly set policy.
    * 
* * .google.iam.v1.PolicyDelta policy_delta = 2; + * + * @return Whether the policyDelta field is set. */ public boolean hasPolicyDelta() { return policyDelta_ != null; } /** + * + * *
    * Policy delta between the original policy and the newly set policy.
    * 
* * .google.iam.v1.PolicyDelta policy_delta = 2; + * + * @return The policyDelta. */ public com.google.iam.v1.PolicyDelta getPolicyDelta() { return policyDelta_ == null ? com.google.iam.v1.PolicyDelta.getDefaultInstance() : policyDelta_; } /** + * + * *
    * Policy delta between the original policy and the newly set policy.
    * 
@@ -127,7 +163,8 @@ public com.google.iam.v1.PolicyDeltaOrBuilder getPolicyDeltaOrBuilder() { } private byte memoizedIsInitialized = -1; - @Override + + @java.lang.Override public final boolean isInitialized() { byte isInitialized = memoizedIsInitialized; if (isInitialized == 1) return true; @@ -137,50 +174,47 @@ public final boolean isInitialized() { return true; } - @Override - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { + @java.lang.Override + public void writeTo(com.google.protobuf.CodedOutputStream output) throws java.io.IOException { if (policyDelta_ != null) { output.writeMessage(2, getPolicyDelta()); } unknownFields.writeTo(output); } - @Override + @java.lang.Override public int getSerializedSize() { int size = memoizedSize; if (size != -1) return size; size = 0; if (policyDelta_ != null) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(2, getPolicyDelta()); + size += com.google.protobuf.CodedOutputStream.computeMessageSize(2, getPolicyDelta()); } size += unknownFields.getSerializedSize(); memoizedSize = size; return size; } - @Override - public boolean equals(final Object obj) { + @java.lang.Override + public boolean equals(final java.lang.Object obj) { if (obj == this) { - return true; + return true; } - if (!(obj instanceof AuditData)) { + if (!(obj instanceof com.google.iam.v1.logging.AuditData)) { return super.equals(obj); } - AuditData other = (AuditData) obj; + com.google.iam.v1.logging.AuditData other = (com.google.iam.v1.logging.AuditData) obj; if (hasPolicyDelta() != other.hasPolicyDelta()) return false; if (hasPolicyDelta()) { - if (!getPolicyDelta() - .equals(other.getPolicyDelta())) return false; + if (!getPolicyDelta().equals(other.getPolicyDelta())) return false; } if (!unknownFields.equals(other.unknownFields)) return false; return true; } - @Override + @java.lang.Override public int hashCode() { if (memoizedHashCode != 0) { return memoizedHashCode; @@ -196,97 +230,103 @@ public int hashCode() { return hash; } - public static AuditData parseFrom( - java.nio.ByteBuffer data) + public static com.google.iam.v1.logging.AuditData parseFrom(java.nio.ByteBuffer data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } - public static AuditData parseFrom( - java.nio.ByteBuffer data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + + public static com.google.iam.v1.logging.AuditData parseFrom( + java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static AuditData parseFrom( - com.google.protobuf.ByteString data) + + public static com.google.iam.v1.logging.AuditData parseFrom(com.google.protobuf.ByteString data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } - public static AuditData parseFrom( + + public static com.google.iam.v1.logging.AuditData parseFrom( com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static AuditData parseFrom(byte[] data) + + public static com.google.iam.v1.logging.AuditData parseFrom(byte[] data) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data); } - public static AuditData parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + + public static com.google.iam.v1.logging.AuditData parseFrom( + byte[] data, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws com.google.protobuf.InvalidProtocolBufferException { return PARSER.parseFrom(data, extensionRegistry); } - public static AuditData parseFrom(java.io.InputStream input) + + public static com.google.iam.v1.logging.AuditData parseFrom(java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } - public static AuditData parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + + public static com.google.iam.v1.logging.AuditData parseFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); } - public static AuditData parseDelimitedFrom(java.io.InputStream input) + + public static com.google.iam.v1.logging.AuditData parseDelimitedFrom(java.io.InputStream input) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException(PARSER, input); } - public static AuditData parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) + + public static com.google.iam.v1.logging.AuditData parseDelimitedFrom( + java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseDelimitedWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseDelimitedWithIOException( + PARSER, input, extensionRegistry); } - public static AuditData parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input); + + public static com.google.iam.v1.logging.AuditData parseFrom( + com.google.protobuf.CodedInputStream input) throws java.io.IOException { + return com.google.protobuf.GeneratedMessageV3.parseWithIOException(PARSER, input); } - public static AuditData parseFrom( + + public static com.google.iam.v1.logging.AuditData parseFrom( com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws java.io.IOException { - return com.google.protobuf.GeneratedMessageV3 - .parseWithIOException(PARSER, input, extensionRegistry); + return com.google.protobuf.GeneratedMessageV3.parseWithIOException( + PARSER, input, extensionRegistry); + } + + @java.lang.Override + public Builder newBuilderForType() { + return newBuilder(); } - @Override - public Builder newBuilderForType() { return newBuilder(); } public static Builder newBuilder() { return DEFAULT_INSTANCE.toBuilder(); } - public static Builder newBuilder(AuditData prototype) { + + public static Builder newBuilder(com.google.iam.v1.logging.AuditData prototype) { return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype); } - @Override + + @java.lang.Override public Builder toBuilder() { - return this == DEFAULT_INSTANCE - ? new Builder() : new Builder().mergeFrom(this); + return this == DEFAULT_INSTANCE ? new Builder() : new Builder().mergeFrom(this); } - @Override - protected Builder newBuilderForType( - BuilderParent parent) { + @java.lang.Override + protected Builder newBuilderForType(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) { Builder builder = new Builder(parent); return builder; } /** + * + * *
    * Audit log information specific to Cloud IAM. This message is serialized
    * as an `Any` type in the `ServiceData` message of an
@@ -295,21 +335,23 @@ protected Builder newBuilderForType(
    *
    * Protobuf type {@code google.iam.v1.logging.AuditData}
    */
-  public static final class Builder extends
-      com.google.protobuf.GeneratedMessageV3.Builder implements
+  public static final class Builder extends com.google.protobuf.GeneratedMessageV3.Builder
+      implements
       // @@protoc_insertion_point(builder_implements:google.iam.v1.logging.AuditData)
       com.google.iam.v1.logging.AuditDataOrBuilder {
-    public static final com.google.protobuf.Descriptors.Descriptor
-        getDescriptor() {
-      return com.google.iam.v1.logging.AuditDataProto.internal_static_google_iam_v1_logging_AuditData_descriptor;
+    public static final com.google.protobuf.Descriptors.Descriptor getDescriptor() {
+      return com.google.iam.v1.logging.AuditDataProto
+          .internal_static_google_iam_v1_logging_AuditData_descriptor;
     }
 
-    @Override
-    protected FieldAccessorTable
+    @java.lang.Override
+    protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
         internalGetFieldAccessorTable() {
-      return com.google.iam.v1.logging.AuditDataProto.internal_static_google_iam_v1_logging_AuditData_fieldAccessorTable
+      return com.google.iam.v1.logging.AuditDataProto
+          .internal_static_google_iam_v1_logging_AuditData_fieldAccessorTable
           .ensureFieldAccessorsInitialized(
-              AuditData.class, Builder.class);
+              com.google.iam.v1.logging.AuditData.class,
+              com.google.iam.v1.logging.AuditData.Builder.class);
     }
 
     // Construct using com.google.iam.v1.logging.AuditData.newBuilder()
@@ -317,17 +359,16 @@ private Builder() {
       maybeForceBuilderInitialization();
     }
 
-    private Builder(
-        BuilderParent parent) {
+    private Builder(com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
       super(parent);
       maybeForceBuilderInitialization();
     }
+
     private void maybeForceBuilderInitialization() {
-      if (com.google.protobuf.GeneratedMessageV3
-              .alwaysUseFieldBuilders) {
-      }
+      if (com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders) {}
     }
-    @Override
+
+    @java.lang.Override
     public Builder clear() {
       super.clear();
       if (policyDeltaBuilder_ == null) {
@@ -339,29 +380,29 @@ public Builder clear() {
       return this;
     }
 
-    @Override
-    public com.google.protobuf.Descriptors.Descriptor
-        getDescriptorForType() {
-      return com.google.iam.v1.logging.AuditDataProto.internal_static_google_iam_v1_logging_AuditData_descriptor;
+    @java.lang.Override
+    public com.google.protobuf.Descriptors.Descriptor getDescriptorForType() {
+      return com.google.iam.v1.logging.AuditDataProto
+          .internal_static_google_iam_v1_logging_AuditData_descriptor;
     }
 
-    @Override
-    public AuditData getDefaultInstanceForType() {
-      return AuditData.getDefaultInstance();
+    @java.lang.Override
+    public com.google.iam.v1.logging.AuditData getDefaultInstanceForType() {
+      return com.google.iam.v1.logging.AuditData.getDefaultInstance();
     }
 
-    @Override
-    public AuditData build() {
-      AuditData result = buildPartial();
+    @java.lang.Override
+    public com.google.iam.v1.logging.AuditData build() {
+      com.google.iam.v1.logging.AuditData result = buildPartial();
       if (!result.isInitialized()) {
         throw newUninitializedMessageException(result);
       }
       return result;
     }
 
-    @Override
-    public AuditData buildPartial() {
-      AuditData result = new AuditData(this);
+    @java.lang.Override
+    public com.google.iam.v1.logging.AuditData buildPartial() {
+      com.google.iam.v1.logging.AuditData result = new com.google.iam.v1.logging.AuditData(this);
       if (policyDeltaBuilder_ == null) {
         result.policyDelta_ = policyDelta_;
       } else {
@@ -371,50 +412,51 @@ public AuditData buildPartial() {
       return result;
     }
 
-    @Override
+    @java.lang.Override
     public Builder clone() {
       return super.clone();
     }
-    @Override
+
+    @java.lang.Override
     public Builder setField(
-        com.google.protobuf.Descriptors.FieldDescriptor field,
-        Object value) {
+        com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) {
       return super.setField(field, value);
     }
-    @Override
-    public Builder clearField(
-        com.google.protobuf.Descriptors.FieldDescriptor field) {
+
+    @java.lang.Override
+    public Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field) {
       return super.clearField(field);
     }
-    @Override
-    public Builder clearOneof(
-        com.google.protobuf.Descriptors.OneofDescriptor oneof) {
+
+    @java.lang.Override
+    public Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof) {
       return super.clearOneof(oneof);
     }
-    @Override
+
+    @java.lang.Override
     public Builder setRepeatedField(
-        com.google.protobuf.Descriptors.FieldDescriptor field,
-        int index, Object value) {
+        com.google.protobuf.Descriptors.FieldDescriptor field, int index, java.lang.Object value) {
       return super.setRepeatedField(field, index, value);
     }
-    @Override
+
+    @java.lang.Override
     public Builder addRepeatedField(
-        com.google.protobuf.Descriptors.FieldDescriptor field,
-        Object value) {
+        com.google.protobuf.Descriptors.FieldDescriptor field, java.lang.Object value) {
       return super.addRepeatedField(field, value);
     }
-    @Override
+
+    @java.lang.Override
     public Builder mergeFrom(com.google.protobuf.Message other) {
-      if (other instanceof AuditData) {
-        return mergeFrom((AuditData)other);
+      if (other instanceof com.google.iam.v1.logging.AuditData) {
+        return mergeFrom((com.google.iam.v1.logging.AuditData) other);
       } else {
         super.mergeFrom(other);
         return this;
       }
     }
 
-    public Builder mergeFrom(AuditData other) {
-      if (other == AuditData.getDefaultInstance()) return this;
+    public Builder mergeFrom(com.google.iam.v1.logging.AuditData other) {
+      if (other == com.google.iam.v1.logging.AuditData.getDefaultInstance()) return this;
       if (other.hasPolicyDelta()) {
         mergePolicyDelta(other.getPolicyDelta());
       }
@@ -423,21 +465,21 @@ public Builder mergeFrom(AuditData other) {
       return this;
     }
 
-    @Override
+    @java.lang.Override
     public final boolean isInitialized() {
       return true;
     }
 
-    @Override
+    @java.lang.Override
     public Builder mergeFrom(
         com.google.protobuf.CodedInputStream input,
         com.google.protobuf.ExtensionRegistryLite extensionRegistry)
         throws java.io.IOException {
-      AuditData parsedMessage = null;
+      com.google.iam.v1.logging.AuditData parsedMessage = null;
       try {
         parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
       } catch (com.google.protobuf.InvalidProtocolBufferException e) {
-        parsedMessage = (AuditData) e.getUnfinishedMessage();
+        parsedMessage = (com.google.iam.v1.logging.AuditData) e.getUnfinishedMessage();
         throw e.unwrapIOException();
       } finally {
         if (parsedMessage != null) {
@@ -449,32 +491,47 @@ public Builder mergeFrom(
 
     private com.google.iam.v1.PolicyDelta policyDelta_;
     private com.google.protobuf.SingleFieldBuilderV3<
-        com.google.iam.v1.PolicyDelta, com.google.iam.v1.PolicyDelta.Builder, com.google.iam.v1.PolicyDeltaOrBuilder> policyDeltaBuilder_;
+            com.google.iam.v1.PolicyDelta,
+            com.google.iam.v1.PolicyDelta.Builder,
+            com.google.iam.v1.PolicyDeltaOrBuilder>
+        policyDeltaBuilder_;
     /**
+     *
+     *
      * 
      * Policy delta between the original policy and the newly set policy.
      * 
* * .google.iam.v1.PolicyDelta policy_delta = 2; + * + * @return Whether the policyDelta field is set. */ public boolean hasPolicyDelta() { return policyDeltaBuilder_ != null || policyDelta_ != null; } /** + * + * *
      * Policy delta between the original policy and the newly set policy.
      * 
* * .google.iam.v1.PolicyDelta policy_delta = 2; + * + * @return The policyDelta. */ public com.google.iam.v1.PolicyDelta getPolicyDelta() { if (policyDeltaBuilder_ == null) { - return policyDelta_ == null ? com.google.iam.v1.PolicyDelta.getDefaultInstance() : policyDelta_; + return policyDelta_ == null + ? com.google.iam.v1.PolicyDelta.getDefaultInstance() + : policyDelta_; } else { return policyDeltaBuilder_.getMessage(); } } /** + * + * *
      * Policy delta between the original policy and the newly set policy.
      * 
@@ -495,14 +552,15 @@ public Builder setPolicyDelta(com.google.iam.v1.PolicyDelta value) { return this; } /** + * + * *
      * Policy delta between the original policy and the newly set policy.
      * 
* * .google.iam.v1.PolicyDelta policy_delta = 2; */ - public Builder setPolicyDelta( - com.google.iam.v1.PolicyDelta.Builder builderForValue) { + public Builder setPolicyDelta(com.google.iam.v1.PolicyDelta.Builder builderForValue) { if (policyDeltaBuilder_ == null) { policyDelta_ = builderForValue.build(); onChanged(); @@ -513,6 +571,8 @@ public Builder setPolicyDelta( return this; } /** + * + * *
      * Policy delta between the original policy and the newly set policy.
      * 
@@ -523,7 +583,9 @@ public Builder mergePolicyDelta(com.google.iam.v1.PolicyDelta value) { if (policyDeltaBuilder_ == null) { if (policyDelta_ != null) { policyDelta_ = - com.google.iam.v1.PolicyDelta.newBuilder(policyDelta_).mergeFrom(value).buildPartial(); + com.google.iam.v1.PolicyDelta.newBuilder(policyDelta_) + .mergeFrom(value) + .buildPartial(); } else { policyDelta_ = value; } @@ -535,6 +597,8 @@ public Builder mergePolicyDelta(com.google.iam.v1.PolicyDelta value) { return this; } /** + * + * *
      * Policy delta between the original policy and the newly set policy.
      * 
@@ -553,6 +617,8 @@ public Builder clearPolicyDelta() { return this; } /** + * + * *
      * Policy delta between the original policy and the newly set policy.
      * 
@@ -560,11 +626,13 @@ public Builder clearPolicyDelta() { * .google.iam.v1.PolicyDelta policy_delta = 2; */ public com.google.iam.v1.PolicyDelta.Builder getPolicyDeltaBuilder() { - + onChanged(); return getPolicyDeltaFieldBuilder().getBuilder(); } /** + * + * *
      * Policy delta between the original policy and the newly set policy.
      * 
@@ -575,11 +643,14 @@ public com.google.iam.v1.PolicyDeltaOrBuilder getPolicyDeltaOrBuilder() { if (policyDeltaBuilder_ != null) { return policyDeltaBuilder_.getMessageOrBuilder(); } else { - return policyDelta_ == null ? - com.google.iam.v1.PolicyDelta.getDefaultInstance() : policyDelta_; + return policyDelta_ == null + ? com.google.iam.v1.PolicyDelta.getDefaultInstance() + : policyDelta_; } } /** + * + * *
      * Policy delta between the original policy and the newly set policy.
      * 
@@ -587,68 +658,69 @@ public com.google.iam.v1.PolicyDeltaOrBuilder getPolicyDeltaOrBuilder() { * .google.iam.v1.PolicyDelta policy_delta = 2; */ private com.google.protobuf.SingleFieldBuilderV3< - com.google.iam.v1.PolicyDelta, com.google.iam.v1.PolicyDelta.Builder, com.google.iam.v1.PolicyDeltaOrBuilder> + com.google.iam.v1.PolicyDelta, + com.google.iam.v1.PolicyDelta.Builder, + com.google.iam.v1.PolicyDeltaOrBuilder> getPolicyDeltaFieldBuilder() { if (policyDeltaBuilder_ == null) { - policyDeltaBuilder_ = new com.google.protobuf.SingleFieldBuilderV3< - com.google.iam.v1.PolicyDelta, com.google.iam.v1.PolicyDelta.Builder, com.google.iam.v1.PolicyDeltaOrBuilder>( - getPolicyDelta(), - getParentForChildren(), - isClean()); + policyDeltaBuilder_ = + new com.google.protobuf.SingleFieldBuilderV3< + com.google.iam.v1.PolicyDelta, + com.google.iam.v1.PolicyDelta.Builder, + com.google.iam.v1.PolicyDeltaOrBuilder>( + getPolicyDelta(), getParentForChildren(), isClean()); policyDelta_ = null; } return policyDeltaBuilder_; } - @Override - public final Builder setUnknownFields( - final com.google.protobuf.UnknownFieldSet unknownFields) { + + @java.lang.Override + public final Builder setUnknownFields(final com.google.protobuf.UnknownFieldSet unknownFields) { return super.setUnknownFields(unknownFields); } - @Override + @java.lang.Override public final Builder mergeUnknownFields( final com.google.protobuf.UnknownFieldSet unknownFields) { return super.mergeUnknownFields(unknownFields); } - // @@protoc_insertion_point(builder_scope:google.iam.v1.logging.AuditData) } // @@protoc_insertion_point(class_scope:google.iam.v1.logging.AuditData) - private static final AuditData DEFAULT_INSTANCE; + private static final com.google.iam.v1.logging.AuditData DEFAULT_INSTANCE; + static { - DEFAULT_INSTANCE = new AuditData(); + DEFAULT_INSTANCE = new com.google.iam.v1.logging.AuditData(); } - public static AuditData getDefaultInstance() { + public static com.google.iam.v1.logging.AuditData getDefaultInstance() { return DEFAULT_INSTANCE; } - private static final com.google.protobuf.Parser - PARSER = new com.google.protobuf.AbstractParser() { - @Override - public AuditData parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new AuditData(input, extensionRegistry); - } - }; + private static final com.google.protobuf.Parser PARSER = + new com.google.protobuf.AbstractParser() { + @java.lang.Override + public AuditData parsePartialFrom( + com.google.protobuf.CodedInputStream input, + com.google.protobuf.ExtensionRegistryLite extensionRegistry) + throws com.google.protobuf.InvalidProtocolBufferException { + return new AuditData(input, extensionRegistry); + } + }; public static com.google.protobuf.Parser parser() { return PARSER; } - @Override + @java.lang.Override public com.google.protobuf.Parser getParserForType() { return PARSER; } - @Override - public AuditData getDefaultInstanceForType() { + @java.lang.Override + public com.google.iam.v1.logging.AuditData getDefaultInstanceForType() { return DEFAULT_INSTANCE; } - } - diff --git a/proto-google-iam-v1/src/main/java/com/google/iam/v1/logging/AuditDataOrBuilder.java b/proto-google-iam-v1/src/main/java/com/google/iam/v1/logging/AuditDataOrBuilder.java index e942cdbb..8076902f 100644 --- a/proto-google-iam-v1/src/main/java/com/google/iam/v1/logging/AuditDataOrBuilder.java +++ b/proto-google-iam-v1/src/main/java/com/google/iam/v1/logging/AuditDataOrBuilder.java @@ -1,29 +1,55 @@ +/* + * 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/iam/v1/logging/audit_data.proto package com.google.iam.v1.logging; -public interface AuditDataOrBuilder extends +public interface AuditDataOrBuilder + extends // @@protoc_insertion_point(interface_extends:google.iam.v1.logging.AuditData) com.google.protobuf.MessageOrBuilder { /** + * + * *
    * Policy delta between the original policy and the newly set policy.
    * 
* * .google.iam.v1.PolicyDelta policy_delta = 2; + * + * @return Whether the policyDelta field is set. */ boolean hasPolicyDelta(); /** + * + * *
    * Policy delta between the original policy and the newly set policy.
    * 
* * .google.iam.v1.PolicyDelta policy_delta = 2; + * + * @return The policyDelta. */ com.google.iam.v1.PolicyDelta getPolicyDelta(); /** + * + * *
    * Policy delta between the original policy and the newly set policy.
    * 
diff --git a/proto-google-iam-v1/src/main/java/com/google/iam/v1/logging/AuditDataProto.java b/proto-google-iam-v1/src/main/java/com/google/iam/v1/logging/AuditDataProto.java index f769613e..7a5309a6 100644 --- a/proto-google-iam-v1/src/main/java/com/google/iam/v1/logging/AuditDataProto.java +++ b/proto-google-iam-v1/src/main/java/com/google/iam/v1/logging/AuditDataProto.java @@ -1,3 +1,18 @@ +/* + * 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/iam/v1/logging/audit_data.proto @@ -5,59 +20,51 @@ public final class AuditDataProto { private AuditDataProto() {} - public static void registerAllExtensions( - com.google.protobuf.ExtensionRegistryLite registry) { - } - public static void registerAllExtensions( - com.google.protobuf.ExtensionRegistry registry) { - registerAllExtensions( - (com.google.protobuf.ExtensionRegistryLite) registry); + 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_iam_v1_logging_AuditData_descriptor; - static final - com.google.protobuf.GeneratedMessageV3.FieldAccessorTable + internal_static_google_iam_v1_logging_AuditData_descriptor; + static final com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internal_static_google_iam_v1_logging_AuditData_fieldAccessorTable; - public static com.google.protobuf.Descriptors.FileDescriptor - getDescriptor() { + public static com.google.protobuf.Descriptors.FileDescriptor getDescriptor() { return descriptor; } - private static com.google.protobuf.Descriptors.FileDescriptor - descriptor; + + private static com.google.protobuf.Descriptors.FileDescriptor descriptor; + static { - String[] descriptorData = { - "\n&google/iam/v1/logging/audit_data.proto" + - "\022\025google.iam.v1.logging\032\034google/api/anno" + - "tations.proto\032\032google/iam/v1/policy.prot" + - "o\"=\n\tAuditData\0220\n\014policy_delta\030\002 \001(\0132\032.g" + - "oogle.iam.v1.PolicyDeltaB\211\001\n\031com.google." + - "iam.v1.loggingB\016AuditDataProtoP\001Z Date: Tue, 5 May 2020 19:44:24 +0200 Subject: [PATCH 02/15] deps: update dependency com.google.api.grpc:proto-google-common-protos to v1.18.0 (#2) --- pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pom.xml b/pom.xml index bf23f4f1..cd114c60 100644 --- a/pom.xml +++ b/pom.xml @@ -63,7 +63,7 @@ UTF-8 github google-iam-parent - 1.17.0 + 1.18.0 3.11.4 4.13 1.29.0 From b2e7dd9610355e6b5c1b2b14dd0e8af07d04600c Mon Sep 17 00:00:00 2001 From: Jeff Ching Date: Wed, 13 May 2020 16:39:41 -0700 Subject: [PATCH 03/15] ci: enable GitHub actions (#5) * ci: enable GitHub actions * chore: fix build.bat --- .github/workflows/ci.yaml | 76 +++++++++++++++++++++++++++++++++++++++ .kokoro/build.bat | 2 +- 2 files changed, 77 insertions(+), 1 deletion(-) create mode 100644 .github/workflows/ci.yaml diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml new file mode 100644 index 00000000..445b4bf8 --- /dev/null +++ b/.github/workflows/ci.yaml @@ -0,0 +1,76 @@ +on: + push: + branches: + - master + pull_request: +name: ci +jobs: + units: + runs-on: ubuntu-latest + strategy: + matrix: + java: [7, 8, 11] + steps: + - uses: actions/checkout@v2 + - uses: actions/setup-java@v1 + with: + java-version: ${{matrix.java}} + - run: java -version + - run: .kokoro/build.sh + env: + JOB_TYPE: test + - name: coverage + uses: codecov/codecov-action@v1 + with: + name: actions ${{matrix.java}} + windows: + runs-on: windows-latest + steps: + - uses: actions/checkout@v2 + - uses: actions/setup-java@v1 + with: + java-version: 8 + - run: java -version + - run: .kokoro/build.bat + env: + JOB_TYPE: test + dependencies: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - uses: actions/setup-java@v1 + with: + java-version: 8 + - run: java -version + - run: .kokoro/dependencies.sh + linkage-monitor: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - uses: actions/setup-java@v1 + with: + java-version: 8 + - run: java -version + - run: .kokoro/linkage-monitor.sh + lint: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - uses: actions/setup-java@v1 + with: + java-version: 8 + - run: java -version + - run: .kokoro/build.sh + env: + JOB_TYPE: lint + clirr: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - uses: actions/setup-java@v1 + with: + java-version: 8 + - run: java -version + - run: .kokoro/build.sh + env: + JOB_TYPE: clirr \ No newline at end of file diff --git a/.kokoro/build.bat b/.kokoro/build.bat index 5af7c27e..05826ad9 100644 --- a/.kokoro/build.bat +++ b/.kokoro/build.bat @@ -1,3 +1,3 @@ :: See documentation in type-shell-output.bat -"C:\Program Files\Git\bin\bash.exe" github/java-iam/.kokoro/build.sh +"C:\Program Files\Git\bin\bash.exe" %~dp0build.sh From 73b7a4a03411326f88e49c2efbd1e34d2170dc1b Mon Sep 17 00:00:00 2001 From: WhiteSource Renovate Date: Tue, 19 May 2020 23:53:18 +0200 Subject: [PATCH 04/15] deps: update dependency com.google.protobuf:protobuf-bom to v3.12.0 (#6) This PR contains the following updates: | Package | Update | Change | |---|---|---| | [com.google.protobuf:protobuf-bom](https://developers.google.com/protocol-buffers/) ([source](https://togithub.com/protocolbuffers/protobuf)) | minor | `3.11.4` -> `3.12.0` | --- ### Release Notes
protocolbuffers/protobuf ### [`v3.12.0`](https://togithub.com/protocolbuffers/protobuf/releases/v3.12.0) [Compare Source](https://togithub.com/protocolbuffers/protobuf/compare/v3.11.4...v3.12.0) ### Protocol Compiler - [experimental] Singular, non-message typed fields in proto3 now support presence tracking. This is enabled by adding the "optional" field label and passing the `--experimental_allow_proto3_optional` flag to protoc. - For usage info, see [docs/field_presence.md](docs/field_presence.md). - During this experimental phase, code generators should update to support proto3 presence, see [docs/implementing_proto3_presence.md](docs/implementing_proto3_presence.md) for instructions. - Allow duplicate symbol names when multiple descriptor sets are passed on the command-line, to match the behavior when multiple .proto files are passed. - Deterministic `protoc --descriptor_set_out` ([#​7175](https://togithub.com/protocolbuffers/protobuf/issues/7175)) ### C++ - [experimental] Added proto3 presence support. - New descriptor APIs to support proto3 presence. - Fix for [#​7463](https://togithub.com/protocolbuffers/protobuf/issues/7463) in -rc1 (core dump mixing optional and singular fields in proto3) - Enable Arenas by default on all .proto files. - Documented that users are not allowed to subclass Message or MessageLite. - Mark generated classes as final; inheriting from protos is strongly discouraged. - Add stack overflow protection for text format with unknown fields. - Add accessors for map key and value FieldDescriptors. - Add FieldMaskUtil::FromFieldNumbers(). - MessageDifferencer: use ParsePartial() on Any fields so the diff does not fail when there are missing required fields. - ReflectionOps::Merge(): lookup messages in the right factory, if it can. - Added Descriptor::WellKnownTypes enum and Descriptor::well_known_type() accessor as an easier way of determining if a message is a Well-Known Type. - Optimized RepeatedField::Add() when it is used in a loop. - Made proto move/swap more efficient. - De-virtualize the GetArena() method in MessageLite. - Improves performance of json_stream_parser.cc by factor 1000 ([#​7230](https://togithub.com/protocolbuffers/protobuf/issues/7230)) - bug: [#​7076](https://togithub.com/protocolbuffers/protobuf/issues/7076) undefine Windows OUT and OPTIONAL macros ([#​7087](https://togithub.com/protocolbuffers/protobuf/issues/7087)) - Fixed a bug in FieldDescriptor::DebugString() that would erroneously print an "optional" label for a field in a oneof. - Fix bug in parsing bool extensions that assumed they are always 1 byte. - Fix off-by-one error in FieldOptions::ByteSize() when extensions are present. - Clarified the comments to show an example of the difference between Descriptor::extension and DescriptorPool::FindAllExtensions. - Add a compiler option 'code_size' to force optimize_for=code_size on all protos where this is possible. ### Java - [experimental] Added proto3 presence support. - Fix for [#​7480](https://togithub.com/protocolbuffers/protobuf/issues/7480) in -rc1 ("TextFormat and JsonFormat ignore experimental proto3 optional enums") - Fix for [#​7505](https://togithub.com/protocolbuffers/protobuf/issues/7505) in -rc1 (" toString() returns incorrect ascii when there are duplicate keys in a map") - Mark java enum \_VALUE constants as [@​Deprecated](https://togithub.com/Deprecated) if the enum field is deprecated - reduce size for enums with allow_alias set to true. - Sort map fields alphabetically by the field's key when printing textproto. - TextFormat.merge() handles Any as top level type. - Throw a descriptive IllegalArgumentException when calling getValueDescriptor() on enum special value UNRECOGNIZED instead of ArrayIndexOutOfBoundsException. - Fixed an issue with JsonFormat.printer() where setting printingEnumsAsInts() would override the configuration passed into includingDefaultValueFields(). - Implement overrides of indexOf() and contains() on primitive lists returned for repeated fields to avoid autoboxing the list contents. - Add overload to FieldMaskUtil.fromStringList that accepts a descriptor. - [bazel] Move Java runtime/toolchains into //java ([#​7190](https://togithub.com/protocolbuffers/protobuf/issues/7190)) ### Python - [experimental] Added proto3 presence support. - [experimental] fast import protobuf module, only works with cpp generated code linked in. - Truncate 'float' fields to 4 bytes of precision in setters for pure-Python implementation (C++ extension was already doing this). - Fixed a memory leak in C++ bindings. - Added a deprecation warning when code tries to create Descriptor objects directly. - Fix unintended comparison between bytes and string in descriptor.py. - Avoid printing excess digits for float fields in TextFormat. - Remove Python 2.5 syntax compatibility from the proto compiler generated \_pb2.py module code. - Drop 3.3, 3.4 and use single version docker images for all python tests ([#​7396](https://togithub.com/protocolbuffers/protobuf/issues/7396)) ### JavaScript - Fix js message pivot selection ([#​6813](https://togithub.com/protocolbuffers/protobuf/issues/6813)) ### PHP - Persistent Descriptor Pool ([#​6899](https://togithub.com/protocolbuffers/protobuf/issues/6899)) - Implement lazy loading of php class for proto messages ([#​6911](https://togithub.com/protocolbuffers/protobuf/issues/6911)) - Correct [@​return](https://togithub.com/return) in Any.unpack docblock ([#​7089](https://togithub.com/protocolbuffers/protobuf/issues/7089)) - Ignore unknown enum value when ignore_unknown specified ([#​7455](https://togithub.com/protocolbuffers/protobuf/issues/7455)) ### Ruby - [experimental] Implemented proto3 presence for Ruby. ([#​7406](https://togithub.com/protocolbuffers/protobuf/issues/7406)) - Stop building binary gems for ruby <2.5 ([#​7453](https://togithub.com/protocolbuffers/protobuf/issues/7453)) - Fix for wrappers with a zero value ([#​7195](https://togithub.com/protocolbuffers/protobuf/issues/7195)) - Fix for JSON serialization of 0/empty-valued wrapper types ([#​7198](https://togithub.com/protocolbuffers/protobuf/issues/7198)) - Call "Class#new" over rb_class_new_instance in decoding ([#​7352](https://togithub.com/protocolbuffers/protobuf/issues/7352)) - Build extensions for Ruby 2.7 ([#​7027](https://togithub.com/protocolbuffers/protobuf/issues/7027)) - assigning 'nil' to submessage should clear the field. ([#​7397](https://togithub.com/protocolbuffers/protobuf/issues/7397)) ### C - [experimental] Add support for proto3 presence fields in C# ([#​7382](https://togithub.com/protocolbuffers/protobuf/issues/7382)) - Cleanup various bits of Google.Protobuf ([#​6674](https://togithub.com/protocolbuffers/protobuf/issues/6674)) - Fix conformance test failures for Google.Protobuf ([#​6910](https://togithub.com/protocolbuffers/protobuf/issues/6910)) - Fix latest ArgumentException for C# extensions ([#​6938](https://togithub.com/protocolbuffers/protobuf/issues/6938)) - Remove unnecessary branch from ReadTag ([#​7289](https://togithub.com/protocolbuffers/protobuf/issues/7289)) - Enforce recursion depth checking for unknown fields ([#​7132](https://togithub.com/protocolbuffers/protobuf/issues/7132)) - Mark GetOption API as obsolete and expose the "GetOptions()" method on descriptors instead ([#​7491](https://togithub.com/protocolbuffers/protobuf/issues/7491)) - Remove Has/Clear members for C# message fields in proto2 ([#​7429](https://togithub.com/protocolbuffers/protobuf/issues/7429)) ### Objective-C - [experimental] ObjC Proto3 optional support ([#​7421](https://togithub.com/protocolbuffers/protobuf/issues/7421)) - Block subclassing of generated classes ([#​7124](https://togithub.com/protocolbuffers/protobuf/issues/7124)) - Use references to Obj C classes instead of names in descriptors. ([#​7026](https://togithub.com/protocolbuffers/protobuf/issues/7026)) - Revisit how the WKTs are bundled with ObjC. ([#​7173](https://togithub.com/protocolbuffers/protobuf/issues/7173)) ### Other - Add a proto_lang_toolchain for javalite ([#​6882](https://togithub.com/protocolbuffers/protobuf/issues/6882)) - [bazel] Update gtest and deprecate //external:{gtest,gtest_main} ([#​7237](https://togithub.com/protocolbuffers/protobuf/issues/7237)) - Add application note for explicit presence tracking. ([#​7390](https://togithub.com/protocolbuffers/protobuf/issues/7390)) - Howto doc for implementing proto3 presence in a code generator. ([#​7407](https://togithub.com/protocolbuffers/protobuf/issues/7407))
--- ### Renovate configuration :date: **Schedule**: At any time (no schedule defined). :vertical_traffic_light: **Automerge**: Disabled by config. Please merge this manually once you are satisfied. :recycle: **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. :no_bell: **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] If you want to rebase/retry this PR, check this box --- This PR has been generated by [WhiteSource Renovate](https://renovate.whitesourcesoftware.com). View repository job log [here](https://app.renovatebot.com/dashboard#googleapis/java-iam). --- pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pom.xml b/pom.xml index cd114c60..f8b3775a 100644 --- a/pom.xml +++ b/pom.xml @@ -64,7 +64,7 @@ github google-iam-parent 1.18.0 - 3.11.4 + 3.12.0 4.13 1.29.0 29.0-android From 2c3fe2197e8a49690faa49c86a13f49ec5c83bec Mon Sep 17 00:00:00 2001 From: WhiteSource Renovate Date: Thu, 21 May 2020 00:56:05 +0200 Subject: [PATCH 05/15] build(deps): update dependency com.google.cloud:google-cloud-shared-config to v0.6.0 (#7) This PR contains the following updates: | Package | Update | Change | |---|---|---| | [com.google.cloud:google-cloud-shared-config](https://togithub.com/googleapis/java-shared-config) | minor | `0.5.0` -> `0.6.0` | --- ### Release Notes
googleapis/java-shared-config ### [`v0.6.0`](https://togithub.com/googleapis/java-shared-config/blob/master/CHANGELOG.md#​060-httpswwwgithubcomgoogleapisjava-shared-configcomparev050v060-2020-05-19) [Compare Source](https://togithub.com/googleapis/java-shared-config/compare/v0.5.0...v0.6.0) ##### Features - add new configuration necessary to support auto-value ([#​136](https://www.github.com/googleapis/java-shared-config/issues/136)) ([c14689b](https://www.github.com/googleapis/java-shared-config/commit/c14689b8791c173687f719d73156a989aedd7ba6))
--- ### Renovate configuration :date: **Schedule**: At any time (no schedule defined). :vertical_traffic_light: **Automerge**: Disabled by config. Please merge this manually once you are satisfied. :recycle: **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. :no_bell: **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] If you want to rebase/retry this PR, check this box --- This PR has been generated by [WhiteSource Renovate](https://renovate.whitesourcesoftware.com). View repository job log [here](https://app.renovatebot.com/dashboard#googleapis/java-iam). --- pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pom.xml b/pom.xml index f8b3775a..9e78c022 100644 --- a/pom.xml +++ b/pom.xml @@ -14,7 +14,7 @@ com.google.cloud google-cloud-shared-config - 0.5.0 + 0.6.0 From 74ecaa1ea647a6271ac4afa9ef7b7195ef72e829 Mon Sep 17 00:00:00 2001 From: WhiteSource Renovate Date: Thu, 4 Jun 2020 22:36:12 +0200 Subject: [PATCH 06/15] build(deps): update dependency org.apache.maven.plugins:maven-project-info-reports-plugin to v3.1.0 (#9) This PR contains the following updates: | Package | Update | Change | |---|---|---| | org.apache.maven.plugins:maven-project-info-reports-plugin | minor | `3.0.0` -> `3.1.0` | --- ### Renovate configuration :date: **Schedule**: At any time (no schedule defined). :vertical_traffic_light: **Automerge**: Disabled by config. Please merge this manually once you are satisfied. :recycle: **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. :no_bell: **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] If you want to rebase/retry this PR, check this box --- This PR has been generated by [WhiteSource Renovate](https://renovate.whitesourcesoftware.com). View repository job log [here](https://app.renovatebot.com/dashboard#googleapis/java-iam). --- pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pom.xml b/pom.xml index 9e78c022..48eca47e 100644 --- a/pom.xml +++ b/pom.xml @@ -121,7 +121,7 @@ org.apache.maven.plugins maven-project-info-reports-plugin - 3.0.0 + 3.1.0 From f69ac15807aafc345f980091feadd4eb3996976c Mon Sep 17 00:00:00 2001 From: WhiteSource Renovate Date: Thu, 11 Jun 2020 01:13:01 +0200 Subject: [PATCH 07/15] deps: update dependency io.grpc:grpc-bom to v1.30.0 (#10) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This PR contains the following updates: | Package | Update | Change | |---|---|---| | [io.grpc:grpc-bom](https://togithub.com/grpc/grpc-java) | minor | `1.29.0` -> `1.30.0` | --- ### Release Notes
grpc/grpc-java ### [`v1.30.0`](https://togithub.com/grpc/grpc-java/releases/v1.30.0) [Compare Source](https://togithub.com/grpc/grpc-java/compare/v1.29.0...v1.30.0) ##### Behavioral Changes - netty: Bandwidth delay product (BDP) is enabled by default ([#​6979](https://togithub.com/grpc/grpc-java/issues/6979)). BDP dynamically adjusts flow control window to optimize the network bandwidth utilization. To disable this feature, build channel/server with `NettyChannelBuilder#flowControlWindow` or `NettyServerBuilder#flowControlWindow`. Existing `flowControlWindow` users need to use `initialFlowWindowSize` to enable BDP. ##### New Features - core: ManagedChannel provides LoadBalancer#Helper with implemented createResolvingOobChannel ([#​6923](https://togithub.com/grpc/grpc-java/issues/6923)). - stub: Add `ClientCallStreamObserver.disableAutoRequestWithInitial(int)` and `ServerCallStreamObserver.disableAutoRequest()` that disables all automatic inbound flow-control requests. These methods are intended to replace the existing `CallStreamObserver.disableAutoInboundFlowControl()`. There may still be some tweaks to the API, so `disableAutoInboundFlowControl()` is not yet deprecated - inprocess,core: add ability to pass status cause to client ([#​6968](https://togithub.com/grpc/grpc-java/issues/6968)). The new API is added to `InprocessChannelBuilder` to show stacktrace from transport when an error happens in tests. - netty: support setting options of boss in NettyServer ([#​6947](https://togithub.com/grpc/grpc-java/issues/6947)). Adds a new API on `NettyServerBuilder` to allow passing channel options for the boss ELG. ##### Bug Fixes - okhttp&#x3A; use new APIs to configure TLS in Android (roll forward of [#​6959](https://togithub.com/grpc/grpc-java/issues/6959)) ([#​6960](https://togithub.com/grpc/grpc-java/issues/6960)). Starting from Android 10, there is a new set of public APIs for configuring TLS, where we were previously invoking hidden methods in SSLSocket. Some of those hidden methods are no longer allowed (will be removed in the future) in Android 11. We migrate to use public APIs whenever possible. - netty: Using classloader to isolate grpc without isolating netty can cause exceptions when creating netty channel/server is fixed ([#​7048](https://togithub.com/grpc/grpc-java/issues/7048)). - api, core, services: make ProtoReflectionService interceptor compatible ([#​6967](https://togithub.com/grpc/grpc-java/issues/6967)). Previously intercepting the ProtoReflectionService breaks the internal hack of passing the server instance to the service. Now we change the way of how it obtains the server instance so that applying interceptors to it doesn’t break its functionality. This change also allows multiple servers to use a shared ProtoReflectionService instance. - netty: Reduce race window size between GOAWAY and new streams. This should greatly reduce the number of calls that fail with errors similar to “UNAVAILABLE: HTTP/2 error code: NO_ERROR Received Goaway.” Although note that these errors have multiple sources, and it only addresses one of them - core: Delay transport shutdown when changing a subchannel’s addresses. This should prevent users from seeing errors saying “UNAVAILABLE: InternalSubchannel closed transport due to address change,” which should have already been rare ##### Documentation - For Java 9+ users, we now recommend using `org.apache.tomcat:annotations-api` for the `@Generated` annotation instead of `javax.annotation:javax.annotation-api`, as it has a more appropriate license - SECURITY.md: add instruction for disabling Conscrypt's default TrustManager ([#​6962](https://togithub.com/grpc/grpc-java/issues/6962)). By default, Conscrypt delegates hostname verification to the platform's default HostNameVerifier, which in OpenJDK is a deny-all implementation. You can configure the Conscrypt provider to not use its TrustManager. ##### Dependencies - Starting from this version, some transitive dependencies of gRPC artifacts are changed from compile scope to runtime scope. Users may experience their application can not rebuild once the gRPC version is upgraded, because some other component of the project may require a dependency that is no longer transitively provided by gRPC artifacts at compile time; and if that happens, users should explicitly add that dependency for the other component. This change does not affect running the application at runtime. - Bumped protobuf to 3.12.0 ##### Examples - Deleted example-kotlin ([#​6936](https://togithub.com/grpc/grpc-java/issues/6936)). [grpc-kotlin](https://togithub.com/grpc/grpc-kotlin) was officially released and examples can be found in its own repository. ##### Acknowledgements [@​agasparovic-sabre](https://togithub.com/agasparovic-sabre) [@​AgentK20](https://togithub.com/AgentK20) [@​apolcyn](https://togithub.com/apolcyn) [@​asdf2014](https://togithub.com/asdf2014) [@​ashithasantosh](https://togithub.com/ashithasantosh) [@​chalin](https://togithub.com/chalin) [@​bogdandrutu](https://togithub.com/bogdandrutu) [@​DRayX](https://togithub.com/DRayX) [@​hojongs](https://togithub.com/hojongs) [@​Nextproc](https://togithub.com/Nextproc) [@​plaflamme](https://togithub.com/plaflamme) [@​reggiemcdonald](https://togithub.com/reggiemcdonald) [@​RiyaTyagi](https://togithub.com/RiyaTyagi)
--- ### Renovate configuration :date: **Schedule**: At any time (no schedule defined). :vertical_traffic_light: **Automerge**: Disabled by config. Please merge this manually once you are satisfied. :recycle: **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. :no_bell: **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] If you want to rebase/retry this PR, check this box --- This PR has been generated by [WhiteSource Renovate](https://renovate.whitesourcesoftware.com). View repository job log [here](https://app.renovatebot.com/dashboard#googleapis/java-iam). --- pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pom.xml b/pom.xml index 48eca47e..3df7723b 100644 --- a/pom.xml +++ b/pom.xml @@ -66,7 +66,7 @@ 1.18.0 3.12.0 4.13 - 1.29.0 + 1.30.0 29.0-android From 22705a9764d17e0d8d5f7e1069b1b18352f3765a Mon Sep 17 00:00:00 2001 From: WhiteSource Renovate Date: Thu, 11 Jun 2020 02:05:37 +0200 Subject: [PATCH 08/15] build(deps): update dependency com.google.cloud:google-cloud-shared-config to v0.8.0 (#11) This PR contains the following updates: | Package | Update | Change | |---|---|---| | [com.google.cloud:google-cloud-shared-config](https://togithub.com/googleapis/java-shared-config) | minor | `0.6.0` -> `0.8.0` | --- ### Release Notes
googleapis/java-shared-config ### [`v0.8.0`](https://togithub.com/googleapis/java-shared-config/blob/master/CHANGELOG.md#​080-httpswwwgithubcomgoogleapisjava-shared-configcomparev070v080-2020-06-10) [Compare Source](https://togithub.com/googleapis/java-shared-config/compare/v0.7.0...v0.8.0) ##### Features - revert "feat: mark auto-value-annotations scope as provided" ([#​154](https://www.github.com/googleapis/java-shared-config/issues/154)) ([88afb4e](https://www.github.com/googleapis/java-shared-config/commit/88afb4e7c57cb6e00929c098135314a926d9da30)) ### [`v0.7.0`](https://togithub.com/googleapis/java-shared-config/blob/master/CHANGELOG.md#​070-httpswwwgithubcomgoogleapisjava-shared-configcomparev060v070-2020-06-10) [Compare Source](https://togithub.com/googleapis/java-shared-config/compare/v0.6.0...v0.7.0) ##### Features - mark auto-value-annotations scope as provided ([#​151](https://www.github.com/googleapis/java-shared-config/issues/151)) ([44ea4cb](https://www.github.com/googleapis/java-shared-config/commit/44ea4cbbf92b4ad35ffaffb7a01a1bce05063daf)) ##### Bug Fixes - lock the google-java-format version used by formatter plugin ([#​149](https://www.github.com/googleapis/java-shared-config/issues/149)) ([d58c054](https://www.github.com/googleapis/java-shared-config/commit/d58c05437a4ea8767db2bebfcc405ec77aeb9705))
--- ### Renovate configuration :date: **Schedule**: At any time (no schedule defined). :vertical_traffic_light: **Automerge**: Disabled by config. Please merge this manually once you are satisfied. :recycle: **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. :no_bell: **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] If you want to rebase/retry this PR, check this box --- This PR has been generated by [WhiteSource Renovate](https://renovate.whitesourcesoftware.com). View repository job log [here](https://app.renovatebot.com/dashboard#googleapis/java-iam). --- pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pom.xml b/pom.xml index 3df7723b..2cc69feb 100644 --- a/pom.xml +++ b/pom.xml @@ -14,7 +14,7 @@ com.google.cloud google-cloud-shared-config - 0.6.0 + 0.8.0 From 5f005b45498dc87aeb8cab35d72fbaae04386c24 Mon Sep 17 00:00:00 2001 From: WhiteSource Renovate Date: Fri, 12 Jun 2020 00:39:05 +0200 Subject: [PATCH 09/15] deps: update dependency com.google.protobuf:protobuf-bom to v3.12.2 (#8) --- pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pom.xml b/pom.xml index 2cc69feb..fc8b1907 100644 --- a/pom.xml +++ b/pom.xml @@ -64,7 +64,7 @@ github google-iam-parent 1.18.0 - 3.12.0 + 3.12.2 4.13 1.30.0 29.0-android From c64974f7e45b7a4e878abb48e75c329bd88e51f3 Mon Sep 17 00:00:00 2001 From: WhiteSource Renovate Date: Mon, 15 Jun 2020 22:36:30 +0200 Subject: [PATCH 10/15] build(deps): update dependency com.google.cloud:google-cloud-shared-config to v0.8.1 --- pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pom.xml b/pom.xml index fc8b1907..a656f38e 100644 --- a/pom.xml +++ b/pom.xml @@ -14,7 +14,7 @@ com.google.cloud google-cloud-shared-config - 0.8.0 + 0.8.1 From 82c4bf50f419b7f57f9a0d15a554b7e8509b99db Mon Sep 17 00:00:00 2001 From: yangnuoyu <46553752+yangnuoyu@users.noreply.github.com> Date: Wed, 17 Jun 2020 19:11:57 -0700 Subject: [PATCH 11/15] feat(deps): adopt flatten plugin and google-cloud-shared-dependencies (#14) --- .gitignore | 2 ++ grpc-google-iam-v1/pom.xml | 1 - pom.xml | 32 +++++--------------------------- 3 files changed, 7 insertions(+), 28 deletions(-) diff --git a/.gitignore b/.gitignore index fadd6afc..069d08fc 100644 --- a/.gitignore +++ b/.gitignore @@ -13,3 +13,5 @@ target/ # python utilities *.pyc __pycache__ + +.flattened-pom.xml diff --git a/grpc-google-iam-v1/pom.xml b/grpc-google-iam-v1/pom.xml index 4948f365..e33afd03 100644 --- a/grpc-google-iam-v1/pom.xml +++ b/grpc-google-iam-v1/pom.xml @@ -58,7 +58,6 @@ javax.annotation javax.annotation-api - 1.3.2 diff --git a/pom.xml b/pom.xml index a656f38e..e771161c 100644 --- a/pom.xml +++ b/pom.xml @@ -63,39 +63,17 @@ UTF-8 github google-iam-parent - 1.18.0 - 3.12.2 - 4.13 - 1.30.0 - 29.0-android - com.google.protobuf - protobuf-bom - ${protobuf.version} + com.google.cloud + google-cloud-shared-dependencies + 0.8.1 pom import - - io.grpc - grpc-bom - ${grpc.version} - pom - import - - - com.google.api.grpc - proto-google-common-protos - ${google.common-protos.version} - - - com.google.guava - guava - ${guava.version} - com.google.api.grpc proto-google-iam-v1 @@ -105,7 +83,7 @@ junit junit - ${junit.version} + 4.13 test @@ -179,7 +157,7 @@ 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/${google.api-common.version}/apidocs/ + https://googleapis.github.io/api-common-java/
From c54859b890f80afd97e46c35e373f567d90172a7 Mon Sep 17 00:00:00 2001 From: WhiteSource Renovate Date: Fri, 26 Jun 2020 07:34:21 +0200 Subject: [PATCH 12/15] build(deps): update dependency com.google.cloud:google-cloud-shared-config to v0.9.0 (#17) This PR contains the following updates: | Package | Update | Change | |---|---|---| | [com.google.cloud:google-cloud-shared-config](https://togithub.com/googleapis/java-shared-config) | minor | `0.8.1` -> `0.9.0` | --- ### Release Notes
googleapis/java-shared-config ### [`v0.9.0`](https://togithub.com/googleapis/java-shared-config/blob/master/CHANGELOG.md#​090-httpswwwgithubcomgoogleapisjava-shared-configcomparev081v090-2020-06-25) [Compare Source](https://togithub.com/googleapis/java-shared-config/compare/v0.8.1...v0.9.0) ##### Features - add ignore rule for javax annotations to handle error in java11 ([#​171](https://www.github.com/googleapis/java-shared-config/issues/171)) ([cd635ad](https://www.github.com/googleapis/java-shared-config/commit/cd635ad6e8e5d71ac3a30e7656eb788027f1c370)) ##### [0.8.1](https://www.github.com/googleapis/java-shared-config/compare/v0.8.0...v0.8.1) (2020-06-15) ##### Bug Fixes - bump flatten plugin version to fix missing version in profile section issue ([#​159](https://www.github.com/googleapis/java-shared-config/issues/159)) ([5b34939](https://www.github.com/googleapis/java-shared-config/commit/5b349399a590b589718b7049f66c82ee38742372))
--- ### Renovate configuration :date: **Schedule**: At any time (no schedule defined). :vertical_traffic_light: **Automerge**: Disabled by config. Please merge this manually once you are satisfied. :recycle: **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. :no_bell: **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] If you want to rebase/retry this PR, check this box --- This PR has been generated by [WhiteSource Renovate](https://renovate.whitesourcesoftware.com). View repository job log [here](https://app.renovatebot.com/dashboard#googleapis/java-iam). --- pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pom.xml b/pom.xml index e771161c..9642e5c3 100644 --- a/pom.xml +++ b/pom.xml @@ -14,7 +14,7 @@ com.google.cloud google-cloud-shared-config - 0.8.1 + 0.9.0 From 13767ef1890b5c81cab43baee28a1b535e5b7211 Mon Sep 17 00:00:00 2001 From: WhiteSource Renovate Date: Wed, 1 Jul 2020 21:07:36 +0200 Subject: [PATCH 13/15] deps: update dependency com.google.cloud:google-cloud-shared-dependencies to v0.8.2 (#18) This PR contains the following updates: | Package | Update | Change | |---|---|---| | [com.google.cloud:google-cloud-shared-dependencies](https://togithub.com/googleapis/java-shared-dependencies) | patch | `0.8.1` -> `0.8.2` | --- ### Release Notes
googleapis/java-shared-dependencies ### [`v0.8.2`](https://togithub.com/googleapis/java-shared-dependencies/blob/master/CHANGELOG.md#​082-httpswwwgithubcomgoogleapisjava-shared-dependenciescomparev081v082-2020-07-01) [Compare Source](https://togithub.com/googleapis/java-shared-dependencies/compare/v0.8.1...v0.8.2)
--- ### Renovate configuration :date: **Schedule**: At any time (no schedule defined). :vertical_traffic_light: **Automerge**: Disabled by config. Please merge this manually once you are satisfied. :recycle: **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. :no_bell: **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] If you want to rebase/retry this PR, check this box --- This PR has been generated by [WhiteSource Renovate](https://renovate.whitesourcesoftware.com). View repository job log [here](https://app.renovatebot.com/dashboard#googleapis/java-iam). --- pom.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pom.xml b/pom.xml index 9642e5c3..95dfd9b3 100644 --- a/pom.xml +++ b/pom.xml @@ -70,7 +70,7 @@ com.google.cloud google-cloud-shared-dependencies - 0.8.1 + 0.8.2 pom import From 25c009878cf28e4dda375cf6605aa61b1dd2f1d5 Mon Sep 17 00:00:00 2001 From: Jeff Ching Date: Tue, 11 Aug 2020 12:06:15 -0700 Subject: [PATCH 14/15] chore: regenerate common templates (#21) --- .github/CODEOWNERS | 8 ++++++ .github/workflows/ci.yaml | 5 +++- .kokoro/build.sh | 6 ++-- .kokoro/dependencies.sh | 11 +++++--- .kokoro/nightly/integration.cfg | 12 +++----- .kokoro/nightly/samples.cfg | 16 ++++------- .kokoro/populate-secrets.sh | 43 +++++++++++++++++++++++++++++ .kokoro/presubmit/integration.cfg | 12 +++----- .kokoro/presubmit/samples.cfg | 14 ++++------ .kokoro/release/publish_javadoc.cfg | 10 +++++++ .kokoro/release/publish_javadoc.sh | 25 +++++++++++++++-- .kokoro/trampoline.sh | 2 ++ CONTRIBUTING.md | 11 +++++++- renovate.json | 3 +- 14 files changed, 130 insertions(+), 48 deletions(-) create mode 100644 .github/CODEOWNERS create mode 100755 .kokoro/populate-secrets.sh diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS new file mode 100644 index 00000000..6137bef2 --- /dev/null +++ b/.github/CODEOWNERS @@ -0,0 +1,8 @@ +# 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 java-samples-reviewers team is the default owner for samples changes +samples/**/*.java @googleapis/java-samples-reviewers diff --git a/.github/workflows/ci.yaml b/.github/workflows/ci.yaml index 445b4bf8..68302207 100644 --- a/.github/workflows/ci.yaml +++ b/.github/workflows/ci.yaml @@ -36,11 +36,14 @@ jobs: JOB_TYPE: test dependencies: runs-on: ubuntu-latest + strategy: + matrix: + java: [8, 11] steps: - uses: actions/checkout@v2 - uses: actions/setup-java@v1 with: - java-version: 8 + java-version: ${{matrix.java}} - run: java -version - run: .kokoro/dependencies.sh linkage-monitor: diff --git a/.kokoro/build.sh b/.kokoro/build.sh index d4d2592d..54531d09 100755 --- a/.kokoro/build.sh +++ b/.kokoro/build.sh @@ -39,7 +39,7 @@ retry_with_backoff 3 10 \ # if GOOGLE_APPLICATION_CREDIENTIALS 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_ROOT}/src/${GOOGLE_APPLICATION_CREDENTIALS}) + export GOOGLE_APPLICATION_CREDENTIALS=$(realpath ${KOKORO_GFILE_DIR}/${GOOGLE_APPLICATION_CREDENTIALS}) fi RETURN_CODE=0 @@ -51,9 +51,7 @@ test) RETURN_CODE=$? ;; lint) - mvn \ - -Penable-samples \ - com.coveo:fmt-maven-plugin:check + mvn com.coveo:fmt-maven-plugin:check RETURN_CODE=$? ;; javadoc) diff --git a/.kokoro/dependencies.sh b/.kokoro/dependencies.sh index cf3bb434..c91e5a56 100755 --- a/.kokoro/dependencies.sh +++ b/.kokoro/dependencies.sh @@ -41,12 +41,15 @@ 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 -Dsort=true | grep '\[INFO] .*:.*:.*:.*:.*' | grep -v ':test$' >.org-list.txt + mvn dependency:list -f pom.xml -DincludeScope=runtime -Dsort=true | grep '\[INFO] .*:.*:.*:.*:.*' | sed -e s/\\s--\\smodule.*// >.org-list.txt - # Output dep list generated using the flattened pom (test scope deps are ommitted) + # 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 -Dsort=true | grep '\[INFO] .*:.*:.*:.*:.*' >.new-list.txt + mvn dependency:list -f .flattened-pom.xml -DincludeScope=runtime -Dsort=true | grep '\[INFO] .*:.*:.*:.*:.*' >.new-list.txt # Compare two dependency lists msg "Comparing dependency lists..." @@ -83,4 +86,4 @@ then else msg "Errors found. See log statements above." exit 1 -fi +fi \ No newline at end of file diff --git a/.kokoro/nightly/integration.cfg b/.kokoro/nightly/integration.cfg index 40c4abb7..0048c8ec 100644 --- a/.kokoro/nightly/integration.cfg +++ b/.kokoro/nightly/integration.cfg @@ -28,14 +28,10 @@ env_vars: { env_vars: { key: "GOOGLE_APPLICATION_CREDENTIALS" - value: "keystore/73713_java_it_service_account" + value: "secret_manager/java-it-service-account" } -before_action { - fetch_keystore { - keystore_resource { - keystore_config_id: 73713 - keyname: "java_it_service_account" - } - } +env_vars: { + key: "SECRET_MANAGER_KEYS" + value: "java-it-service-account" } diff --git a/.kokoro/nightly/samples.cfg b/.kokoro/nightly/samples.cfg index 20aabd55..f2542931 100644 --- a/.kokoro/nightly/samples.cfg +++ b/.kokoro/nightly/samples.cfg @@ -24,19 +24,15 @@ env_vars: { env_vars: { key: "GOOGLE_APPLICATION_CREDENTIALS" - value: "keystore/73713_java_it_service_account" + value: "secret_manager/java-docs-samples-service-account" } env_vars: { - key: "ENABLE_BUILD_COP" - value: "true" + key: "SECRET_MANAGER_KEYS" + value: "java-docs-samples-service-account" } -before_action { - fetch_keystore { - keystore_resource { - keystore_config_id: 73713 - keyname: "java_it_service_account" - } - } +env_vars: { + key: "ENABLE_BUILD_COP" + value: "true" } diff --git a/.kokoro/populate-secrets.sh b/.kokoro/populate-secrets.sh new file mode 100755 index 00000000..f5251425 --- /dev/null +++ b/.kokoro/populate-secrets.sh @@ -0,0 +1,43 @@ +#!/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/integration.cfg b/.kokoro/presubmit/integration.cfg index 522e5b10..dded67a9 100644 --- a/.kokoro/presubmit/integration.cfg +++ b/.kokoro/presubmit/integration.cfg @@ -24,14 +24,10 @@ env_vars: { env_vars: { key: "GOOGLE_APPLICATION_CREDENTIALS" - value: "keystore/73713_java_it_service_account" + value: "secret_manager/java-it-service-account" } -before_action { - fetch_keystore { - keystore_resource { - keystore_config_id: 73713 - keyname: "java_it_service_account" - } - } +env_vars: { + key: "SECRET_MANAGER_KEYS" + value: "java-it-service-account" } diff --git a/.kokoro/presubmit/samples.cfg b/.kokoro/presubmit/samples.cfg index 1171aead..01e09600 100644 --- a/.kokoro/presubmit/samples.cfg +++ b/.kokoro/presubmit/samples.cfg @@ -24,14 +24,10 @@ env_vars: { env_vars: { key: "GOOGLE_APPLICATION_CREDENTIALS" - value: "keystore/73713_java_it_service_account" + value: "secret_manager/java-docs-samples-service-account" } -before_action { - fetch_keystore { - keystore_resource { - keystore_config_id: 73713 - keyname: "java_it_service_account" - } - } -} +env_vars: { + key: "SECRET_MANAGER_KEYS" + value: "java-docs-samples-service-account" +} \ No newline at end of file diff --git a/.kokoro/release/publish_javadoc.cfg b/.kokoro/release/publish_javadoc.cfg index f18e3d1d..753ac94e 100644 --- a/.kokoro/release/publish_javadoc.cfg +++ b/.kokoro/release/publish_javadoc.cfg @@ -1,14 +1,24 @@ # 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: "STAGING_BUCKET_V2" + value: "docs-staging-v2-staging" + # Production will be at: docs-staging-v2 +} + env_vars: { key: "TRAMPOLINE_BUILD_FILE" value: "github/java-iam/.kokoro/release/publish_javadoc.sh" } + before_action { fetch_keystore { keystore_resource { diff --git a/.kokoro/release/publish_javadoc.sh b/.kokoro/release/publish_javadoc.sh index 9542b0ee..86c9874a 100755 --- a/.kokoro/release/publish_javadoc.sh +++ b/.kokoro/release/publish_javadoc.sh @@ -24,6 +24,11 @@ if [[ -z "${STAGING_BUCKET}" ]]; then exit 1 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")/../../ @@ -31,13 +36,13 @@ pushd $(dirname "$0")/../../ python3 -m pip install gcp-docuploader # compile all packages -mvn clean install -B -DskipTests=true +mvn clean install -B -q -DskipTests=true NAME=proto-google-iam-v1 VERSION=$(grep ${NAME}: versions.txt | cut -d: -f3) # build the docs -mvn site -B +mvn site -B -q pushd target/site/apidocs @@ -53,3 +58,19 @@ python3 -m docuploader upload . \ --staging-bucket ${STAGING_BUCKET} popd + +# V2 +mvn clean site -B -q -Ddevsite.template="${KOKORO_GFILE_DIR}/java/" + +pushd target/devsite + +# 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_V2} diff --git a/.kokoro/trampoline.sh b/.kokoro/trampoline.sh index ba17ce01..9da0f839 100644 --- a/.kokoro/trampoline.sh +++ b/.kokoro/trampoline.sh @@ -21,4 +21,6 @@ function cleanup() { echo "cleanup"; } trap cleanup EXIT + +$(dirname $0)/populate-secrets.sh # Secret Manager secrets. python3 "${KOKORO_GFILE_DIR}/trampoline_v1.py" diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 085021dd..f2dbdee0 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -99,7 +99,16 @@ mvn -Penable-samples clean verify ``` 2. [Activate](#profile-activation) the profile. -3. Define your samples in a normal Maven project in the `samples/` directory +3. Define your samples in a normal Maven project in the `samples/` directory. + +### Code Formatting + +Code in this repo is formatted with +[google-java-format](https://github.com/google/google-java-format). +To run formatting on your project, you can run: +``` +mvn com.coveo:fmt-maven-plugin:format +``` ### Profile Activation diff --git a/renovate.json b/renovate.json index 5395f5e4..083391a3 100644 --- a/renovate.json +++ b/renovate.json @@ -76,5 +76,6 @@ "groupName": "jackson dependencies" } ], - "semanticCommits": true + "semanticCommits": true, + "masterIssue": true } \ No newline at end of file From 5f64afe1779b67427285a9675905bec21c4612ac Mon Sep 17 00:00:00 2001 From: "release-please[bot]" <55107282+release-please[bot]@users.noreply.github.com> Date: Tue, 11 Aug 2020 16:23:55 -0400 Subject: [PATCH 15/15] chore: release 0.14.0 (#15) * chore: created CHANGELOG.md [ci skip] * chore: updated README.md [ci skip] * chore: updated versions.txt [ci skip] * chore: updated proto-google-iam-v1/pom.xml [ci skip] * chore: updated grpc-google-iam-v1/pom.xml [ci skip] * chore: updated pom.xml [ci skip] * chore: updated grpc-google-iam-v1/build.gradle [ci skip] * chore: updated proto-google-iam-v1/build.gradle Co-authored-by: release-please[bot] <55107282+release-please[bot]@users.noreply.github.com> --- CHANGELOG.md | 17 +++++++++++++++++ grpc-google-iam-v1/pom.xml | 4 ++-- pom.xml | 4 ++-- proto-google-iam-v1/pom.xml | 4 ++-- versions.txt | 2 +- 5 files changed, 24 insertions(+), 7 deletions(-) create mode 100644 CHANGELOG.md diff --git a/CHANGELOG.md b/CHANGELOG.md new file mode 100644 index 00000000..bedac9a6 --- /dev/null +++ b/CHANGELOG.md @@ -0,0 +1,17 @@ +# Changelog + +## [0.14.0](https://www.github.com/googleapis/java-iam/compare/v0.13.0...v0.14.0) (2020-08-11) + + +### Features + +* **deps:** adopt flatten plugin and google-cloud-shared-dependencies ([#14](https://www.github.com/googleapis/java-iam/issues/14)) ([82c4bf5](https://www.github.com/googleapis/java-iam/commit/82c4bf50f419b7f57f9a0d15a554b7e8509b99db)) + + +### Dependencies + +* update dependency com.google.api.grpc:proto-google-common-protos to v1.18.0 ([#2](https://www.github.com/googleapis/java-iam/issues/2)) ([81a7470](https://www.github.com/googleapis/java-iam/commit/81a7470ee9633ff052ccb679cbe37b0079ee51ef)) +* update dependency com.google.cloud:google-cloud-shared-dependencies to v0.8.2 ([#18](https://www.github.com/googleapis/java-iam/issues/18)) ([13767ef](https://www.github.com/googleapis/java-iam/commit/13767ef1890b5c81cab43baee28a1b535e5b7211)) +* update dependency com.google.protobuf:protobuf-bom to v3.12.0 ([#6](https://www.github.com/googleapis/java-iam/issues/6)) ([73b7a4a](https://www.github.com/googleapis/java-iam/commit/73b7a4a03411326f88e49c2efbd1e34d2170dc1b)) +* update dependency com.google.protobuf:protobuf-bom to v3.12.2 ([#8](https://www.github.com/googleapis/java-iam/issues/8)) ([5f005b4](https://www.github.com/googleapis/java-iam/commit/5f005b45498dc87aeb8cab35d72fbaae04386c24)) +* update dependency io.grpc:grpc-bom to v1.30.0 ([#10](https://www.github.com/googleapis/java-iam/issues/10)) ([f69ac15](https://www.github.com/googleapis/java-iam/commit/f69ac15807aafc345f980091feadd4eb3996976c)) diff --git a/grpc-google-iam-v1/pom.xml b/grpc-google-iam-v1/pom.xml index e33afd03..fa7187cf 100644 --- a/grpc-google-iam-v1/pom.xml +++ b/grpc-google-iam-v1/pom.xml @@ -4,13 +4,13 @@ 4.0.0 com.google.api.grpc grpc-google-iam-v1 - 0.13.1-SNAPSHOT + 0.14.0 grpc-google-iam-v1 GRPC library for grpc-google-iam-v1 com.google.cloud google-iam-parent - 0.13.1-SNAPSHOT + 0.14.0 diff --git a/pom.xml b/pom.xml index 95dfd9b3..774e49b1 100644 --- a/pom.xml +++ b/pom.xml @@ -4,7 +4,7 @@ com.google.cloud google-iam-parent pom - 0.13.1-SNAPSHOT + 0.14.0 Google IAM Parent https://github.com/googleapis/java-iam @@ -77,7 +77,7 @@ com.google.api.grpc proto-google-iam-v1 - 0.13.1-SNAPSHOT + 0.14.0 diff --git a/proto-google-iam-v1/pom.xml b/proto-google-iam-v1/pom.xml index 1a9506c8..a6628e5c 100644 --- a/proto-google-iam-v1/pom.xml +++ b/proto-google-iam-v1/pom.xml @@ -4,13 +4,13 @@ 4.0.0 com.google.api.grpc proto-google-iam-v1 - 0.13.1-SNAPSHOT + 0.14.0 proto-google-iam-v1 PROTO library for proto-google-iam-v1 com.google.cloud google-iam-parent - 0.13.1-SNAPSHOT + 0.14.0 diff --git a/versions.txt b/versions.txt index 7d21bd24..97817876 100644 --- a/versions.txt +++ b/versions.txt @@ -1,4 +1,4 @@ # Format: # module:released-version:current-version -proto-google-iam-v1:0.13.0:1.13.1-SNAPSHOT +proto-google-iam-v1:0.14.0:0.14.0